xelander Posted July 13, 2009 Author Share Posted July 13, 2009 Yah, i would like to know the command for random.and will this script work if so?```Case "/Randomtip"dim TT = (the random command from 1 to 3)if T = 1 thencall playermsg(index,"rawr tip 1",1)else if T = 2 thencall palyermsg(index,"rawr tip 2",1)else if T = 3 thencall palyermsg(index,"rawr tip 3",1)end ifexit sub```i would like some help here. Link to comment Share on other sites More sharing options...
Owen F Posted July 13, 2009 Share Posted July 13, 2009 EndIf no space,ElseIf no spacerandom from 1 to 3 would be: Rand(1,3)Typ-o in your two last PlayerMsg'sin spite of how many people do it, Dimming is entirely unnecessary in VBScript Link to comment Share on other sites More sharing options...
xelander Posted July 13, 2009 Author Share Posted July 13, 2009 ok thank you alot! :3 Link to comment Share on other sites More sharing options...
Owen F Posted July 13, 2009 Share Posted July 13, 2009 No problem! :) Link to comment Share on other sites More sharing options...
Admiral Refuge Posted July 13, 2009 Share Posted July 13, 2009 Also, if you're going to be comparing something to multiple values, it's best to use the select case statement, e.g.> **Case** "/Randomtip"> **Dim** T> T = Rand(1, 3)> **Select Case** T> **Case** 1> **Call** PlayerMsg(Index,"rawr tip 1",1)> **Case** 2> **Call** PlayerMsg(Index,"rawr tip 2",1)> **Case** 3> **Call** PlayerMsg(Index,"rawr tip 3",1)> **End Select** Link to comment Share on other sites More sharing options...
xelander Posted July 13, 2009 Author Share Posted July 13, 2009 Ok thanks alot you too. ;) 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