Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to set a Global (Random) Integer?
ehovda321 Offline
Junior Member

Posts: 38
Threads: 22
Joined: Dec 2011
Reputation: 0
#1
How to set a Global (Random) Integer?

Would this work?

SetGlobalVarInt("buy_a", RandInt(7, 12));
SetGlobalVarInt("buy_b", RandInt(8, 14));
SetGlobalVarInt("buy_c", RandInt(3, 7));
SetGlobalVarInt("buy_d", RandInt(2, 6));

I want to set each GlobalVarInt to a Random Integer.

Thank you! Big Grin
03-13-2013, 09:42 PM
Find
NaxEla Offline
Senior Member

Posts: 415
Threads: 5
Joined: Dec 2012
Reputation: 28
#2
RE: How to set a Global (Random) Integer?

Yes, that would work.

Also, here's a tip: when you are scripting (or just programming in general) and you're not sure if something will work, just try it. It's not like you're computer will go up in flames if it doesn't work.

In Ruins [WIP]
03-13-2013, 11:41 PM
Find




Users browsing this thread: 1 Guest(s)