Assistance in the development of a new server from scratch

Started by Martin_Voitel, Apr 27, 2015, 04:49 PM

Previous topic - Next topic

Martin_Voitel

Hello everyone! Really want to make your RPG server based on the client's 0.4. But I don't know a programming language and not know what to start with. Who could tell. how to start the server, to establish a registration on the server, set cars and houses on the map and make them available for purchase. To do a simple job. I will be very glad if someone can help me! May be somebody wants to organize a RPG server, you can take together, I have a lot of interesting ideas.

Honey

It's good that you want to make a RPG server for 0.4 , We appreciate your efforts :)

I Suggest you start from the wiki here : http://wiki.vc-mp.org

Once you're familiar with some Function Syntax You can start by downloading the VC:MP Server and plugins, You can get more information by wandering around the forum, Goodluck :)

Martin_Voitel

I badly know English and it's hard for me to search it all. In the game I was advised to seek help on the forum. I would like to learn how to make the first run, which file in the folder the server is responsible for what and how it can be edited

Honey

Basically, We make files with the extension .nut which are read by the server, You start by making a main file also known as main.nut, You can change the main file by going into server.cfg and replacing sqgamemode with the required file directory for e.g. If I've my Main file in Scripts Folder I would load it like this :

sqgamemode Scripts\Main.nut ( It may be the wrong slash, Just for showing purposes )

Then You can start by OnScriptLoad(); Which is read by the server before anything else, Like before You can see Other Official Events and Functions in the wiki. Some examples are OnPlayerCommand( params ) ( Gets triggered when a player enters a command like /register ) or OnPlayerHealthChange( newhp, oldhp ), Scripting examples :

function onPlayerCommand( player, cmd, text ) // Hopefully these were the ones :)
{
if ( cmd == "hello ")
{
MessagePlayer( " Hey ", player );
}
}

And

OnScriptLoad()
{
print( "Script Loaded") // Prints "Script Loaded " when server starts
}

Hopefully that'll help you start, If you need help don't hesitate to ask :)

.

Quote from: Honey on Apr 27, 2015, 05:27 PMBasically, We make files with the extension .nut which are read by the server...

Just for reference. The file extension can be anything you like. You could even omit having one. As long as it's a text file then it should load just fine.
.

Martin_Voitel

Quote from: Honey on Apr 27, 2015, 05:27 PMBasically, We make files with the extension .nut which are read by the server, You start by making a main file also known as main.nut, You can change the main file by going into server.cfg and replacing sqgamemode with the required file directory for e.g. If I've my Main file in Scripts Folder I would load it like this :

sqgamemode Scripts\Main.nut ( It may be the wrong slash, Just for showing purposes )

Then You can start by OnScriptLoad(); Which is read by the server before anything else, Like before You can see Other Official Events and Functions in the wiki. Some examples are OnPlayerCommand( params ) ( Gets triggered when a player enters a command like /register ) or OnPlayerHealthChange( newhp, oldhp ), Scripting examples :

function onPlayerCommand( player, cmd, text ) // Hopefully these were the ones :)
{
if ( cmd == "hello ")
{
MessagePlayer( " Hey ", player );
}
}

And

OnScriptLoad()
{
print( "Script Loaded") // Prints "Script Loaded " when server starts
}

Hopefully that'll help you start, If you need help don't hesitate to ask :)


Thank you. And what program to open and edit the files .nut? And from where I can download the server files? The link to the wiki page http://wiki.vc-mp.org/wiki/Main_Page or server from one topic to the forum http://forum.vc-mp.org/?topic=33.0 ?

Gulk

Notepad++ is a good program for editing scripts and such. - http://notepad-plus-plus.org/

You'll get the latest server executables and plugins here - http://forum.vc-mp.org/?board=5.0