|
|
#1 |
|
Huge Clucker
![]() ![]() ![]() Join Date: May 2006
Posts: 434
Reputation: 341
|
GVar Plugin v1.3
This plugin is an extension to the per-player variable (PVar) system introduced in SA-MP 0.3a with a few key differences:
Changelog v1.3:
Refer to changes.txt in the server package for the full changelog. Definitions pawn Code:
Natives pawn Code:
Instructions Create a directory called "plugins" inside of the server directory if one does not already exist. Place the plugin file (gvar.dll or gvar.so) inside of this directory. Add the following line to server.cfg so that the plugin will load the next time the server starts: Windows: Code:
plugins gvar.dll Code:
plugins gvar.so pawn Code:
Recompile the scripts with any desired natives and callbacks provided by the include file. Start the server. Notes
Download Server Plugin (Windows and Linux) (Mirror) Source Code (Cross-Compatible) (Mirror) The Windows version requires the Microsoft .NET Framework 4.0 or higher. Last edited by Incognito; 21/10/2012 at 10:43 PM. |
|
|
|
|
|
#2 |
|
High-roller
![]() ![]() ![]() ![]() ![]() Join Date: Mar 2008
Location: Slovenia
Posts: 2,606
Reputation: 59
|
Wow thank you very much for this
.Just one question. Why didn't you make it like in your streamer so: Code:
native Streamer_SetIntData(type, {Text3D,_}:id, data, value);
native SetGVarInt(type, id, varname[], int_value);
|
|
|
|
|
|
#3 |
|
Gangsta
![]() ![]() ![]() ![]() Join Date: Feb 2009
Posts: 628
Reputation: 35
|
Assuming that the memory isn't an issue, isn't it slower than using pawn structures?
Anyway, good job, and thank you for helping samp community! Mike. |
|
|
|
|
|
#4 |
|
Banned
![]() Join Date: Dec 2008
Posts: 236
Reputation: 0
|
Amazing job again, Incognito!
|
|
|
|
|
|
#5 |
|
Huge Clucker
![]() ![]() ![]() Join Date: May 2006
Posts: 434
Reputation: 341
|
$€ЯĢ: This wasn't really designed for complex data structures, though I do see your point. The absence of a player ID means that some other form of identification would be useful to have. I think it would work much better as an optional parameter, though, as it's not always needed:
pawn Code:
Therefore, rather than doing this: pawn Code:
You could do this instead: pawn Code:
I'll see about adding that parameter to the natives later, but it will require some additional checks. Sma_X: Yes, it will be slower due to function overhead, but it consumes less memory (in most cases) and can be used for inter-script communication. |
|
|
|
|
|
#6 |
|
Big Clucker
![]() ![]() Join Date: Aug 2009
Posts: 183
Reputation: 0
|
Nice!
|
|
|
|
|
|
#7 |
|
Big Clucker
![]() ![]() Join Date: Dec 2008
Posts: 63
Reputation: 0
|
I was thinking of something like this and what do you know
![]() Very Nice! Keep up the good work |
|
|
|
|
|
#8 |
|
Big Clucker
![]() ![]() Join Date: Aug 2009
Posts: 183
Reputation: 0
|
-
|
|
|
|
|
|
#9 |
|
High-roller
![]() ![]() ![]() ![]() ![]() Join Date: Aug 2009
Location: United States
Posts: 1,505
Reputation: 154
|
very nice, keep up the good work!
|
|
|
|
|
|
#10 |
|
Huge Clucker
![]() ![]() ![]() Join Date: Aug 2009
Posts: 322
Reputation: 0
|
Niceeeeee
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [Plugin] [REL] DNS Plugin v2.4 | Incognito | Plugin Development | 79 | 21/03/2013 02:32 PM |
| Plugin Help | [EpK]Lulz | Server Support | 3 | 30/04/2010 10:34 AM |
| [Include] [INC] Глобальные переменные (GVar) | MX_Master | Релизы/Releases | 5 | 29/03/2010 02:54 PM |
| irc plugin | [HKS]dlegend | Help Archive | 19 | 06/12/2009 08:50 PM |