Thread: 317 PI duplicate dropped items dont load

Results 1 to 3 of 3
  1. #1 317 PI duplicate dropped items dont load 
    Sexy
    Im Strength's Avatar
    Join Date
    Sep 2012
    Posts
    477
    Thanks given
    40
    Thanks received
    35
    Rep Power
    20
    okay so the problems lies when you die, lets say you have 20 dragon bones in your inventory. un noted ones. and you die.

    you go back to where you died to loot back your dragon bones and theres only one dragon bone there. if you spam click it you can pick up probably 5-6 of them.

    when you teleport away and teleport back there is one there again, rinse and repeat until you have looted all 20 (weather its one at a time or 5-6 at a time you still only get the original 20)

    so i know its in my reloaditems method, but i cant seem to figure out whats going on, any idea? compairsons of working ones?

    heres mine:

    [SPOIL]
    Code:
    	public void reloadItems(Client c) {
    		for(GroundItem i : items) {
    			if(c != null){
    				if (c.getItems().tradeable(i.getItemId()) || i.getName().equalsIgnoreCase(c.playerName)) {
    					if (c.distanceToPoint(i.getItemX(), i.getItemY()) <= 60) {
    						if(i.hideTicks > 0 && i.getName().equalsIgnoreCase(c.playerName)) {
    							c.getItems().removeGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    							c.getItems().createGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    						}
    						if(i.hideTicks == 0) {
    							c.getItems().removeGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    							c.getItems().createGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    						}
    					}
    				}	
    			}
    		}
    	}
    [/SPOIL]
    Reply With Quote  
     

  2. #2  
    Sexy
    Im Strength's Avatar
    Join Date
    Sep 2012
    Posts
    477
    Thanks given
    40
    Thanks received
    35
    Rep Power
    20
    bump, still need help
    Reply With Quote  
     

  3. #3  
    Registered Member
    Stanaveli's Avatar
    Join Date
    Aug 2014
    Posts
    1,490
    Thanks given
    184
    Thanks received
    653
    Rep Power
    1338
    Quote Originally Posted by Im Strength View Post
    okay so the problems lies when you die, lets say you have 20 dragon bones in your inventory. un noted ones. and you die.

    you go back to where you died to loot back your dragon bones and theres only one dragon bone there. if you spam click it you can pick up probably 5-6 of them.

    when you teleport away and teleport back there is one there again, rinse and repeat until you have looted all 20 (weather its one at a time or 5-6 at a time you still only get the original 20)

    so i know its in my reloaditems method, but i cant seem to figure out whats going on, any idea? compairsons of working ones?

    heres mine:

    [SPOIL]
    Code:
    	public void reloadItems(Client c) {
    		for(GroundItem i : items) {
    			if(c != null){
    				if (c.getItems().tradeable(i.getItemId()) || i.getName().equalsIgnoreCase(c.playerName)) {
    					if (c.distanceToPoint(i.getItemX(), i.getItemY()) <= 60) {
    						if(i.hideTicks > 0 && i.getName().equalsIgnoreCase(c.playerName)) {
    							c.getItems().removeGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    							c.getItems().createGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    						}
    						if(i.hideTicks == 0) {
    							c.getItems().removeGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    							c.getItems().createGroundItem(i.getItemId(), i.getItemX(), i.getItemY(), i.getItemAmount());
    						}
    					}
    				}	
    			}
    		}
    	}
    [/SPOIL]
    Look what I marked in red, it looks like if you aren't within distance to the ground item it doesn't show it at al?

    Also why are you removing them all then spawning them back on the ground?
    Keep your head up.



    Reply With Quote  
     


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: 1
    Last Post: 07-23-2013, 06:10 PM
  2. [317] PI No drops?!!?!?
    By Vexare in forum Help
    Replies: 13
    Last Post: 04-19-2013, 10:57 PM
  3. Replies: 26
    Last Post: 07-13-2011, 03:47 PM
  4. Replies: 11
    Last Post: 05-24-2011, 06:52 AM
  5. items dont load
    By Dylan in forum Help
    Replies: 5
    Last Post: 07-28-2009, 10:30 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
  •