Helps With Cmds

Helps With Cmds

Postby creamchef » 30 Jan 2013, 12:34

How do I add cmds, like where do I put them?
Owner of Infection Time![Zombie Survival]
creamchef
 
Posts: 60
Joined: 09 Jul 2012, 23:54

Re: Helps With Cmds

Postby SS_Legend » 30 Jan 2013, 15:54

Navigate to your MCDzienny folder, extra > commands > dll (create a folder named dll if you don't have one) > drag and drop your .dll file into there.

Make sure in front of the .dll file it has Cmd<name> first, and make sure that the command is made for MCDzienny.

For example: CmdZombie.dll
Owner of [LS] Servers

Lava Survival: Image
Zombie Survival: Image
Website: http://legendservers.enjin.com/
SS_Legend
 
Posts: 116
Joined: 24 Feb 2012, 00:54

Re: Helps With Cmds

Postby Conor » 30 Jan 2013, 16:38

You can also create your own command skeletons (.cs files) and then compile them to a dll file using MCDzienny.

To create a custom command this way, you use the /cmdcreate (cmdName) command. Then you can edit the .cs file found in extra > commands > source. You can view and edit it with notepad, but a coding environment such as Microsoft Visual Studio is much more effective.

Then you can compile the command using ./compile (cmdName). This compiles the .cs file and the .dll for your command is then found within extra > commands > dll, as SS_Legend said.

To load your commands you can use /cmdload and to unload and re-edit you can then use /cmdunload.

Place a command name in cmdautoload.txt to ensure they are loaded on server start up.
Conor (Conanza121)
User avatar
Conor
Coder
 
Posts: 390
Joined: 10 Oct 2012, 21:36
Location: @21Conor

Re: Helps With Cmds

Postby creamchef » 30 Jan 2013, 20:37

Ty :DD
Owner of Infection Time![Zombie Survival]
creamchef
 
Posts: 60
Joined: 09 Jul 2012, 23:54

Re: Helps With Cmds

Postby creamchef » 31 Jan 2013, 01:27

I didnt work, i had to make the commands folder adn dll folder, when i cmdload the cmd it comes up with this:
Cmdlottery.dll does not exist in the DLL folder, or is missing a dependency. Details in the error log.
Owner of Infection Time![Zombie Survival]
creamchef
 
Posts: 60
Joined: 09 Jul 2012, 23:54

Re: Helps With Cmds

Postby ismellike » 31 Jan 2013, 05:17

Save code in a text file but name it Cmdlottery.cs.and have it in extra>commands>source.

Then in game do /compile lottery and /cmdload lottery
What a beast...
User avatar
ismellike
Coder
 
Posts: 731
Joined: 31 Oct 2012, 04:04
Location: Kansas

Re: Helps With Cmds

Postby creamchef » 31 Jan 2013, 22:25

ismellike wrote:Save code in a text file but name it Cmdlottery.cs.and have it in extra>commands>source.

Then in game do /compile lottery and /cmdload lottery

File not found: Cmdlottery.cs
Owner of Infection Time![Zombie Survival]
creamchef
 
Posts: 60
Joined: 09 Jul 2012, 23:54

Re: Helps With Cmds

Postby Conor » 01 Feb 2013, 16:49

You do not rename the text file to Cmdlottery.cs

You rename the file name to Cmdlottery, and the extension type to .cs, instead of .txt

Right now you probably have cmdlottery.cs.txt which is wrong.

See here for help: viewtopic.php?f=12&t=1763
Conor (Conanza121)
User avatar
Conor
Coder
 
Posts: 390
Joined: 10 Oct 2012, 21:36
Location: @21Conor


Return to Help in Coding

Who is online

Users browsing this forum: No registered users and 1 guest

cron