Lou Bagel's Forum Posts

  • Nice going there man!

    Having those default values stored as instance variable of the player sprite would make the most sense, as those values are directly tied to how that particular sprite behaves. However, global variables or a dictionary wouldn't be bad either. So I guess in the end it all boils down to what you prefer.

    Thanks!

    Another option I may just take is make a function for each (setSprintSpeed; setWalkSpeed; etc).

    I have a list of issues I need to work out, especially with the sprint (using x button), but thought I would share a link anyway to what I have right now: (sometimes its fun to see the progress)

    http://loubagel.com/archives/louPlatform/080716/

  • I'm sure every time someone shares their events you will need to customize some for your layout. I hear ya on the tutorials. I found a good one on it but can't find it again—there needs to be upvotes or something on tutorials so the more useful ones are easier to find.

  • I can't find the tutorial I used but here is what I did:

    Global Variable ControlPadTouchID (forgot to capture in the snip)

    I crossed out some unrelated events and highlighted the ones pertaining to ControlPadTouchID

    Basically there are three steps:

    • Anytime a touch starts it checks if it is touching the control pad. If so it changes the variable to the touch's ID
    • If the variable is not -1 then that touch's location will be tracked to determine which direction to move
    • Anytime a touch ends there will be a check to see if it was the touch ID stored in the variable. If it isn't then the control pad movement isn't interrupted. If it is then the variable will be set to -1 which stops step 2

    Should be able to make another global variable for the other controlpad/joystick and duplicate the events. The touches should be tracked separately and not interfere with each other.

  • Haven't looked at your capx yet but what I mean is tracking the touches so they don't affect each other. So you would have on touch ends & Touch ID equals X

    I haven't done two joysticks but I have done control pad and buttons, you can see by clicking the ninja picture in the middle of my signature. It took some testing and debugging but it is definitely possible

  • Have you tried using the debugger to monitor objects? Or creating a text box where you can append text as events fire? That can help you understand what is going on.

    Do you have an event that re-enables the platform behavior? Maybe that is firing and you don't realize it

  • Are you talking about once you reach the edge of one layout it loads the next layout?

  • Not sure this is enough info for anyone to help you. There is probably an event or action that you don't realize is affecting something.

  • Have you learned how to track touch ID?

  • If you are trying to reduce load time just for testing you could isolate what you are testing in a separate layout

  • What is the best way to store all these speeds as variables? So I can say set jump strength to standard/sprint/water/etc. instead of having to change in multiple places when tweaking. Can a dictionary take care of that? Or will I have to resort to instance variables for each?

  • Almost there on the swimming. Need to add something to not allow skipping across the top of the water though:

  • Sprite.CustomMovement.MovingAngle

  • If moving in a straight line to destination then that would be the angle of movement. I haven't looked but would be surprised if there wasn't a property for angle of movement, making it simpler.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You can manipulate the X and Y movement vectors of the platform behavior directly

    I must have not noticed these actions—thanks!

    Getting him in the water is easy...gotta get him out of the water now

  • I also have noticed this with path finding movement and decided to use other behaviors (may not be possible in all situations)

    I had a player move towards enemy on path finding movement and had an event for on collision to attack (since enemy was still moving I didn't want to wait for arrival and have them walk past each other). Sometimes it would "arrive" at the enemies origin but wouldn't be close enough to cause collision.

    Also had zombies that were supposed to take a few steps at a time so it was path finding a small distance. Randomly it wouldn't move at all when it was supposed to. I could never trouble shoot it. I guess now I know it was "close enough" so didn't move at all.

    I know this post doesn't help you but I am interested in any resolution as right now path finding movement is my last choice, unless there is an actual maze.