Wrap X & Y Problem

JCFordJCFord Member Posts: 785
edited November -1 in Working with GS (Mac)
I have a large game area 960x640 and the camera is setup at the standard 480x320 size.

I have actors moving all over the game area, and to optimise the frame rate I have an Actor I have called ANTI-FREEZE the same size as the camera 480x320 that follows the camera and when any of my actors are onscreen they will move, but if they are off screen not in contact with the ANTI-FREEZE actor they freeze. and this worked great and has improved my frame rate.

My game area wraps X & Y so if an actor goes off the screen bottom they will float back in at the top etc But I have an issue that as my actors are floating off the edge of the screen they are freezing - so they appear half on half off either side but frozen.

Because my ANTI-FREEZE actor is the exact size of the camera I wondered if these actors were kind of half-in-half out of the actor ANTI-FREEZE and shtiks was causing the problem, so I have tried to increase the actor ANTI-FREEZE to make it oversize, but as soon as my actors get to the edge of the screen they still freeze and don't continue off to the other side of the screen like I want?

Confusing I know, but Anyone have any ideas?

Comments

  • ORBZORBZ Member Posts: 1,304
    how is ANTI-FREEZE following the camera? Via constrain attribute or is ANTI-FREEZE itself your camera controller?
  • rebumprebump Member Posts: 1,058
    Yeah, I had some similar wrapping X/Y stuff that worked in 0.7.0 and now occasionally freezes in 0.8.2 and stutters about the edge of the visible area. I was probably going to be working on that tonight if I can get some free time. If I discover anything, I'll let you know. Same with you! :-)
  • JCFordJCFord Member Posts: 785
    Tried everything I can think of bug this bug stil persists for me.

    ORBZ to answer your question my actor ANTI-FREEZE is constrained by its own X & Y position to that of the scene camera origin X & Y.

    It works beautifully freezing anything thats outside of ANTI-FREEZE or any actor that moves out of ANTI-FREEZE, but as soon as an actor reaches the edge on the canvas area and should wrap onto the opposite side of the screen it freezes half-on half-off even though ANTIFREEZE itself has wrapped - very odd!
Sign In or Register to comment.