• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Dice Rollin???

Status
Not open for further replies.
Level 3
Joined
Nov 3, 2006
Messages
23
Hi Guys :cidea: i want to make a trigger with something like "Dice Rollin". For example when a creep dies the WE chooses a random number betwenn 1-10 or 1-6 or whatever, and when it rolls a 1 or 2 it does nothing, 3 it drops certain item, 4 Drops Potion and so on... Can u help please?
 
Level 9
Joined
Oct 24, 2007
Messages
421
Try using the following actions

'set variable ''integer'' to ''math random number between'' 1 - number of events

' if ''integer equal to 'one event' then 'create 1 item of type ''item made'' at position of dying unit'
else do nothing

and use if then elses for each possible outcome
 
Status
Not open for further replies.
Top