Should I switch to YSI/y_ini?
#1

Hi guys.

So I've been making a RolePlay server for past 2 years and for the whole time I've been using Dini to save a lot of information like my house system, player save system, job system and lots of other things. I find Dini very easy to use and that's why I never tried to learn y_ini or something like that. I once read the y_ini tutorial and it seemed like it's a lot harder than Dini, but I don't think it really is, and I don't know if I should switch to it.

So basically my question is, should I switch to y_ini and start learning it or is it okay to use Dini while there aren't more than 100 players on the server.

And is there a fast way to change every save system in the whole script from Dini to y_ini?

Sorry if "Scripting Help" is the wrong section for my question, I just didn't know where to post it.

Thanks in advanced!
Reply
#2

I'm going to break my 1337 post count for this but I'll tell you something...

This question has been asked countless amounts of time. Using Dini is a mistake since it's very poorly slow and was made just to ease out to work with files, but later we got to see SQLite implementation and MySQL plugins in SA-MP.

Many people go forward to learn different saving systems rather than SQL because they think it's hard or useless, whereas SQL is a different language. It's not something that you'll just use in your SA-MP modifications, but also when you work with web development, and other projects.

SQL provides database relations and so much features, that it's something that you should use as a saving system rather than other INI/ file based solutions that are not just slower, but also come up with bugs and other issues. For example, if you need help with a INI file, many people would just give their guesses but if you get stuck with SQL, you will not just find SA-MP forum to help you with that, but also different websites and communities.

Also, there's no fast way to convert anything to a different saving system, take your time and do your changes slowly since you're new to it. Put your time in learning it and adapting your script to it and to be just dependent of it.

SQLite is a built-in native implementation in SA-MP server and it doesn't require a SQL server to store the database, it saves it in scriptfiles folder. Whereas MySQL requires use of external plugins and is way faster than SQLite, for it's own reasons. MySQL allows you to show your data on your websites incase if you want to have a UCP or something similar. SQLite also provides this feature but your server and website should be on one machine.

SQLite in my opinion is an overkill for SA-MP. So you should just stick to it if you don't want to go for MySQL.

I've built lots of Call of Duty TDM scripts, some roleplay and I've sticked to SQLite for most of them since they are just enough and you won't need MySQL unless you want your project to be Hi-Fi.

---

EDIT: Quoting ****** from an older post:

"I've said this before. People think that MySQL is some simple plug-and-play magic bullet that you can use to just make your mode instantly better. They don't realise that the "L" in "SQL" means "language". So instead of programming PAWN, and using a bit of this mystery thing, you are now programming in two languages at once. If you spend months learning PAWN, you should spend the same time learning SQL, if not more - it is probably the more complex of the two languages, and not something that just gets bolted on to the side."
Reply
#3

I have to totally concur with _logic.
SQL gives you much more features and is just alot easyer to use.
For example when creating a character system for my gamemode. SQL made this ridicolously easy for me while i never managed to get it done with dini/y_ini. (some problems with id's and other things.)
So the best you could do is to start with SQL. It isn't that hard after all. Just experiment a little with it.
Reply
#4

Yeah I know that this question has been asked for many times I just wanted someone to break it up for me. I kinda want to open the server in the close future so I don't have time to learn MySQL. Also I found many bugs with Dini and sometimes it screws up my savefile. Dini sometimes bugs out and deletes everything inside of the INI file. Also my server crashes sometimes I don't know exactly if it happens due to Dini beeing too slow to withstand my saving systems. Anyway thanks for helping out!
Reply
#5

Quote:
Originally Posted by jasperschellekens
Посмотреть сообщение
I have to totally concur with _logic.
SQL gives you much more features and is just alot easyer to use.
For example when creating a character system for my gamemode. SQL made this ridicolously easy for me while i never managed to get it done with dini/y_ini. (some problems with id's and other things.)
So the best you could do is to start with SQL. It isn't that hard after all. Just experiment a little with it.
Yeah I'll read some tutorials for it and see if I'm gonna use it or not. Thanks
Reply
#6

Just a tip, use the edit button and avoid double posts
Reply
#7

Quote:
Originally Posted by Logic_
Посмотреть сообщение
Just a tip, use the edit button and avoid double posts
Yeah I forgot about that

One more question, if I switch to y_ini from Dini, are my INI files going to stay the same way and can I just continue saving and loading from the same files?
Reply
#8

Should be fine but depends on your code since Y_INI uses tags. But why Y_INI?
Reply
#9

I don't know, it's kinda similar do Dini and not hard to learn, but it's a lot faster.
Reply
#10

Quote:
Originally Posted by andrejc999
Посмотреть сообщение
I don't know, it's kinda similar do Dini and not hard to learn, but it's a lot faster.
Just use SQL. It is really easy to learn. Everyone who learned pawn can also learn sql. Its absolutely not even hard.
Things like bugged savefiles like in dini/y_ini will not happen anymore.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)