Jump to content

  • Log In with Google      Sign In   
  • Create Account


Health Effect


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 mrmohadnan   Members   -  Reputation: 278

Like
0Likes
Like

Posted 22 May 2013 - 04:01 PM

I want to make something already done by a lot of games , which is when I am taking so much hits from enemy red screen drawn like the following , using XNA 4.0:

after it's drawn and I am still alive I want to be removed slightly as in the call of duty !!!

4r9xgose284oedd6g.jpg


Edited by mrmohadnan, 22 May 2013 - 04:01 PM.


Sponsor:

#2 menohack   Members   -  Reputation: 216

Like
2Likes
Like

Posted 22 May 2013 - 04:08 PM

Render-to-texture the scene, then make a new shader that combines the rendered image with the blood image (with transparency in the middle).

 

This is known as a post-process.



#3 minibutmany   Members   -  Reputation: 1572

Like
2Likes
Like

Posted 22 May 2013 - 07:20 PM

To make it fade away, adjust the alpha(opacity) of the image, which is demonstrated in this stack overflow thread: 

http://stackoverflow.com/questions/6632723/how-to-make-a-texture2d-50-transparent-xna


Stay gold, Pony Boy.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS