|
Removed.
This is the error:
Code:src\com\rs2hd\packethandler\Object1PacketHandler.java:40: duplicate case label case 15204: ^ src\com\rs2hd\packethandler\Object1PacketHandler.java:43: duplicate case label case 15204: ^ src\com\rs2hd\packethandler\Object1PacketHandler.java:46: duplicate case label case 15204: ^ src\com\rs2hd\packethandler\Object1PacketHandler.java:49: duplicate case label case 15204: ^ src\com\rs2hd\packethandler\Object1PacketHandler.java:52: duplicate case label case 15204: ^ src\com\rs2hd\packethandler\Object1PacketHandler.java:55: duplicate case label case 15204: ^
It's because you duplicated the case 6 times lol... you only need to make one case statement for that object id and put inside of that case statement if statements that check for the objects x and y coordinated =)
I.E
and so on and so forth and your welcome...Code:case 1337: if(objectX == x coord here && objectY == y coord here) { your method here; } if(objectX == second x coord here && objectY == second y coord here) { your method here; } break;
Yeah, I understood, but I don't know how to combine them, lol.
This is how mine looks like:
Code:break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0); break; case 15204: player.getActionSender().sendCreateObject(15205, 0, X, Y, 4, 0);
I'm too lazzzzzy to do that atm. xD Just woke upppp, do it for me you noob.
i just gave you the EXACT way to do it lol all you need to do is print out the object's x and y coords when you click on it, so at the bottom of your object option 1 class you need to make sure under DEFAULT that there is a method that prints out the x and y coords of the object... Once you get the x and y coords plug them into my code and boom all set... put all of the objects into 1 case by using if statements...
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |