Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[Request] Gm Commands

Joined
Jan 11, 2013
Messages
589
Reaction score
82
Hi, im new to the private server community and i'm eager to learn how to code. Can anyone please explain the methods behind the Gm Commands; how to read and edit them? I searched google and ragezone and i'm without any luck finding a tutorial. If anyone can explain in detail how it works or has seen a tutorial please reply, i would be really greatfull. If it helps i'm using Lithium V111 Base. :w00t:

Edit: I'm basicly trying to customize/clean up the Gm commands for admin/head gm/jr/donor.
 
BloopBloop
Joined
Aug 9, 2012
Messages
892
Reaction score
275
You should start learning the basics of java, before you continue with private server development

This site will help you learning java:
Thenewboston.org

Do you know what this means?
Code:
System.out.println("Haaai");
 
Upvote 0
Initiate Mage
Joined
Dec 13, 2012
Messages
26
Reaction score
0
Agreed with Hilia. If you have no programming experience you're in over your head. I have been programming for years and it still takes considerable time.

At any rate, if you open the source then open client->messages->commands you'll see a separate file for each gm rank. Sort through that and once it makes sense to you, you'll know how to add/remove commands.
 
Upvote 0
Custom Title Activated
Member
Joined
Apr 29, 2008
Messages
1,297
Reaction score
509
Agreed with Hilia. If you have no programming experience you're in over your head. I have been programming for years and it still takes considerable time.

At any rate, if you open the source then open client->messages->commands you'll see a separate file for each gm rank. Sort through that and once it makes sense to you, you'll know how to add/remove commands.

I never had programming experience in Java when I started. I didn't bother reading the "basics" or "books". If you're programming for years, I doubt it would take a "considerable time".

Things I don't understand is, people should learn from trial and error. And come on, all the file names and function names are even named as what they're supposed to do. If you even bothered trying to understand, you would know
Code:
c.getPlayer().gainMeso(5000);
Would make you gain 5k mesos. Regardless or not with programming experience.
 
Upvote 0
Joined
Jan 11, 2013
Messages
589
Reaction score
82
....i don't mean to sound rude, i'm thankful that you guys replied, but when i asked for help i just ment someone to point out important details here and there. Anyone can tell me that i should learn java, and i agree that is should, and i'm trying to. Also, if u been "programming" for yrs surely u could of given me better advise, again i'm not trying to be rude. As for Xerie comment above, I'm not stupid lol, i know the basics of reading the script, thats a "no shet" statement, pardon my rudeness. Maybe it's my fault for not being Clear with my question, I was just asking for someone to hint at how the GM Command function works and how to read it, since it's obviously not as simple as "C.getPlayer().gainMeso(500);"
 
Upvote 0
Custom Title Activated
Member
Joined
Apr 29, 2008
Messages
1,297
Reaction score
509
....i don't mean to sound rude, i'm thankful that you guys replied, but when i asked for help i just ment someone to point out important details here and there. Anyone can tell me that i should learn java, and i agree that is should, and i'm trying to. Also, if u been "programming" for yrs surely u could of given me better advise, again i'm not trying to be rude. As for Xerie comment above, I'm not stupid lol, i know the basics of reading the script, thats a "no shet" statement, pardon my rudeness. Maybe it's my fault for not being Clear with my question, I was just asking for someone to hint at how the GM Command function works and how to read it, since it's obviously not as simple as "C.getPlayer().gainMeso(500);"

Wasn't talking to you in my earlier post.
Yea, it's real similar. Lol. Have you even bothered trying to read the commands file?
 
Upvote 0
BloopBloop
Joined
Aug 9, 2012
Messages
892
Reaction score
275
This is the Command:
Code:
   public static class Somemeso extends CommandExecute {
        
         @Override
        public int execute(MapleClient c, String[] splitted) {
            c.getPlayer().gainMeso(5000, true);
            return 1;
        }
    }

Code:
 public static class Somemeso extends CommandExecute {
Somemeso = The Command name.

Code:
 @Override
Because you extend the class "CommandExecute", you need to type @override

Code:
 public abstract int execute(MapleClient c, String[] splitted);
Lazy .... Copy Paste FTW....
/**
* The method executed when this command is used.
*
* @param c the client executing this command
* @param splitted the command and any arguments attached
*
* @return 1 if you want to log the command, 0 if not. TODO: USE {@link #ReturnValue}
*/

In other words if you type "!notice Haaai" , Then "Haai" is the splitted string.

Code:
 c.getPlayer().gainMeso(5000, true);
Get the Maple Character that uses this command and give him 5000 meso
 
Upvote 0
Back
Top