[HowTo] Create Custom In Game Command

06/23/2022 19:32 Nove240#1
Hello, Today a quick tutorial : How to create in game command like /buff /about etc..

First of all, you must use the Source Code ( of Captain Herlock )

All modification are into the GameMessage.cpp File :

First, you need to add a Command like this :

[Only registered and activated users can see links. Click Here To Register...]

Note : the NORMAL2 function allow to all player to use the command, if you want to make only GM command : you must use GM2and specify the required permission to use the command : like this

[Only registered and activated users can see links. Click Here To Register...]

After doing this : go to line +- 2000 and add the function of the command : like this

[Only registered and activated users can see links. Click Here To Register...]

In my case, the function execute lua code, but if you are good with source you can do lot of other things !

Result In game for the /about :

[Only registered and activated users can see links. Click Here To Register...]

Have a Nice Day !

Fayz / Aeklys
06/27/2023 09:21 hassuny#2
Super !!
06/27/2023 11:03 osomeloso#3
Great job!!!

And If you call a lua code where you need to create the lua? In the normal route from server folder?
06/27/2023 12:06 yosiemelo#4
Quote:
Originally Posted by osomeloso View Post
Great job!!!

And If you call a lua code where you need to create the lua? In the normal route from server folder?
yes
resource -> script