SA-MP Forums Archive
[FilterScript] First FileterScript (Lottery) - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+--- Thread: [FilterScript] First FileterScript (Lottery) (/showthread.php?tid=472362)



First FileterScript (Lottery) - Brandon_More - 28.10.2013

Well there isn't every much to say.. just been working on this for around 1 and half hours. (Testing as well)

Administrator chooses the Lottery Number (Maximum: 500), Price (Minimum: 2,500 - Maximum: 500,000), Prize (String and Digits) and the Range (Maximum 500)

RANGE:

Range is the numbers that can be chosen in order to keep control of the lottery.. Example: I need to do this multiplication error, all I know is that it is between 5 and 60. That would be an example of the range.

LOTTERY NUMBER:

Lottery number is the number it's self. Simple enough huh?

PRICE:

Price of the lottery ticket, charged even if you loose. You can have the maximum fee of 500k and no less than 2.5k (Change in source code)

PRIZE:

Prize is the reward for testing your luck, this can be anything from Vehicle to hand money. Simple.

If the person wins everyone in the server receives a message notifying that it's over as well as telling them the winner. The person will also be frozen until you go to him.

This is a Custom lottery - Meaning you will be the one giving them the reward (TP'ing to the person)

COMMANDS:

/startlot >> This will send a message to everyone on the server notifying them that a Lottery event has begun with the details of: Prize, Price & Range.

/lot >> This is the command that you type to test and see if you won.. Simple enough

/stoplot >> This will stop the lottery and return all values to default.

/changelot >> This will change the lottery number to another and notify the whole server.

I WOULD SS, BUT I AM USING WIN 8 AND.. IT BUGS ALL THE TIME

If anyone needs me to convert the script (Variables..ECT) I will be more than happy to help

DOWNLOAD (You will need: zcmd.inc & a_samp.inc):

http://pastebin.com/XfwXQLnN

Please don't comment if you don't have anything good to say this is my first Filterscript..

Sorry for appearance of FS...



Re: First FileterScript (Lottery) - BodyBoardVEVO - 28.10.2013

Any screenshot ?


Re: First FileterScript (Lottery) - Brandon_More - 28.10.2013

I said I can't ScreenShot becasue I am using Windows 8 and it get's a-bit buggy..


Re: First FileterScript (Lottery) - Sgt.TheDarkness - 28.10.2013

Very nice script, very simple.

However, I do suggest that you work on your indentation, perhaps a global timer to control timed lottery events? Or even a random giveaway event?