Raised This Month: $51 Target: $400
 12% 

Trigger function with % chance


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Airkish
AlliedModders Donor
Join Date: Apr 2016
Location: Lithuania
Old 02-22-2017 , 04:24   Trigger function with % chance
Reply With Quote #1

I want function to be triggered with 5% chance but I'm getting error

PHP Code:
number of arguments doesn't match definition 
So what I'm doing (or at least I think it should do like that)
Every round start it gets a random number from 1 to 100 if number is equal or below 5 then it does CmdKnifeRound

PHP Code:
public RoundStart() {
    if(
random_num1100) <= 5) {
        
CmdKnifeRound;
    }

Any help?
__________________
Airkish is offline
 



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

Forum Jump


All times are GMT -4. The time now is 13:15.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode