• 🏆 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!
  • ✅ The POLL for Hive's Texturing Contest #33 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!

[Spell] Help! Spell pick item

Status
Not open for further replies.
Level 26
Joined
Mar 19, 2008
Messages
3,140
Unfortunately, you are pretty restricted in picking random items.

  • Set p = (Position of <unit>)
  • Custom script: call MoveRectTo(udg_Rect, GetLocationX(udg_p), GetLocationY(udg_p))
  • Custom script: call RemoveLocation(udg_p)
  • Set item = (Random item in Rect)
Requires declaring global region: 'Rect' at map initialization trigger. Customize width and height.
 
Status
Not open for further replies.
Top