(4.1 at least) monsters lose damaging property

FrankenGraphics

New member
Two of my enemy objects lose their ability to damage the player haphazardly. The only thing that single them out from the rest is that they have the ability to wrap around the screen (in other words, their screen edge behaviour is null). It's kind of hard to verify but i think they lose it precicely when wrapping around.
 

Mugi

Member
if a monster is sitting on the edge of the screen (edge fo a nametable actually) there are issues with the objects and their attributes.
in my demo, damaging a monster sitting on the edge of a nametable (maybe 8pixels wide area or so horizontally) are effectively invulnerable as they are in a different table than the player is and simply refuse to register damage.
funny enough they can damage the player just fine. sounds somewhat the opposite of the issue you're having but im quite sure it's related. For me it randomly happens in the middle of the screen since the scrolling has the nametables move around
but in a single screen enviroment, this happens exclusively on the screen edges. (i simply go around this for now by using a destroyMe edge reaction, until i manage to get something done for better handling of off-screen monsters.)
 

FrankenGraphics

New member
I wish it was only on the edge! Once they have passed the wraparound seam, the altered (nulled) properties are persistent. Could still be related though.

A really hacky solution could maybe be to have a timer that will refresh the object instance with its init values (times each action step), but that is not pretty and feels like going out of your way and tax the game loop unnecessarily to produce only marginally better results. Not even 100% sure it'll work. I'll keep looking but haven't found anything tangible so far.
 

Mugi

Member
i havent really started looking yet, but reprogramming the monster edge / offscreen behavior is definitely there on my list of things that i need to rewrite for my game, so if all else fails, i will let you know when i get there.
 
Top Bottom