Jump to content

Screen fades Red


NotAvailableToday

Recommended Posts

Use this opcode to choose the fade color:

 

0169: set_fade_color_RGB 256 0 0

 

Red Green Blue, 256 is full 0 is empty, so here its a red fade wink.gif

Then you make a little fade like a flash:

 

 

:CJ_hit

0001: wait 1 ms

00D6: if

> Unknow Opcode <

004D: jump_if_false @CJ_hit

0001: wait 1 ms

0169: set_fade_color_RGB 256 0 0 // (red fade color)

016A: fade 0 time 0

0001: wait 20 ms

016A: fade 1 time 10

0169: set_fade_color_RGB 0 0 0 // (return to basic fade color)

0001: wait 100 ms

0002: jump @CJ_hit

 

The unknow opcode is something linked with the fact to be hit, like :

031D: actor $PLAYER_ACTOR hit_by_weapon 51

 

But the problem with this one is that the fade will begin only if weapon 51 (not an other) is used on CJ. Bye and I hope to be helpfull

 

 

 

Link to comment
https://gtaforums.com/topic/389655-screen-fades-red/#findComment-1058837509
Share on other sites

NotAvailableToday

I know but I can use if or, can´t I?

 

 

edit: The code won´t work sad.gif

 

 

:CJ_hit10001: wait 1 ms00D6: if 8184:   not actor $PLAYER_ACTOR health >= 50 004D: jump_if_false @CJ_hit10001: wait 1 ms0169: set_fade_color_RGB 256 0 0 // (red fade color)016A: fade 0 time 00001: wait 20 ms016A: fade 1 time 100169: set_fade_color_RGB 0 0 0 // (return to basic fade color)0001: wait 100 ms0002: jump @CJ_hit1004E: end_thread 

 

 

 

 

Edited by Zombie.modder
Link to comment
https://gtaforums.com/topic/389655-screen-fades-red/#findComment-1058837652
Share on other sites

NotAvailableToday

another question: Can I make a transparent fade ?

 

 

:CJ_hit10001: wait 1 ms00D6: if 8184:   not actor $PLAYER_ACTOR health >= 50 004D: jump_if_false @CJ_hit10001: wait 1 ms0169: set_fade_color_RGB 255 0 0 // (red fade color)016A: fade 0 time 00001: wait 20 ms016A: fade 1 time 100169: set_fade_color_RGB 0 0 0 // (return to basic fade color)0001: wait 100 ms0002: jump @CJ_hit1004E: end_thread 

 

 

i mean a red fade wich is transparent and never fade out

Link to comment
https://gtaforums.com/topic/389655-screen-fades-red/#findComment-1058837808
Share on other sites

 

:FADEREDthread 'FADERED' jump @FADERED_96 :FADERED_18wait 0 1@ = Actor.Health($PLAYER_ACTOR)if and  not Player.Wasted($PLAYER_CHAR)8741:   not actor $PLAYER_ACTOR busted jf @FADERED_184 if 002D:   1@ >= 2@ // (int) jf @FADERED_111 if 801D:   not  1@ > 2@ // (int) jf @FADERED_96 jump @FADERED_18 :FADERED_962@ = Actor.Health($PLAYER_ACTOR)jump @FADERED_18 :FADERED_1110169: set_fade_color_RGB 255 0 0 0062: 2@ -= 1@ // (int) 3@ = 1000 0072: 3@ /= 2@ // (int) 043C: disable_sounds_after_fade 0 fade 0 3@ wait 0 2@ *= 50 fade 1 2@ 043C: disable_sounds_after_fade 1 jump @FADERED_96 :FADERED_184wait $DEFAULT_WAIT_TIME jump @FADERED_18 

 

 

From my mod. Biohazard Alert.

Link to comment
https://gtaforums.com/topic/389655-screen-fades-red/#findComment-1058838461
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • 0 User Currently Viewing
    0 members, 0 Anonymous, 0 Guests

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.