• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Improved floating texts help needed

Status
Not open for further replies.
Level 1
Joined
Jun 13, 2008
Messages
132
Hi there people, I am making a big rpg and I am trying my best with this project, currently my floating texts system shows a lot of floating texts when you deal a lot of instances of damage in a short period of time, this makes my game look ugly, I would like to know a way to make floating text refresh and show the total of damage dealt, for example, if you dealt 20 damage points, and then you deal 22 damage points, your floating text of 20 damage points changes to 20+22 (44).
Other thing I would like to know is, how can I make my floating texts get bigger and then get smaller?
 
Level 25
Joined
Jul 10, 2006
Messages
3,315
Firstly, to stagger the texts:
You'll need two triggers.

Trigger 1:
When a unit takes damage, set a DamageTaken[unit id] real variable to DamageTaken[unit id] + event response - damage taken.
Add this unit to a group for later reference.

Trigger 2:
Period event, every 0.5 seconds or so (however often you want it)
Display that DamageTaken[unit id] value above each unit in the abovementioned group.
Reset DamageTaken[unit id] to 0.

Next, to change the floating text sizes. You'll need to instance every floating text in an array, and periodically (every 0.03 sec) loop through them and increase/decrease as necessary.
 
Level 1
Joined
Jun 13, 2008
Messages
132
Firstly, to stagger the texts:
You'll need two triggers.

Trigger 1:
When a unit takes damage, set a DamageTaken[unit id] real variable to DamageTaken[unit id] + event response - damage taken.
Add this unit to a group for later reference.

Trigger 2:
Period event, every 0.5 seconds or so (however often you want it)
Display that DamageTaken[unit id] value above each unit in the abovementioned group.
Reset DamageTaken[unit id] to 0.

Next, to change the floating text sizes. You'll need to instance every floating text in an array, and periodically (every 0.03 sec) loop through them and increase/decrease as necessary.

Thank you very much! however, now I will need to make a mui system to handle all the stuff, this is going to kill me >.< +rep. for you.
 
Status
Not open for further replies.
Top