I need some advice on a couple of questions.
#1

Hello, I am thinking of getting into SAMP coding again, but I want to ask some questions about this.

First question: If I am making a server, would I put all the codes in 1 gamemode or in a gamemode and some filterscripts? Can you tell me why and when I should use what?

Second question: What's better to use to save data like properties, cars, players. Mysql or just some text files in folders? Can you also tell me why and when I should use what?

Thank you very much, if you're going to answer to this.

xX4m4zingXx
Reply
#2

1. I personally never use filterscripts unless I need for example PleoMax textdraw editor etc. etc. But you can use them. Best way I find is by having multiple modules example:
PHP код:
#include "..\myScripts\LSPD.pwn" 
But if you arent good with modules, better have it all inside 1 script for nwo until you learn how to do it. You can also use filterscripts but it can cause a mess if you dont know what are you doing

2. Depends, what sort of server you want to have? How much are you willing to pay for your box? If you are thinking of making a larger server and you expect big playerbase go with MySQL if not Id suggest that you use something like YINI. Also all depends on what you achieve, SQL is great for searching data, injecting etc. but it can be tricky if you dont know SQL good.

Regarding SQL, there is just too much gain from it. You can make separate tables and inject stuff into them separately so you can keep track of everything nicely. Start learning SQL and you might have an awesome time or might be horrible.
Reply
#3

First answer: In my opinion, it's more better to put all the codes in 1 gamemode and some filterscripts. Why ? Because the gamemode is the most important thing on a server. It's the "heart" of all of the things that are out there. The filterscripts running a single script or a little more.
Like in server.cfg
PHP код:
...
gamemode0 your_gamemode1
filterscripts your_filterscripts
... 
gamemode is run first against filterscript and the filterscript and problems may arise to filterscripts and bugging the gamemode(My opinion)

Second answer: If you want ro save your health,money,your house,biz,faction,etc. you need to use to save data. I use INI and MYSQL
Reply
#4

Hello,

1st. I like to have everything in one file. Modules suck on SA-MP, dependency everywhere.
2nd. Go with SQLite or MySQL. I prefer SQLite, though.
Reply
#5

Quote:
Originally Posted by TwinkiDaBoss
Посмотреть сообщение
1. I personally never use filterscripts unless I need for example PleoMax textdraw editor etc. etc. But you can use them. Best way I find is by having multiple modules example:
PHP код:
#include "..\myScripts\LSPD.pwn" 
But if you arent good with modules, better have it all inside 1 script for nwo until you learn how to do it. You can also use filterscripts but it can cause a mess if you dont know what are you doing

2. Depends, what sort of server you want to have? How much are you willing to pay for your box? If you are thinking of making a larger server and you expect big playerbase go with MySQL if not Id suggest that you use something like YINI. Also all depends on what you achieve, SQL is great for searching data, injecting etc. but it can be tricky if you dont know SQL good.

Regarding SQL, there is just too much gain from it. You can make separate tables and inject stuff into them separately so you can keep track of everything nicely. Start learning SQL and you might have an awesome time or might be horrible.
Quote:
Originally Posted by radiobizza
Посмотреть сообщение
First answer: In my opinion, it's more better to put all the codes in 1 gamemode and some filterscripts. Why ? Because the gamemode is the most important thing on a server. It's the "heart" of all of the things that are out there. The filterscripts running a single script or a little more.
Like in server.cfg
PHP код:
...
gamemode0 your_gamemode1
filterscripts your_filterscripts
... 
gamemode is run first against filterscript and the filterscript and problems may arise to filterscripts and bugging the gamemode(My opinion)

Second answer: If you want ro save your health,money,your house,biz,faction,etc. you need to use to save data. I use INI and MYSQL

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
Hello,

1st. I like to have everything in one file. Modules suck on SA-MP, dependency everywhere.
2nd. Go with SQLite or MySQL. I prefer SQLite, though.
Thank you for all those comments. I am definitely going to put everything in 1 gamemode. I am not sure yet if I am going to use MySQL/SQLlite or just folders. I think that if I can get MySQL/SQLlite(is this the right naming) working that it's way more handy than just files, because you can use that info in websites.
Reply
#6

Quote:
Originally Posted by xX4m4zingXx
Посмотреть сообщение
Hello, I am thinking of getting into SAMP coding again, but I want to ask some questions about this.

First question: If I am making a server, would I put all the codes in 1 gamemode or in a gamemode and some filterscripts? Can you tell me why and when I should use what?

Second question: What's better to use to save data like properties, cars, players. Mysql or just some text files in folders? Can you also tell me why and when I should use what?

Thank you very much, if you're going to answer to this.

xX4m4zingXx
First, You can Make All codes On 1 Gamemodes .. But If you want to Make on Filterscript ..Not Probs
But You must Know How Much Filterscript and Gamemodes can Load Read Here !

Second,Mysql Is Look Better , But if you have a Confused you can Make On SQLite !
SQLite Is Not Dificult Which Mysql

====Good Luck For Coding again!! I Hope You can Coding Well======
Reply
#7

There are blank MySQL and SQLite gamemodes out there.
Search, look how SQL is done, and move on from there. Way better than files as reading/writing can lag the server if you plan on having shit loads of people.
Reply
#8

Quote:
Originally Posted by Amunra
Посмотреть сообщение
First, You can Make All codes On 1 Gamemodes .. But If you want to Make on Filterscript ..Not Probs
But You must Know How Much Filterscript and Gamemodes can Load Read Here !

Second,Mysql Is Look Better , But if you have a Confused you can Make On SQLite !
SQLite Is Not Dificult Which Mysql

====Good Luck For Coding again!! I Hope You can Coding Well======
Thank you, if I can't get MySQL done, then I will use SQLite.

Quote:
Originally Posted by itsCody
Посмотреть сообщение
There are blank MySQL and SQLite gamemodes out there.
Search, look how SQL is done, and move on from there. Way better than files as reading/writing can lag the server if you plan on having shit loads of people.
I'm not planning on having shit loads of people, just a bit of my friends and some other people, probs about 20 or so, but I think that MySQL is better in many ways, so I think I'm going to use that.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)