InDWrekt's Forum Posts

  • The first option only changes when the animations are different so it is really the most efficient although the efficiency gains aren't very big. The second and third (2nd: every tick, 3rd: no condition) are exactly the same. They both happen every tick. The last option is basically an every tick situation but only 1 of the 2 options is happening every tick depending on if the character is moving or not.

    With all that said though, the animation engine, as far as I understand it, will handle all these pretty close to the same. You aren't going to get huge gains from choosing any specific option above.

  • There are a few ways this can be done. You could check the angle of movement which seems like the most intuitive, but there is an easier way. Check the x value of the pathfinding next node. If it's less then the current x, face left. If not, face right.

  • It would be easier to help you with this problem if you posted your project here. Without access to it, we can really only guess what is going on.

    That said, the most likely issue is, your image origins are set wrong. Many times, when a new user creates a character from a sprite sheet, they don't realize they have to fix their image origins. If your characters origins cause their collision box to push down into the solid floor, it will cause them to fall through.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • It sounds like you should use the pathfinding behavior, not the moveto behavior. Pathfinding calculates a path around obstacles and moves the character along that path.

  • To add a little to igortyhon's answer, you can also import event sheets into each other so, you can have one event sheet containing all the events that are used in every room, and import it into a room specific event sheet when you have events that may be specific. Just right click on your event sheet and click the Include Event Sheet option.

  • Your evaluation idea is the correct way to do it. However, with pathfinding, you don't want to compare your current x and y against the destination. You want to check the pathfinding behaviors movingangle (Self.Pathfinding.MovingAngle). This will update every time the character reaches a node in the path and return the current angle at which the character is moving.

  • Could you create a layout that only has the things you want on all layouts and then just duplicate it for each new level?

    You could also use Global layers to build a single layer that will contain all your background items. Global layers are layers that are created in one layout then, override every other layouts layer with the same name as the global layer. I made a popover menu system to show this functionality for a previous forum question. Take a look:

    drive.google.com/file/d/1g1gKkHFQ444PQq1kot-ugyW06cwNsG5l/view

  • You need to set some variable on the object to define what team it is on. Then, when targeting, check the instance variable to see if the object is a valid target. In the conditions you should do something like this:

    Pick Sprites in range.

    Sprite has peerid = enemy.peerid (or Sprite has peerid <> self.peerid)

    Pick closest Sprite.

    All these conditions need to be in a single action. That way, each following condition would filter the list. First you pick all sprites in range. Then keep only the sprites from the previous list that are enemies. Then choose the closest sprite from the previous list.

  • If you post the file, I would be happy to take a look at it.

    More often than not, issues with the platform behavior have to do with your collision bounds and sprite origin. If you have a sprite whose sprite origins for each animation frame are in different places relative the the base of the sprite collision bounds, you can wind up with your sprite moving inside the solid object which will cause it to fall through the solid object.

  • You may not have found anything for climbing a rope but, that is really no different from climbing a ladder from a gameplay standpoint. There are a ton of Ladder tutorials out there. Try this one for example:

    construct.net/en/tutorials/ladders-platform-games-697

    or this one:

    construct.net/en/tutorials/simple-ladder-platformer-game-330

    or if you prefer a video:

    youtube.com/watch

  • There is no need to "teleport" the sprites at all. All you need to do is, add the sprite to the layout design and go to the new layout. If you look at any of the tutorials that have multiple levels, you can see examples of this. Also, I have attached a link to an example I built for a different question a while ago that could help you see how to do it:

    drive.google.com/file/d/1INg7SXrc4XT3ew7nmUkOuTFpHGy0xdIU/view

    If you need to keep track of variables between the different layouts, you can set them as global variables.

  • All you need to do is include the check for the boolean value in the same event conditions as the pick nearest. Take a look at this example.

    drive.google.com/file/d/1X3Fuhu0yTb9OwCS-8mVaUaTi1GDJpi_d/view

  • I answered a similar question here construct.net/en/forum/construct-3/how-do-i-8/optimize-code-158547

    If you take a look at this example: drive.google.com/file/d/1yG8azZPg66Ve6QxSHzGXY6LHqg8GmBc0/view

    You should be able to get what you need. It uses a JSon file to hold conversation information and a local variable on the character to record where in the conversation they are.

  • You're welcome. Glad I could help and good luck with your project.

  • Your file was unavailble when I tried to download it so I didn't have it to work with. I built a simple concept that I think should have all the things you asked for though:

    drive.google.com/file/d/1g34uTHMpVszjBiE4HmWTWv3dUqlFnyoB/view

    Problem #1 & #2

    I get around this by, rebuilding the object every time a change is made. I don't rely on the image points. I just place them above the base object the height of the image * the position in the array.

    Problem #3

    (Modifying) - This part is taken care of by rebuilding on change.

    (Changing Cost) - For this, I store the price in the array and update it when I update the image selected.

    Hopefully this little project gets you what you need to complete your project. Good luck.