Highwire4 Posted April 4, 2013 Report Share Posted April 4, 2013 So my game has dark areas that can be illuminated with an item. I've managed to simulate it by having a shadow and/or light graphic follow the player's position. I've managed to get it to appear and dissapear only when the light sensor is overlapping a shadow trigger. The problem I'm having is getting the flash light to work. I'm basically having two shadow graphics follow the camera, one is invisible until a button is pressed. At that point I want the graphics to swap visibilities and stay that way until the button is pressed again. I can't get it to work right. It either just flashes for a moment or doesn't work at all. Active 27 is the flashlight graphic and Active 28 is the shadow graphic. Light>[INDENT]-Start of Frame>[/INDENT][INDENT][INDENT]-Make "Active 27" invisible-Make"Active 28" invisible[/INDENT][/INDENT][INDENT]-Always>[/INDENT][INDENT][INDENT]-Set position of "Active 27" at (-240,-173) from "Player sensor"-Set position of "Active 28" at (-240, -173) from "Player sensor"[/INDENT][/INDENT]>>>>>>DARK[INDENT]-If "lightsensor" is overlapping "Shadowtrigger">-NEGATE upon pressing "D">-"Active 27" is invisible>[/INDENT][INDENT][INDENT]-"Active 28" Reappear[/INDENT][/INDENT][INDENT]-If "lightsensor" is NOT overlapping "Shadowtrigger">-NEGATE upon pressing "D">-"Active 27" is invisible>[/INDENT][INDENT][INDENT]-"Active 28" Invisible[/INDENT][/INDENT][INDENT]-If "lightsensor" is overlapping "Shadowtrigger">-upon pressing "D">-"Active 27" is invisible>[/INDENT][INDENT][INDENT]-Make "Active 28" invisible-"Active 27" Reappear[/INDENT][/INDENT]>>>>FLASHLIGHT[INDENT]-If "lightsensor" is overlapping "Shadowtrigger">-NEGATE upon pressing "D">-"Active 28" is invisible>[/INDENT][INDENT][INDENT]-"Active 27" Reappear[/INDENT][/INDENT][INDENT]-If "lightsensor" is NOT overlapping "Shadowtrigger">-NEGATE upon pressing "D">[/INDENT][INDENT][INDENT]-"Active 27" Invisible[/INDENT][/INDENT][INDENT]-If "lightsensor" is overlapping "Shadowtrigger">-upon pressing "D">-"Active 28" is invisible>[/INDENT][INDENT][INDENT]-Make "Active 27" invisible-"Active 28" Reappear[/INDENT][/INDENT][/CODE]halp plz Link to comment Share on other sites More sharing options...
TailsSena Posted April 4, 2013 Report Share Posted April 4, 2013 Perhaps an MFA containing just that frame and bit of code would be helpful. Link to comment Share on other sites More sharing options...
Highwire4 Posted April 23, 2013 Author Report Share Posted April 23, 2013 Well here's some code: Download link for the MFA: http://www.mediafire.com/?uz9mlu9nt7v877q Now I'm not sure what I'm doing wrong. I just want it to swap the two screen overlay graphics at the push of a button and stay that way while in a certain zone. Link to comment Share on other sites More sharing options...
Highwire4 Posted April 30, 2013 Author Report Share Posted April 30, 2013 Bumping this up cause I'm seriously at a loss. I've been trying to get this to work all week. Even totally scrapped the coding and tried something else that ended up failing. Link to comment Share on other sites More sharing options...
Recommended Posts