SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts > Includes

Thread Tools Display Modes
Old 14/04/2015, 03:16 PM   #1
Misiur's Avatar
Join Date: Jul 2009
Location: Poland
Posts: 2,530
Reputation: 552
Default YSI 3.1

Disclaimer: Whole YSI project was published under MPL 1.1 license


There are a range of libraries included in YSI, most described in their own topics, all included in the download at the end of this post. Those with no link below will hopefully get documentation soon. Some of the libraries are very low level programming, others are very high level extended SA:MP functionality. I've attempted to split the list up, but the divide is largely arbitrary.

Links marked as "Old" may have out of date information due to changed syntax etc, but could still be useful for getting an idea of how the library works.
  • Low Level
  • y_als - Slightly simplifies the use of the Advanced Library System.
  • y_amx - Low level AMX information access. Used by y_hooks, y_testing and y_timers to list public functions.
  • y_bintree - PAWN binary tree implementation.
  • y_bit - Bit arrays for PAWN - vastly reduces memory usage for true/false arrays.
  • y_cell - Some clever bit-level variable manipulations.
  • y_debug - Compile time macros for displaying, or not, debug information at run time.
  • y_files - A plugin with some useful file functions. Not included in the download below.
  • y_hooks - Allows you to hook any callback with no effort at all.
  • y_ini - This is the fastest ini file system around, designed to load entire files at once.
  • y_inline - Allows for the declaration of inline functions in PAWN.
  • y_iterate - foreach, but in YSI.
  • y_malloc - Allocate and free memory as required.
  • y_master - Code for the master system. See this topic and y_commands for more information.
  • y_php - Fast and efficient two-way communication with PHP. Requires shmop.
  • y_playerarray - Bit arrays optimised specifically for arrays of players.
  • y_playerset - Call functions passing groups, single players, arrays, or playerarrays as the "target" parameter.
  • y_remote - Wrappers for "CallRemoteFunction" and "CallLocalFunction".
  • y_scriptinit - Provides "OnScriptInit" for both gamemodes and filterscripts.
  • y_stringhash - Allows you to treat strings as numbers for things like "switch" statements.
  • y_testing - Allows for very simple unit testing production.
  • y_timers - Simplifies the creation of repeating timers, balancing them for optimal server performance. Also allows for the simple definition of functions to be called once after a delay.
  • y_utils - Random useful functions.
  • y_va - Variable argument functions such as va_printf and va_format.
  • y_writemem - WINDOWS ONLY! Write to arbitrary memory addresses in the server memory.
  • y_xml - XML file reading and writing.
  • High Level
  • y_areas - Manage zones on the map, with players entering and leaving.
  • y_classes - Allows for extra dynamic class selection screens, different users can have different skin options and you can add and remove classes dynamically.
  • y_colours - AKA y_colors. Defines a vast number of colours and provides both definition and string access to them.
  • y_commands - This is a commands system designed for managing hundreds of commands at once, unlike others which are only designed for small numbers of commands. It offers many improvements over other systems including the speed of ZCMD with dynamic command renaming, dynamic per-player permissions and dynamic /commands and /help abilities to list all commands and help on those commands.
  • y_dialog - Show dialogs to players with no worry about IDs and with inline functions available.
  • y_flooding - Restrict the number of connections from a single IP and set what happens if they go over that number (kick the new one, kick them all or ban the IP).
  • y_groups - Defines generic functions for groups, an abstraction from all other collections of users such as admin levels and gangs.
  • y_languages - Holds language information on all players, as well as languages loaded in the system.
  • y_lock - Restricts the server to run on only the IP specified by in "bind".
  • y_svar - Server information that is automatically saved and loaded.
  • y_td - Text draw style functions for better dynamic updates.
  • y_text - The biggest addition to this version. The y_text library provides functions for displaying, styling, and translating, messages dynamically. Allowing you to change the apperance of text entirely without editing or recompiling your mode. It also handles multiple languages transparently and adds features such as colour fades and new format specifiers.
  • y_users - Full user system with login and registration functions.
  • y_uvar - Per-player variables with automatic loading and saving.
  • y_zonepulse - Fade gang zones from one colour to another and back.

Generic Topics

Errors and Warnings
Writing libraries with YSI

