Jump to content

setDamageFlash not working


Duion

Recommended Posts

I noticed there is a %obj.setDamageFlash(1); function called here: https://github.com/GarageGames/Torque3D/blob/development/Templates/Full/game/scripts/server/player.cs#L230

But I never seen it work.

For reference what it is:

http://docs.garagegames.com/torque-3d/reference/classShapeBase.html#ab6ce0ad64a4e0f1a346a9b370d679792


So it is a sourcecode function that calls the flash.cs postFX to play a damage flash on the screen, but it does not work.


I could find a very old thread on garagegames speaking of the same problem:

http://www.garagegames.com/community/forums/viewthread/59064

So is there really a broken function in the templates for like 10 years now?


Does someone has an idea how to make it work, or should we replace it?

Link to comment
Share on other sites

from what i remember this was used for displaying a postFX Damage screen,

i think that just the PostFx itself isnt there or working...


Check Legends the Game .. its based on some t3d/tgea version

http://www.legendsthegame.net/

and the damage flash is in there but i think it is their own shader (might be wrong here)

anyways the DamageFlash should work you just need to supply a postFx.

Link to comment
Share on other sites

just tried it myself now :/ they must have gone mia totally but

i found a working link from a at least trusted site

http://www.gamershell.com/download_14860.shtml forget this one!!! it seems to be for a older version and best part is that i got a virus warning from the file :roll:


Anyways here http://www.legendsthegame.net/files/legends_windows_0.4.2.2.exe this is the full installer for the latest and last version of it

Link to comment
Share on other sites

Forget it, I got it working now.

You have to add "FlashFx.enable();" somewhere. The postFx was not enabled.


Alternatively just set it to enabled here:

https://github.com/GarageGames/Torque3D/blob/development/Templates/Full/game/core/scripts/client/postFx/flash.cs#L40

So it will always be on.


I wonder how much performance it costs, since the flashFx will always be on, you see it in console wiht trace(1) as well as the gammaPostFx.

Link to comment
Share on other sites

Using a GuiFadeinBitmapCtrl will probably do the same job with just using an Image in the GUI that fades.

After trying it I found that there is an issue, the fading GUI image only fades to solid color, there is an alpha value in the fade color picker, but it seems to get ignored. If that could get solved it will probably be a better solution, since it is less complicated then having another postFx running all the time.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...