How to save the game? and enemy paths?

This forum is currently in read-only mode.
From the Asset Store
Be discreet and rescue your friends from behind enemy lines.
  • Ok I've been trying to figure out how to use the save game commands, and it hasn't been working:

    I have a box, when the box is collided with the players bullet it will turn green (Got that working) and then save. I can't figure out how to use the save game commands to get it to work. It needs to work like this:

    At the main menu I have a load button, it should load the progress of the current game.

    Then there is a new game button, which should create a new game

    I will assign a key to loading like R so when the player dies from spikes or such, he can see the particles of blood fall then load from where he saved with the box, or If the player gets stuck somewhere or wants to restart from the last save point.

    When the box is shot with the bullet, it will save the game.

    -------------------------------------------------------------------------------------------------------

    Now I would like to know how I can tell my enemies where to go (This is a 2d platformer), say i wanted a enemy on the ground to move left and right back and forth, or just keep moving in one direction.

    What i'm wondering is how do i make my enemies move around on platforms or ground, or even air if I decide to make a flying enemy. Do I need to make waypoints, If so How do I do it, or if I need to do something else.

    --------------------------------------------------------------------------------------------------------

    If anyone could help me with any of my questions i'd be grateful.

    Thanks.

  • for flying enemies you could use the RTS behavior to set waypoints

  • Thanks, that's a good Idea.

  • Could anyone answer my save game question? Also the waypointing thing didn't work.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • A path movement is on the to-do list. As for the save game question; i have no idea.

  • Saving is dead easy, the Save/Load to disk action stores the save game data in a file (use an expression like AppPath + "myfile.sav" to store it in the game's own folder). The Quicksave/quickload actions store the data in memory. So you can use events like:

    + On key S pressed

    -> Quicksave

    + On key L pressed

    -> Quickload

    Press S to save, L to load last quicksave...

  • Ok i tried the quicksave/load thing and It only loads like some sprites then the rest are invisible such as: My character sprite, and the ground, and one of the enemys. Help?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)