Issue338

Title Show status (paralysis, slowdown) countdown in game
Priority feature Status resolved
Assigned To greg Keywords
Linked issues Watchers greg, jesusalva

Submitted on 2011-07-24 19h08 by tracker_migration, last changed by matthiaskrgr.

Messages
Author: tracker_migration Date: 2011-01-31   06h58
Submitted by salimiles
I think it would be useful to have a some indication of how much longer Tux will be in certain states (like invisibility).
Author: tracker_migration Date: 2011-01-31   07h53
Posted by salimiles
Opps. This should be in "feature requests". Moving it there.
Author: tracker_migration Date: 2011-03-21   09h51
Posted by ahuillet
Yes, on top of the player in the 3D view rather than the HUD, though.
Author: jesusalva Date: 2014-01-06   21h12
This appear really important, because it kind of suck sometimes when you active
a skill, are on the middle of a important thing and suddently it ends. Also when
you are paralyzed, because sometimes it appear to take an eternity.

This would help too much the players, because them could know when the skill is
going to end and apply it again.
Author: matthiaskrgr Date: 2014-01-13   20h05
Yeah, maybe we can just copy the health-bar implementation to represent a
countdown and display it over tux instead? (although some circular thingy would
probably look way cooler :) )
Author: jesusalva Date: 2014-01-15   18h09
For start, us could just print numbers. It is not too hard this way. But a
circular thing (like a clock) is really way cooler ;-).

A bar... Hmm... Not cool imo. There would need be a lot of bars. Too messy, I think.
Author: jesusalva Date: 2014-04-10   01h11
EXPERIMENT: Playing with tux colors
==============================
INSTRUCTIONS:

In view.c:1980 change
		b = 0.2;
to
		b = 0.2 * Me.paralyze_duration;
======================================
TESTING

To test it, use the Emergency Shutdown skill on 2nd revision.
======================================
EFFECT

Tux will start purple, then as the time goes, it will be red and when it
oversaturate (be somewhat orange) the skill time will end and Tux will return to
normal.
===========================
THEORY

We will multiply 0.2 by the paralyzed duration, making Tux's color vary as the
time is decreasing, making easy to understand that the time is ending.
Experimental Table:
Paralyzed_Duration | Blue amount (0.2 * Paralyzed_Duration)
25.0 | 5.0
10.0 | 2.0
05.0 | 1.0
01.0 | 0.2
0.75 | 0.15
00.5 | 0.1
0.25 | 0.05
00.0 | 0.0

With this we conclude that we will have excessive blue at the start, making Tux
purple. Because values greater than 1.0 are ignored, Tux will remain purple util
the timer strikes 5 seconds. Then, blue will start fading away, giving a red
impression util 1 second left, Then blue will be lower than green and Tux will
start getting yellow, but before Tux strikes yellow (what is impossible because
green value is 0.2) the counter reaches 0 and the effect ends.

We can obtain the inverse by changing the multiplication to a division (instead
of purple - red - orange, orange - red - purple).
The same effect can be obtained changing the multiplication by a sum, but this
is not recommended. WARNING: subtraction is not supported!

NOTE: Utilizing
b=0.2 * (Me.paralyzed_duration/2);
Proved to be much better.

===========================
OTHER EXAMPLES
I got the yellow formula:
		g = 0.2 + (r+0.1);
		b = 0.2;
		r = 0.2 * (Me.paralyze_duration/2) + 0.5;
Author: jesusalva Date: 2014-04-10   01h15
PATCH THAT FIXES THIS BUG:
http://rb.freedroid.org/r/2047/
RR 2047
by Gregory Lozet
Author: matthiaskrgr Date: 2014-07-02   21h54
Implemented as 64698ff7e93adf9153efd9fad63c10b811fea957 via Review Request 2047 :)
History
Date User Action Args
2014-07-02 21:54:49matthiaskrgrsetstatus: open -> resolved
assignedto: greg
messages: + msg2835
nosy: + greg
2014-04-10 01:20:08jesusalvasetnosy: + jesusalva
2014-04-10 01:15:54jesusalvasetmessages: + msg2753
2014-04-10 01:11:25jesusalvasetmessages: + msg2752
2014-01-15 18:09:23jesusalvasetmessages: + msg2687
2014-01-13 20:05:11matthiaskrgrsetmessages: + msg2682
2014-01-06 21:12:31jesusalvasetmessages: + msg2660
2011-07-26 11:58:27matthiaskrgrsetpriority: bug -> feature
2011-07-24 19:08:03tracker_migrationcreate