[GameMode] Y-Core + Y-RP development thread
#1



This project is under active development

This thread is for live updates of Y-Core and Y-RP (other Y-* projects will have separate threads). I'd like to ask you for features that all gamemodes should have, and RP gamemodes should have.

Y?

Because I can. Because it's practically YSI libraries showcase. Because I'm sick and tired of Raven's GM still being alive. And because I need your help to make this happen.

The goal

I'm dissapointed with underuse of YSI in the wild. Usually it's foreach and that's it. I want to create a bootstrap for all server owners - no matter the gamemode, no matter the server language. Y-RP will be the flagship, as my fondest memories are from playing on RP servers.

Y-Core?

Y-core is just a scaffolding for another scaffolding such as Y-RP. You can use Y-Core without any of the extensions, as everything is customizable from within config.

Installation

This is not a beginner friendly gamemode. It is not meant to be used without modifications. If you don't understand particular code excerpt, feel free to ask here or in github issues. I did not list Y-RP as a submodule, as it is optional, and in the future there'll be many gamemodes to choose from.
If you are having troubles with enviornment, feel free to use my create-samp-app tool to set up everything quickly.

Prerequisites Y-Core
  • Set up samp-server and compiler in default folders
  • Clone Y-Core
  • Copy gamemodes/config.inc.template to gamemodes/config.inc
  • (if using only Y-Core) Disable all Y_MODE_* modules
  • If using Y_PLAYER_REQUIRE_ACCOUNT, compile and run gamemodes/install.pwn
  • Done!
Y-RP
  • Install Y-Core as above
  • Clone Y-RP and unpack in Y-Core root folder
  • Enable Y_MODULE_RP in config.inc
Current features

Y-Core
  • Secure login and register system
  • Player vehicles
  • Vehicle dealerships
Y-RP
  • TBD
Download

Y-Core (github)
Y-RP (github)
Reply
#2

Interesting glad to see someone doing more with the YSI libary. Are you going to allow anyone to commit to the gamemode?
Reply
#3

Of course! I'm feeling a little alone with advocating for YSI, and I'll accept all pull requests (as long as they conform to my style guide and module structure). Also it's all licensed under MIT, so you can freely use it for your own purposes
Reply
#4

If this is a showcase of Y-Core, why do we need MySql when Y-core comes with y_ini?
Reply
#5

Mysql is required, I'm not using Y_ini. Why? I'm a fullstack webdeveloper and I'm working with SQL (MySQL/MariaDB flavour) every day. Even stupid stuff like: get a player with most money on the server. How would you do that using ini files? Either you create a new file collecting all players money and keep track of each and every money change of all players (this is somewhat similar to database indexes), or you open up all files of all players and get the biggest amount. File operations are slow, and in RDBMS such as MySQL it's just a matter of "SELECT MAX(money) FROM players". Also, I'm planning on creating an UCP for Y-Core, and you can't do that easily without a database.
Reply
#6

Interesting!

I was trying to do something similar with a framework I was developing (sampfw - San Andreas Framework), but being more focused on high-level features than low-level functionality. If my time frees up like I am expecting, and this shows some promise, this could definitely be used as a base for it.

I'll be watching this closely!
Reply
#7

Pretty neat I must say.

Rep+ From Me
Reply
#8

I got a little carried away doing factions. Editable by admins and specific faction rank levels, as set in config.inc












There is objects management to be finished (and custom commands) but factions are mostly done.
Reply
#9

Umm sounds like there's something new coming up on the table.
Reply
#10

good job Misiur, don't push yourself so you don't burn out too soon :P
Reply
#11

I think the lack of YSI use is due to little current and complete documentation.
Reply
#12

Quote:
Originally Posted by nG Inverse
Посмотреть сообщение
I think the lack of YSI use is due to little current and complete documentation.
Wrong, it's mainly because people are unaware of it's solutions and features it provide. Lack of awareness is the most common and first issue which is the base of other issues.

What one can do is put YSI tutorials in a link along with their examples on their thread. And that one individual only posts on their thread, and everyone puts a link to it in their (forum) signature, which will get attention of a lot of people.
Reply
#13

