Torque game engine demo health bar
by Dan · in Game Design and Creative Issues · 04/28/2009 (6:53 pm) · 25 replies
i was wondering if there is a way to make like a health and mana bar in the bottom corner of the screen when your done with an editing a torque game mission. i would also like to know if there is any free down loadable spells like AFX but free
#22
//-----------------------------------------------------------------------------
// Torque Game Engine
// Copyright (C) GarageGames.com, Inc.
//-----------------------------------------------------------------------------
// Load dts shapes and merge animations
exec("~/data/shapes/player/player.cs");
exec("~/data/shapes/tge_elf/elf.cs");
// Timeouts for corpse deletion.
$CorpseTimeoutValue = 22 * 1000;
// Damage Rate for entering Liquid
$DamageLava = 0.01;
$DamageHotLava = 0.01;
$DamageCrustyLava = 0.01;
//
$PlayerDeathAnim::TorsoFrontFallForward = 1;
$PlayerDeathAnim::TorsoFrontFallBack = 2;
$PlayerDeathAnim::TorsoBackFallForward = 3;
$PlayerDeathAnim::TorsoLeftSpinDeath = 4;
$PlayerDeathAnim::TorsoRightSpinDeath = 5;
$PlayerDeathAnim::LegsLeftGimp = 6;
$PlayerDeathAnim::LegsRightGimp = 7;
$PlayerDeathAnim::TorsoBackFallForward = 8;
$PlayerDeathAnim::HeadFrontDirect = 9;
$PlayerDeathAnim::HeadBackFallForward = 10;
$PlayerDeathAnim::ExplosionBlowBack = 11;
//----------------------------------------------------------------------------
// Player Audio Profiles
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
05/06/2009 (1:09 pm)
when you say pt it at the the top is it before this or after it//-----------------------------------------------------------------------------
// Torque Game Engine
// Copyright (C) GarageGames.com, Inc.
//-----------------------------------------------------------------------------
// Load dts shapes and merge animations
exec("~/data/shapes/player/player.cs");
exec("~/data/shapes/tge_elf/elf.cs");
// Timeouts for corpse deletion.
$CorpseTimeoutValue = 22 * 1000;
// Damage Rate for entering Liquid
$DamageLava = 0.01;
$DamageHotLava = 0.01;
$DamageCrustyLava = 0.01;
//
$PlayerDeathAnim::TorsoFrontFallForward = 1;
$PlayerDeathAnim::TorsoFrontFallBack = 2;
$PlayerDeathAnim::TorsoBackFallForward = 3;
$PlayerDeathAnim::TorsoLeftSpinDeath = 4;
$PlayerDeathAnim::TorsoRightSpinDeath = 5;
$PlayerDeathAnim::LegsLeftGimp = 6;
$PlayerDeathAnim::LegsRightGimp = 7;
$PlayerDeathAnim::TorsoBackFallForward = 8;
$PlayerDeathAnim::HeadFrontDirect = 9;
$PlayerDeathAnim::HeadBackFallForward = 10;
$PlayerDeathAnim::ExplosionBlowBack = 11;
//----------------------------------------------------------------------------
// Player Audio Profiles
//----------------------------------------------------------------------------
//----------------------------------------------------------------------------
#23
On an unrelated note: the damage rates for lava will not work if you try to change them, there's a easy fix for that though.
05/06/2009 (2:26 pm)
You can literally place them anywhere up there. Just to keep things organized I would place it near the Liguid damageTypes, ie. the Lava stuff// Damage Rate for entering Liquid $DamageLava = 0.01; $DamageHotLava = 0.01; $DamageCrustyLava = 0.01;
On an unrelated note: the damage rates for lava will not work if you try to change them, there's a easy fix for that though.
#24
and how do i change the damage of the lava. can it be negative so by going into lava i gain health??
05/06/2009 (2:54 pm)
whats a .dso and how do i removeand how do i change the damage of the lava. can it be negative so by going into lava i gain health??
#25
So far as the lava question goes: no. If you step into lava, regardless of the damage amount set for the different types you will be instantly killed. It can be fixed but first you should get the drowining and other things working before forging ahead.
I would also recommend reading the documentation available for TGE, under the Support -> Documentation link, it has a scripting section, and a few tutorials that will help you understand things a little better.
05/06/2009 (4:54 pm)
Quote:whats a .dso and how do i removeThey're the compiled versions of the scripts that the engine generates when it successfully executes the script(s). It will have the same name as the original scriptFilename.cs but have the .dso extension tacked onto the end of it: scriptFilename.cs.dso. To remove it simply delete it from the directory and the next time that Torque runs, and if nothing is wrong with the script, a new one will be generated. It's a means of optimizing the script into a format that's machine readable and faster to execute.
So far as the lava question goes: no. If you step into lava, regardless of the damage amount set for the different types you will be instantly killed. It can be fixed but first you should get the drowining and other things working before forging ahead.
I would also recommend reading the documentation available for TGE, under the Support -> Documentation link, it has a scripting section, and a few tutorials that will help you understand things a little better.
Dan