Mathesunix's Recent Forum Activity

  • Note that in my capx the origin image point of the trees and player sprites is at the bottom. Also, it doesn't look like you separated trunks from the leaves, like I suggested in my previous comment.

    "Wait 0" is needed, because we have to wait 1 tick for the trees to be created, before sorting them.

    "For each ordered" because we need to cycle through all trees sorted from top to bottom.

    If all this doesn't help, please share your capx file.

    Hi! Hope you're fine.

    So, I think the problem is solved! Here's what I did:

    Event sheet: https://drive.google.com/file/d/1RytVFQcr2WzHi55zN32lPd7IYF0Q_lW4/view?usp=sharing

    Layout: https://drive.google.com/file/d/1fG7O97o0GIXgNuGSS6JWLCFcyxG4VaDf/view?usp=sharing

    As I said in my previous post, your solution was working almost completely, the only drawback was that the instance lower down on the layout wasn't behaving like the others, so I thought I could just put the top part of an instance inside the layout and let its Y coordinate outside of it to see what would happen, and it worked fine:

    Video: https://drive.google.com/file/d/1u6mUIbcgdy2uaDsrX5_TE92lQax7o-yi/view?usp=sharing

    Now I just need to make that specific bottom instance invisible and it's all good.

    I'm still trying to understand how to solve it with events only, without needing to go for this out of layout instance thing, but it works and I'm satisfied with the result.

    Thank you so much for helping me! Have a good day!

  • Try z-sorting the trunks as it's done in my example, and move all leaves to another layer, which is above the layer with trunks and player.

    Video: https://drive.google.com/file/d/11ef6VXTfySQLdhu-EZ5JU0HE8Go3YJ0R/view?usp=sharing (I added this new tall box sprite to the family just to see if I weren't facing a bug).

    Event sheet: https://drive.google.com/file/d/12QqzV7B0FLDUPK-cvqFKlRZJKm3r7uI_/view?usp=sharing

    Hi, so, I tried to delete my events and copy paste yours into my capx, just to see if the problem would be solved (the only thing I changed was the "repeat 100 times" to "repeat 5 times" since my sprites are way bigger and occupy more space on the screen), and... Apparently, it did not, at least not completely; as you can see in the video, it only works for the instances that are higher on the screen, the instance that is lower down does not behave the same way (trunk in front of the player when it shouldn't be), I have some questions:

    Why did you use this "for each ordered" condition? I read some tutorials and the manual entry for this condition but I couldn't fully understand it in the specific context I'm facing here.

    Why did you use the "pick bottom instance"?

    Why "wait 0 seconds"?

    Thanks.

  • It's your second post with the same question and I still don't understand what you mean. Why do you need to cut the tree in half?

    If you want to walk "behind" it, simply change z-order (move character behind the tree or to the bottom of the layer).

    Check out this capx, it may be relevant:

    https://www.dropbox.com/s/lbewjvv6rekd2na/IsometricForest.capx?dl=0

    Hi! Thanks for replying! I now understand how I can make what I want, as in your capx, I just needed to compare the object Y with the player Y, an so I get the desired result:

    https://drive.google.com/open?id=1vm7Dmljc6TGpqj_q0Nu0qcK_LAm7jnWT

    https://drive.google.com/open?id=1GOTgoXTtklxZbgnyF_n1KkeqgjgnraUr

    As you can see, I added the object to a family because I want this behavior to be repeated for every single tree instance my player cross, but now it does not seem to work, sometimes the player gets behind the trunk or in front of the leaves when the opposite should happen:

    https://drive.google.com/open?id=1tXqjaBwlPlxLeNoYgN932lZ1E55Jwyx3

    Here's the capx in case anyone needs it: https://drive.google.com/open?id=1LcAJNk3YTVaN0bRPM9jwT2A9dHSEbkKS

    What should I do to solve the problem?

    Thanks.

  • https://drive.google.com/open?id=1NrEK_2HHKHmnwnxK-_q3qc-QyATaGBlQ

    Hi, hope you're all fine. So, i want to create the effect in this capx without having to cut the sprite in half as it is in the file, is it possible?

    Thanks in advance!

  • https://drive.google.com/open?id=1NrEK_2HHKHmnwnxK-_q3qc-QyATaGBlQ

    Hello everyone, I hope you're all good, I would like to know how can i make this effect without needing to cut a sprite in half as you can see in the capx, is it possible?

  • Hey people, my thanks to all of you for the help! All your tips helped me come up with a simple solution that I could not see! Here it is:

    Thanks one more time! Wish you the best.

  • Add 'else' in 29, 30 & 31.

    Thank you guy for trying to help me! Really appreciate

  • The problem is that in your logic, you have told the variable to change based on it's condition... but it is changing the variable several times in the single event because it's processing your code in-line. You need to have some way of changing the variables in a more controlled way. Currently if the variable is "left" it changes to "right" but is then immediately pocessed from "right" to something else. Maybe adding a "wait 0 seconds" after each state change might work... otherwise you need to break down your state change engine to be more controlled over the variable adjustments.

    ~Sol

    ey, thanks you so much for trying to help me! I've found a simpler and effective solution to the problem!

  • Seems kind of simple, but have you tried setting the 8direction to four-directions only in it's settings for the object that has the behavior?

    Yes I tried! But it didn't work !

  • Hi guys, my problem is basically with logic, I'm confused about what I should do to make this sprite move in four directions with the simulate controls.

    Here I'm using that "edge maker" thing, which is very useful when you want your sprite to move in just two directions, but I want it to move in four, and I'm having problems at it.

    Huh, I guess a screenshot may help:

    This sprite, as you can see, has a text instance variable called direction that is used to determine the movement orientation through the event actions.

    The problem is that the sprite goes to a completely unexpected direction when it hits the boundary maker object, if it was meant to go to the right, it goes up instead, and sometimes it doesn't even hit it at all, it just pass through it like there was nothing there.

    Well, that's it, hope you people can help me! Oh, and I'm sorry for my rusty english , I'm still learning!

    Thanks in advance!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi, I'm Matheus , I'm from São Paulo, Brazil, how are you?

    I'm a beginner game designer (I have started studying game design yesterday , so I know basically nothing).

    My English is awful, sorry :/, so if I commit any grammatical error, let me know please!

    Nice to meet you!.

Mathesunix's avatar

Mathesunix

Member since 27 Jan, 2016

None one is following Mathesunix yet!

Connect with Mathesunix

Trophy Case

  • 8-Year Club
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

11/44
How to earn trophies