DshWinchester Posted December 22, 2009 Author Share Posted December 22, 2009 how works in a script?like,I wanna a script spell that give just 50% chance of worksI need do what?an exemple```rand = rand(1,2)select case randcase 1call setplayerstr(index,getplayerstr(index)+2)case 2call playermsg(index," you duck" , blue)```or something like thtat Link to comment Share on other sites More sharing options...
evilbunnie Posted December 22, 2009 Share Posted December 22, 2009 To use the Rand Function you use it like```Call Rand(1,5)```Or```Dim lolomglolomg = Rand(1,5)```Now 1 = The starting number and 5 = the last numberSo it would be chance out of 5. Link to comment Share on other sites More sharing options...
DshWinchester Posted December 22, 2009 Author Share Posted December 22, 2009 I will trythanks Link to comment Share on other sites More sharing options...
evilbunnie Posted December 22, 2009 Share Posted December 22, 2009 Ok```rand = Rand(1,2)Select Case randCase 1Call SetPlayerSTR(Index, GetPlayerSTR(Index) + 2)Case 2Call PlayerMsg(Index,"Wrong try again." , YELLOW)End Select```Fixed.EDIT Fixed again, You need to have a setplayerSTR Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now