Quote:
Originally Posted by Logic_
Посмотреть сообщение
Wrong, it's mainly because people are unaware of it's solutions and features it provide. Lack of awareness is the most common and first issue which is the base of other issues.
Good documentation would cover all features/functionality, function lists, definitions, syntax restrictions, common warning/errors, etc. If it existed, people would be more informed, thus more willing to use the libraries.

I found myself searching for current documentation for two days on specific libraries and their functionality to no avail. At that point, I just recreated the features.
Reply
#14

Quote:
Originally Posted by Logic_
Посмотреть сообщение
Wrong, it's mainly because people are unaware of it's solutions and features it provide. Lack of awareness is the most common and first issue which is the base of other issues.

What one can do is put YSI tutorials in a link along with their examples on their thread. And that one individual only posts on their thread, and everyone puts a link to it in their (forum) signature, which will get attention of a lot of people.
Wrong, because it's a large library and it feeds off itself. People only want what they need.
Reply
#15

Misiur uhh, Why don't you use the regular pawn compiler? Is there any difference from the Zeex's or russian compiler?

I wanted to try this but it seems that my knowledge on scripting is far from being called Average Scripting skill, and it also seems that there are not much explanation on the Y-Less includes... I want to learn it but every documentation was removed when Y-Less left samp scenes
Reply
#16

Quote:
Originally Posted by JesterlJoker
Посмотреть сообщение
I wanted to try this but it seems that my knowledge on scripting is far from being called Average Scripting skill, and it also seems that there are not much explanation on the Y-Less includes... I want to learn it but every documentation was removed when Y-Less left samp scenes
If you don't know what it does or what it's for, then you probably don't need it.
Reply
#17

Код:
// Wrong
Function() {
	
}

// Right
Function()
{

}
You're aware that both are right?(And will compile fine) Right?
The only difference is that the second either a waste of space or is used for people to say how "good they are at coding that they made a 30k line code" when most of their code is coded like this;

Dunno why people say the second is "clearer", both are clear, just that the first has less "wasted lines"

You can also code like so
Код:
Code { 

    // code

}
I know that its a coding style, but it's not conventional, its randomatic and you haven't limited it to the code on your repo but generally emphasized that coding should be done with line breaking brackets only. (which is in my personal opinion, wrong and I rather avoid from using a library that forces me to do break lines)

Moreover, y_inline afaik supports both inline and line-broken brackets (like foreach)
Reply
#18

Not sure if YSI is production "friendly", last time I used it back in 2014 it was pretty hard to debug your code when something goes wrong. Memory corruption was one of the things, I guess people just don't want to deal fixing YSI themselves, it's a large lib and requires skill and time to understand/fix. I guess the vast majority of popular servers / servers with large player base don't use it apart from standalone foreach (in YSI known as y_iterate).
Reply
#19

Quote:
Originally Posted by Kaperstone
Посмотреть сообщение
Код:
// Wrong
Function() {
	
}

// Right
Function()
{

}
You're aware that both are right?(And will compile fine) Right?
The only difference is that the second either a waste of space or is used for people to say how "good they are at coding that they made a 30k line code" when most of their code is coded like this;

Dunno why people say the second is "clearer", both are clear, just that the first has less "wasted lines"

You can also code like so
Код:
Code { 

    // code

}
I know that its a coding style, but it's not conventional, its randomatic and you haven't limited it to the code on your repo but generally emphasized that coding should be done with line breaking brackets only. (which is in my personal opinion, wrong and I rather avoid from using a library that forces me to do break lines)

Moreover, y_inline afaik supports both inline and line-broken brackets (like foreach)
Of course he knows! This is his project, and he should choose how he wants people to contribute regardless if it's something as small as that. Personally I probably wouldn't care to much for that, but if you want everything to be similar to another style of code then so be it, and I'm sure he's not going for lines as he's trying to mimic a modular setup so unless he wants to brag about a few extra lines I doubt it's for that cause.

I wouldn't really say it's a waste of space it's more of how the person maintaining the project wants to look at it. It's really not that big of an issue.
Reply
#20

It is just a style guide, I am aware both are correct. We dont have something like eslint (yet) but I'd like to pull requests to be consistent with my style
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)