McDonald's Forum Posts

  • 9 posts
  • You could try setting a global variable and setting the steering speed to that variable every tick. Then, on key down, start increasing the variable, and on key up reset it to the original amount. Or you could just directly increase the steering speed. I have never played with cars, so I don't know if that's possible.

  • I cut out some irrelevant actions.

  • fisholith

    Well, I still have a problem - I update the real ship, then update the ghost ship, then loop it 100 times, but the ghost doesn't update and stays in the same place as the real ship, spawning 100 dots every tick. My every tick event looks like this:

    Start tick

    Do physics stuff and update real ship

    Set ghost's state to ship's state

    (sub-event)Repeat 100 times

    Do physics on ghost

    Spawn dot on ghost

    End tick

    Yet the ghost doesn't update and spews dots in the same place.

  • Eh, I tried adding it to my game (then just straight up copy-pasting it), but it didn't help. Thanks for help, anyway.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I did what you suggested and the ghost doesn't update and follows the real ship instead. This is probably because the tick ends, ghost starts going forwards, but the next tick comes and resets the ghost back to ship's position. I added the loop as a sub-event if that matters.

    The "Repeat 100 times" loop causes the ghost ship to just spawn a 100 times more dots in one place, so it seems to be a problem with updating the ghost.

    Although now that I think of it, I need player actions to be accounted for instantly, so this isn't the best solution.

  • I should've explained more - there is a star system, with a central star and two planets orbiting it in more or less circular orbits, and you can freely fly around it, while the star and planets constantly affect your trajectory. I'll take a look at this tutorial, thanks!

    E: Well, it didn't help much, as I use cos and sin to calculate my trajectory.

  • I searched around and didn't find anything similar to my question. Could you give me a link to one?

  • Have you tried adding an instance variable "Gravity" to the vials, setting it the the gravity you want, and then setting bullet gravity to Self.Gravity?

  • (Not enough space for a ? )

    I'm working on a game where you fly around space in a ship, and I would like to draw a path showing your orbit. Do you have any tips?

  • 9 posts