• 🏆 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!

[Trigger] Item Drop System

Status
Not open for further replies.
Level 3
Joined
Aug 19, 2020
Messages
38
Greetings everyone,
I would like to make a item drop system that when item drops, it has a floating text which tells you what dropped.
But I do not know how to achieve it, anyone please help?
For example,
A wolf is defeated and it drops 3 items
there will be a floating text " Item A, Item B, Item C dropped"

I can't find any drop system with floating text :(
 

Uncle

Warcraft Moderator
Level 64
Joined
Aug 10, 2018
Messages
6,510
Just to clarify, how do you want the floating text to look?

One long line of text?
"Claws of Attack +9, Robe of the Magi +6, Kelen's Dagger of Escape"

OR broken up 1 by 1:
"Claws of Attack +9"
"Robe of the Magi +6"
"Kelen's Dagger of Escape"

And it's really quite simple to do, you just store the names of the Items that dropped in String variables and create Floating Text using these stored Strings.
Here's a rough idea:
  • Create Item A
  • Set ItemName[1] = Name of Item A
  • Create Item B
  • Set ItemName[2] = Name of Item B
  • Create Item C
  • Set ItemName[3] = Name of Item C
  • Create Floating Text "ItemName[1] + ", " + ItemName[2] + ", " + ItemName[3]"
  • etc...
 
Level 3
Joined
Aug 19, 2020
Messages
38
first of all, thanks for replying.
I figured it out myself but I wonder if there are better ways to do it.

My trigger is something like

random number to decide whether item drops or not
if drop , set floating text to the item's name
then for the next item,
check if text is empty or not,
if it is not empty, set floating text = floating text + , + another item name
 

zam

zam

Level 3
Joined
Jan 1, 2021
Messages
31
Problem is floating texts have a limit of 100 per player which are also affected by evasion, critical strike, terrain evasion and possibly shadowstrike. Unsure if I forgot any... It'd be worth while looking into how to use images.
Does not matter as long as you remove them constantly.
 
Status
Not open for further replies.
Top