Thread: [ANY] Queued Switching System [Server Sided]

Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 31
  1. #21  
    Registered Member
    Join Date
    Jun 2012
    Posts
    80
    Thanks given
    18
    Thanks received
    21
    Rep Power
    46
    Quote Originally Posted by Ey Cuzzo View Post
    Or...

    in resetItems(int)
    Code:
    		if(c.getAwaitingUpdate())
    			c.setAwaitingUpdate(false);
    In wearItem(int, int) under if(slot >= 0 && ...)
    Code:
    c.setAwaitingUpdate(true);
    In client.java, in process:
    Code:
    		if(getAwaitingUpdate())
    			getItems().resetItems(3214);
    In Player.java declare:
    Code:
    	public void setAwaitingUpdate(boolean update) {
    		awaitingUpdate = update;
    	}
    	
    	public boolean getAwaitingUpdate() {
    		return awaitingUpdate;
    	}
    	
    	private boolean awaitingUpdate = false;
    Edit: got derepped for posting "shit code making the thread look bad." If you think the above code is shit, you're a moron. It really can't get ANY simpler.
    Can't believe people are trying to sell this.
    Reply With Quote  
     

  2. #22  
    bop
    Spar's Avatar
    Join Date
    Dec 2011
    Posts
    273
    Thanks given
    227
    Thanks received
    50
    Rep Power
    35
    Quote Originally Posted by Da Real Underoath View Post
    Can't believe people are trying to sell this.
    But that's not what hes selling now is it..?

    Refer to:

    Quote Originally Posted by L__A View Post
    So far from true it's funny

    Let me point out the flaws in your code;

    1. toWear[invslot] = true is wrong since you declared "toWear" as an int array, not a boolean array.
    2. You're never storing the item id that needs to be equipped
    3. You're enhanced iterating though an integer array and using "toWear[i]" which will give you an index out of bounds error if the item id (that you never stored) is greater than 27.
    4. You're checking if "toWear[i]" is true when it's an integer array.
    5. equipItem(i) would not work since you also need to specify the item slot in a PI
    6.
    Reply With Quote  
     

  3. #23  
    Registered Member
    Join Date
    Dec 2012
    Posts
    5
    Thanks given
    0
    Thanks received
    2
    Rep Power
    0
    Quote Originally Posted by bwump View Post
    But that's not what hes selling now is it..?

    Refer to:
    It's actually exactly what he's selling though...?
    Reply With Quote  
     

  4. #24  
    Registered Member

    Join Date
    Apr 2012
    Posts
    764
    Thanks given
    0
    Thanks received
    276
    Rep Power
    213
    Quote Originally Posted by Ey Cuzzo View Post
    It's actually exactly what he's selling though...?
    Ask anyone who I've sold this to - it's not it ~.~
    Reply With Quote  
     

  5. #25  
    Registered Member
    Join Date
    Dec 2012
    Posts
    5
    Thanks given
    0
    Thanks received
    2
    Rep Power
    0
    Quote Originally Posted by L__A View Post
    Ask anyone who I've sold this to - it's not it ~.~
    If you would like, send me the usual code in PM. If its anything more complicated than what I had posted, it's really unnecessary.
    Reply With Quote  
     

  6. #26  
    RuneAdventure - The Epic Adventure

    Thock321's Avatar
    Join Date
    Jul 2011
    Posts
    1,809
    Thanks given
    706
    Thanks received
    363
    Rep Power
    416
    Quote Originally Posted by SGPK View Post
    its probably something like this


    declare ->
    Code:
    public int[] toWear = new int[28];
    public boolean needsToDo = false;
    itemwear ->
    Code:
    toWear[invslot] = true;
    needsToDo = true;
    process ->
    Code:
    if (needsToDo) {
     for (int i : toWear) {
      if (toWear[i]) equipItem(i);
      toWear[i] = false;
     }
     needsToDo = false;
    }
    Your code is totally wrong, and you could make a real queue.
    Reply With Quote  
     

  7. #27  
    Registered Member

    Join Date
    Apr 2012
    Posts
    764
    Thanks given
    0
    Thanks received
    276
    Rep Power
    213
    Quote Originally Posted by Ey Cuzzo View Post
    If you would like, send me the usual code in PM. If its anything more complicated than what I had posted, it's really unnecessary.
    The code itself is rather simplistic, so I'll just tell you what Jagex does. Jagex queues all switches (a maximum of 8 per tick) and performs them all at once at the end of a tick cycle (and in turn, updates the inventory). That is exactly what I do, nothing more, nothing less.

    If you truly coded your extremely complicated if statement (internet needs a sarcasm font) then you should be able to code what I just said, as well.
    Reply With Quote  
     

  8. #28  
    Registered Member
    Join Date
    Dec 2012
    Posts
    5
    Thanks given
    0
    Thanks received
    2
    Rep Power
    0
    Quote Originally Posted by L__A View Post
    The code itself is rather simplistic, so I'll just tell you what Jagex does. Jagex queues all switches (a maximum of 8 per tick) and performs them all at once at the end of a tick cycle (and in turn, updates the inventory). That is exactly what I do, nothing more, nothing less.

    If you truly coded your extremely complicated if statement (internet needs a sarcasm font) then you should be able to code what I just said, as well.
    Putting it in a "queue" is rather extraneous, when you can easily update the inventory/equipment tab at the end of the cycle as I displayed earlier. However, due to popular belief; if it works, it works.

    Saying that, I still don't believe this should be sold as it is quite simple and not at all difficult to implement. Almost like selling the DDS spec function.
    Reply With Quote  
     

  9. #29  
    Registered Member
    Karma_K's Avatar
    Join Date
    Nov 2012
    Posts
    4,287
    Thanks given
    152
    Thanks received
    610
    Rep Power
    108
    how muuch would this cost exactly
    Reply With Quote  
     

  10. #30  
    Registered Member
    Velocity's Avatar
    Join Date
    Jan 2009
    Age
    25
    Posts
    2,029
    Thanks given
    1,013
    Thanks received
    2,373
    Rep Power
    4112
    I hope for the love of god you're not actually making a queue...
    Reply With Quote  
     

Page 3 of 4 FirstFirst 1234 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Replies: 12
    Last Post: 07-27-2011, 08:24 PM
  2. [$40] Server sided end of voting system
    By !!A!! in forum Requests
    Replies: 3
    Last Post: 04-24-2011, 12:22 PM
  3. client sided or server sided?
    By wa3ad in forum Help
    Replies: 9
    Last Post: 04-21-2011, 03:53 PM
  4. help on client sided and server sided
    By Zᴀᴄʜ in forum Help
    Replies: 5
    Last Post: 06-20-2010, 08:24 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •