• Welcome to ForumKorner!
    Join today and become a part of the community.

Coding Question

Zewko

New Member
Reputation
0
Hey guys,

I just have a quick question..I am new to the "RSPS" community and I wanted to ask a very simple question, How do I add commands? I have the code for commands I want to add but I need to know were to put them (I know where to put them, Commands.Java But were in Commands.Java do I put the new command I made)?

Commands I want to make -

if(playerCommand.startsWith("donate")) {
c.getPA().sendFrame126("http://google.com", 12000);
}

if(playerCommand.equals("corp")) {
c.getPA() .movePlayer(x, y,0); //replace x & y with the coords
}

if (playerCommand.startsWith("curses")) {
c.setSidebarInterface(5, 5608);
c.getCurse().resetCurse();
}


Those, Just need to know were to put them...

Thanks guys,
Mike
 

Deathwish

Onyx user!
Reputation
0
For the rsps I used to use, every command was a class, but you should check playerHandler.
 

Zewko

New Member
Reputation
0
Deathwish said:
For the rsps I used to use, every command was a class, but you should check playerHandler.

OK, Got that.. But were in the commands.java do I put the command that I just made?
 

Zewko

New Member
Reputation
0
So anywere in between the "Jail" and "Mute" command?

http ://puu.sh/1d6zN

That's what I mean.
 

Deathwish

Onyx user!
Reputation
0
Yeah. It's just a bunch of if commands. Order doesn't really matter.
 
Top