Game Development Community

Lava Damage

by Tom Feni · in Torque Game Engine · 12/04/2003 (6:55 am) · 2 replies

I have implemented lava and when I jump in I only lose about 3/4 of my health and I can run around and not die under the lava.. but when I leave and jump back in I die... so how can I make it kill instantly at full health?
I played with the lava damage scale but it still does the same thing.. I only used the player.cs script.. is lava commented somewhere else?
as in damage amounts?
thanks for any help in advance :)

#1
12/04/2003 (7:56 am)
Change

$DamageLava = 0.01;

at the top of player.cs

to something like

$DamageLava = 100;

That should do it.

Or in Armor::onEnterLiquid (player.cs again)

change
case 4: //Lava
         %obj.setDamageDt(%this, $DamageLava, "Lava");

to

case 4: //Lava
         %obj.kill();
#2
12/04/2003 (8:49 pm)
%obj.kill(); works like a charm.. thanks