Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Door stutter problem

Tindy

Sponsor

So, I have these doors in my game, right? (They tend to make a game better, I hear.) When I stand in front of a door and press the action button, it opens beautifully - I've had that part covered for a while now. However, when I try to do the same from *behind* the door (IE: From the other room), it still works but kind of does a stutter step, regardless of if it's opening or closing.  Why does it do this?  Is there a way I can fix it?

|                        |
------|   |--------
|   door^             |
 

Tindy

Sponsor

(Event Page 1, Trigger=Action Button)                    @>Wait 3 Frame(s)
                                                                          @>Control self switch: A=ON
(Event Page 2, Self Switch A=ON, Trigger=Automatic)  @>Wait 3 Frame(s)
                                                                          @>Control self switch: B=ON
(Event Page 3, Self Switch B=ON, Trigger=Automatic)  @>Wait 3 Frame(s)
                                                                          @>Control self switch: C=ON
(Event Page 4, Self Switch C=ON, Trigger=Action Button)

Thats just to open the door, and the stutter problem still exists there; to close it I just add [@>wait 3 frame(s) @>Self Switch C, B, A = OFF]. I'm beginning to think that it's maybe because the open door sprite is set to "Through," and the rest obviously aren't, so that I guess could cause a problem with the hero sprite behind the door....maybe?
 
Just had this problem. Make the event "Direction Fix On" During the moveroute of the event. put Direction Fix Off at the top. At the bottom put it back to Direction Fix On.
 
Ahh, I see, the door turns to face you for 3 frames, causing the stutter.
You can check "Direction Fix", but there's another, easier solution. Simplify your event code to two pages:

(Event Page 1, Trigger Action Button)
Code:
@>Set Move Route: [Door]
       :$>Turn Left
       :$>Wait: 3 frames
       :$>Turn Right
       :$>Wait: 3 frames
       :$>Turn Up
@>Wait: 6 frames
@>Control Self-Switch A = On

(Event Page 2, Self-Switch A=On, Trigger Action Button)
Code:
@>Set Move Route: [Door]
       :$>Turn Right
       :$>Wait: 3 frames
       :$>Turn Left
       :$>Wait: 3 frames
       :$>Turn Down
@>Wait: 6 frames
@>Control Self-Switch A = Off
 
Tindy I sent you a PM but if you want help with this one two please send a little demo and Ill modify it with an explaination of what I did to help you ok?  It doesnt have to be a demo of your game just make a new game with a what you have set up for the door.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top