Function List

The download now includes "". This file provides PAWNO with a complete function list for the WHOLE of YSI. It will also include most of YSI if you add it to your mode, but you can just use individual files as before.

Click here for a sneak-preview of the function list:

The functions are divided by library, and also grouped by functionality, with the more advanced functions being lower down. Most of the time you can get away with only ever using the top couple of functions in a library.

Last edited by Misiur; 14/04/2015 at 05:24 PM.
Misiur is offline   Reply With Quote
Old 15/04/2015, 02:29 AM   #2
Join Date: Jun 2013
Location: Argentina.
Posts: 2,067
Reputation: 827
Default Respuesta: YSI 3.1

Nice, this will help many people
Swedky is offline   Reply With Quote
Old 15/04/2015, 02:46 AM   #3
Gammix's Avatar
Join Date: Jan 2015
Location: Canada
Posts: 1,825
Reputation: 833
Default Re: YSI 3.1

Not much help. Most of the people don't know proper methods and way of using most of the libraries.
I could be good if we had those long page documentations he wrote a long time ago!

My GitHub:

Gammix is offline   Reply With Quote
Old 15/04/2015, 03:00 AM   #4
Join Date: Dec 2013
Location: GetPlayerPos(playerid, pos); Scripter/Mapper.
Posts: 3,410
Reputation: 439
Default Re: YSI 3.1

You can always find cached versions of the threads with things such as, which will allow you to access a (if applicable): ****** cache store, store, etc for most threads.
Abagail is offline   Reply With Quote
Old 15/04/2015, 05:52 AM   #5
Crayder's Avatar
Join Date: Sep 2013
Location: Flames of Hell
Posts: 3,837
Reputation: 607
Default Re: YSI 3.1

@Misiur: You should go clone this -

That is the actual latest by Y-Less. I put that and sscanf 3 (both the very latest) on, though I'm not the type of person to take any responsibility. It seems you are so go take those! We need to all get together and bring back all of the cached tutorials and actual threads before they are gone completely.
Those who deserve reputation, do not need to beg for it.
Also, don't expect the help you need when offering reputation, you'll just be attracting Rep Hunters.
Join SA-MP Discord!
Crayder is offline   Reply With Quote
Old 16/04/2015, 12:59 PM   #6
Misiur's Avatar
Join Date: Jul 2009
Location: Poland
Posts: 2,530
Reputation: 552
Default Re: YSI 3.1

Ok, I've updated to latest Y_Less commit and started adding features onto that. Thanks Cryder!
Misiur is offline   Reply With Quote
Old 18/10/2016, 04:18 AM   #7
Huge Clucker
[DK]Dark_Knight's Avatar
Join Date: Apr 2008
Location: New Zealand
Posts: 390
Reputation: 18
Default Re: YSI 3.1

Does anyone still have the 3.1 of YSI. I can only find version 4 and up. Y_Classes doesnt work at all on version 4. but it did in version 3.1
[DK]Dark_Knight is offline   Reply With Quote
Old 12/01/2017, 02:34 AM   #8
Huge Clucker
Join Date: Jan 2017
Posts: 307
Reputation: 40
Default Re: YSI 3.1

I see a lot of activity on that github page and i was wondering is that YSI stable? I have an old copy of YSI and it works for me so is there a reason to upgrade? Any bug fixes etc. ?

EDIT: I was thinking about this, not the link in the first post:

Last edited by wallee; 12/01/2017 at 04:06 PM.
wallee is offline   Reply With Quote
Old 12/03/2017, 07:58 PM   #9
Little Clucker
Join Date: Mar 2014
Posts: 46
Reputation: 4
Default Re: YSI 3.1

i include, and when i use the Y_ini it crashes my samp editor...

This only crashes samp editor, doesn't crash when I do it with pawno

Last edited by Sibuscus; 16/03/2017 at 10:15 AM.
Sibuscus is offline   Reply With Quote
Old 11/08/2017, 10:14 AM   #10
Join Date: May 2013
Posts: 118
Reputation: 7
Default Re: YSI 3.1

Is there any benchmark or performance/speed test for YSI libs?
Yousha is offline   Reply With Quote

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

All times are GMT. The time now is 11:01 PM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.