[FilterScript] [MySQL]New MoneyBag System
#1

New MoneyBag System


Introduction:


Hello,

i noticed in nowdays the most servers are using the old moneybag system that use strcmp command and old functions + is not optimized at all,
so i created new with the most optimized functions, and fastest functions (MySQL), i don't forgot credits for [HiC]TheKiller because i got inspired by his work ofc


Features:


- Fast loading postions MySQL

- easy to add your own clues and pos's

- easy to deleted it too

- script so optimized

- Support 2 saving modes SQLite / MySQL

- fast loading and setup


How to install it ?:


- Download it (mediafire) | copy it (pastebin)

- as you see in script there some places must be edited and some others not

PHP Code:
// --------------< this must be edited without it FS will not work >--------------
#define USE_MYSQL 1 // un-comment this and comment USE_SQLITE to use MySQL
#define USE_SQLITE 0 // un-comment this and comment USE_MYSQL to use SQLite
 
#define MySQL_Host     "localhost" // hostname of your mysql server if you are using xampp use "localhost"
#define MySQL_User     "root" // username for your mysql database
#define MySQL_Database "test" // database that server will connect to it
#define MySQL_Password "" // password of the database (user) that server will connect to it
 
// --------------< you can edit this if you want >--------------
 
#define MAX_MONEYBAGS 150 // max moneybags that can be stored in database
#define MB_DELAY 30 // how many time moneybag re-spawn
 
#define MAX_MONEYBAG_MONEY 37000 // Max of money that can moneybag handle
#define MIN_MONEYBAG_MONEY 13000 // Min of money that can moneybag handle
 
//#define WEAPONS_BOUNS // un-comment this if you want player get weapons bouns from moneybag
 
#if defined WEAPONS_BOUNS
 
#define MAX_WEAPONS_AMMO 1500 // Min of ammo that can be given to a player
#define MIN_WEAPONS_AMMO 200 // Max of ammo that can be given to a player 
* edit mysql informations
- Complie it

- copy *.amx file to filterscripts in your server folder

- add it in Server.cfg

- restart server

- well done

Commands:

- /savemb or /savemoneybag

- /delmb or /deletemoneybag

- /mb or /moneybag

- /tmb or /togglemb

How to add a moneybag?:

just get ingame and use /savemb or /savemoneybag with name!

enjoy!

same for delete /delmb


Download Link:


Pastebin: http://pastebin.com/RR3uSEPH
Mediafire: http://www.mediafire.com/file/f31aij...eyBag%282%29.p

**Note: *.p = *.pwn just open it using your pawn complier and complie it


Credits:


- SA-MP Team
- Zeex
- BlueG
- [HiC]TheKiller
- Jelly23
Reply
#2

Nice 9/10
Reply
#3

Nice,
Reply
#4

I like it, just because its MYSQL
Reply
#5

Quote:
Originally Posted by Scripter18
View Post
I like it, just because its MYSQL
Scripter18, you're starting being rude so much, pls some of your friendly
Reply
#6

Thanks everyone
Reply
#7

Quote:
Originally Posted by RyderX
View Post
Scripter18, you're starting being rude so much, pls some of your friendly
And what it has to do with this topic?

OT: Good job.
Reply
#8

Nice one man Hope u Make another good FS!
Reply
#9

Updates:

Bug fixes: Nothing.

New Features:

- Now support SQLite saving mode!

- global variables are changed to static thanks to Jelly23

- optimized and removed *stock* key from the script (stop abusing it!)

- strings sizes are now very good.

Thanks you all for you feedbacks
Reply
#10

For a simple release at least you pulled it off and there is some depth to this system. Almost any money bag script would be deleted these days but you somehow found a way to avoid that.
Reply
#11

Quote:
Originally Posted by Pottus
View Post
For a simple release at least you pulled it off and there is some depth to this system. Almost any money bag script would be deleted these days but you somehow found a way to avoid that.
Thanks for your feedback
Reply
#12

Well scripted, good job!
Reply
#13

Ok, nice work
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)