Jump to content


Photo

Path Collisions


  • Please log in to reply
9 replies to this topic

#1 tempesttime

tempesttime

    GMC Member

  • New Member
  • 8 posts

Posted 18 May 2012 - 06:45 PM

Please let me know if this topic doesn't belong here.
I am making a game and I am working on replicating the "Tales of " 2d battle system. I am currently working on adding Back Steps and Forward Dashes through the use of paths.
I was hoping someone could help me with a few things. First, when my paths collide with a wall, my character gets stuck to them, and can't move at all.
The other question I have, which is the more complex one, is if it would be possible to maintain the vertical movement in the path, just not have the horizontal movement (so you can keep back jumping against the wall, you just won't go anywhere).
Thanks in advance :)
  • 0

#2 roa

roa

    GMC Member

  • New Member
  • 96 posts

Posted 19 May 2012 - 01:12 AM

Your new here so I will tell you before someone else of lower tolerance does- you need to show what your working on script wise and what you have done to further your progress-other wise, we can't help you. You mentioned a game unknown and a lacking mental visage scribble of what we are supposed to guess at, reply with more info so we can help you.
  • 0

#3 Gamer3D

Gamer3D

    Human* me = this;

  • GMC Member
  • 1590 posts
  • Version:GM8.1

Posted 19 May 2012 - 04:59 AM

I am currently working on adding Back Steps and Forward Dashes through the use of paths.

First let me say that using paths for this is a bad idea for a number of reasons (For example, the problem you're having).

I was hoping someone could help me with a few things. First, when my paths collide with a wall, my character gets stuck to them, and can't move at all.

You probably use functions such as move_contact_solid. This kind of function will stop immediately if the character is ALREADY inside a solid, which it will be when the path puts it there. Alternately, GM is trying to do something similar.

The other question I have, which is the more complex one, is if it would be possible to maintain the vertical movement in the path, just not have the horizontal movement.

Yes.
For me, the easiest way would be to pull out the path vertex data, then construct a quadratic Bezier spline from the y coordinates.
For you, the easiest way would be to create another object that ALSO follows the path, and copy the y-coordinate from that. (NOTE: I said easiest. Not best. Not even good)
  • 0

#4 tempesttime

tempesttime

    GMC Member

  • New Member
  • 8 posts

Posted 21 May 2012 - 10:20 PM

Your new here so I will tell you before someone else of lower tolerance does- you need to show what your working on script wise and what you have done to further your progress-other wise, we can't help you. You mentioned a game unknown and a lacking mental visage scribble of what we are supposed to guess at, reply with more info so we can help you.

Thank you for letting me know and for going easy on me :)
What I have done so far to make my character move into a backstep and into a dash doesn't exactly include GML. I have the character change into a different object which follows a path in the create event in the form of a small, open arc.
What I have done to try to fix it, before I read Gamer3D's post, was (in the step event):
if space behind character is NOT free
jump to position x+1 (relative)

does this make more sense?
  • 0

#5 Nocturne

Nocturne

    Nocturne Games

  • Administrators
  • 16837 posts
  • Version:GM:Studio

Posted 21 May 2012 - 10:51 PM

Your new here so I will tell you before someone else of lower tolerance does- you need to show what your working on script wise and what you have done to further your progress-other wise, we can't help you. You mentioned a game unknown and a lacking mental visage scribble of what we are supposed to guess at, reply with more info so we can help you.


So, you with your whole 95 posts speak from experience of what the community can and cannot accept? Obviously you are wrong or you would know that your kind of post is not tolerated in the least. The OP posted a perfectly valid question, explaining exactly what his problem is and asking for suggestions on how to solve it. He did NOT ask for a dose of mis-placed attitude. In future, if you can't help the person with their problem just don't post and you'll save us all some hassles.



@tempesttime : As gamer3D suggests, you could create an invisible object (no sprite) that follows the path, then have the player object use mp_potential_step (in DnD it's "step avoid" I think) to follow that object. In this way the path object will never get stuck and the player will have a far easier time avoiding obstacles, and even if they do get stuck, the movement of the other object it is following will probably take it out of collision again quickly.

PS: Paths are really quite tricky when you are dealing with collisions, so if this is going to be an issue, maybe you should use something else?
  • 1

#6 roa

roa

    GMC Member

  • New Member
  • 96 posts

Posted 24 May 2012 - 08:19 AM


Your new here so I will tell you before someone else of lower tolerance does- you need to show what your working on script wise and what you have done to further your progress-other wise, we can't help you. You mentioned a game unknown and a lacking mental visage scribble of what we are supposed to guess at, reply with more info so we can help you.


So, you with your whole 95 posts speak from experience of what the community can and cannot accept? Obviously you are wrong or you would know that your kind of post is not tolerated in the least. The OP posted a perfectly valid question, explaining exactly what his problem is and asking for suggestions on how to solve it. He did NOT ask for a dose of mis-placed attitude. In future, if you can't help the person with their problem just don't post and you'll save us all some hassles.



@tempesttime : As gamer3D suggests, you could create an invisible object (no sprite) that follows the path, then have the player object use mp_potential_step (in DnD it's "step avoid" I think) to follow that object. In this way the path object will never get stuck and the player will have a far easier time avoiding obstacles, and even if they do get stuck, the movement of the other object it is following will probably take it out of collision again quickly.

PS: Paths are really quite tricky when you are dealing with collisions, so if this is going to be an issue, maybe you should use something else?

That's cute, cause I seem to remember post requiring nothing short of providing the proper information- I asked nothing of him that I wasn't my self asked to provide directly by administrators or other game maker community members. 95 post has got nothing to do with my experience on here but rather my timing and understanding to help others. Who's to say I don't go under two accounts here? I was simply stating he would benefit from posting his work, and I did not simply understand him as I'm sure the 80 views prior my post hinted at with others. I'm glad he got the help he needed and would be willing to help if the need arises. Admins are supposed to set the mood for the site, so instead of jumping off the deep end with a snide remark or criticizing me for some miss intent you put there,work harder at non hypocritical presentation. Don't give me a reason to ill perceived your kind, I will post nothing more as there is no need,he has his help.@ Sorry tempesttime if my approach was distasteful or sub satisfactory.
  • 0

#7 Coga19000

Coga19000

    GMC Member

  • GMC Member
  • 100 posts
  • Version:GM8

Posted 24 May 2012 - 08:34 AM

I admit I'm new in here, so I'm not sure if my post is going to help at all, but Zethros uses the move_outside_solid code. Maybe you could use it, too?
  • 0

#8 Nocturne

Nocturne

    Nocturne Games

  • Administrators
  • 16837 posts
  • Version:GM:Studio

Posted 24 May 2012 - 08:36 AM

That's cute, cause I seem to remember post requiring nothing short of providing the proper information- I asked nothing of him that I wasn't my self asked to provide directly by administrators or other game maker community members. 95 post has got nothing to do with my experience on here but rather my timing and understanding to help others. Who's to say I don't go under two accounts here? I was simply stating he would benefit from posting his work, and I did not simply understand him as I'm sure the 80 views prior my post hinted at with others. I'm glad he got the help he needed and would be willing to help if the need arises. Admins are supposed to set the mood for the site, so instead of jumping off the deep end with a snide remark or criticizing me for some miss intent you put there,work harder at non hypocritical presentation. Don't give me a reason to ill perceived your kind, I will post nothing more as there is no need,he has his help.@ Sorry tempesttime if my approach was distasteful or sub satisfactory.


If what you say is true and you have two accounts then that is very much against the rules...Posted Image. However, that silliness aside, I found your comments completely unnecessary, particularly due to the fact that in the novice forum you are not required to post code as many people use DnD, and that we also get many non-english speakers here who post the best they can to make themselves understood.

The Op's post was quite understandable, or, at least, contained enough information for you to make an educated guess at his question and TRY to supply an answer. And even if it didn't, you could still have asked for more information without the need to put him down the way you did. A simple "could you please give more information? Perhaps with some code?" would have sufficed.

As for a reason to "ill perceived my kind" (sic) if you care to check my post history I hope you'll see that I do try to be fair and just with the people on this forum. Your post came across as brash, rude and arrogant, and on top of that did nothing to help the OP with his problem. If that was not your intent, fine, it can be difficult to interpret "tone of voice" from a post! I can happily accept that we have both jumped the gun here and hopefully future encounters will be on a more amicable footing. Posted Image
  • 0

#9 Coga19000

Coga19000

    GMC Member

  • GMC Member
  • 100 posts
  • Version:GM8

Posted 24 May 2012 - 08:42 AM


That's cute, cause I seem to remember post requiring nothing short of providing the proper information- I asked nothing of him that I wasn't my self asked to provide directly by administrators or other game maker community members. 95 post has got nothing to do with my experience on here but rather my timing and understanding to help others. Who's to say I don't go under two accounts here? I was simply stating he would benefit from posting his work, and I did not simply understand him as I'm sure the 80 views prior my post hinted at with others. I'm glad he got the help he needed and would be willing to help if the need arises. Admins are supposed to set the mood for the site, so instead of jumping off the deep end with a snide remark or criticizing me for some miss intent you put there,work harder at non hypocritical presentation. Don't give me a reason to ill perceived your kind, I will post nothing more as there is no need,he has his help.@ Sorry tempesttime if my approach was distasteful or sub satisfactory.


If what you say is true and you have two accounts then that is very much against the rules...Posted Image. However, that silliness aside, I found your comments completely unnecessary, particularly due to the fact that in the novice forum you are not required to post code as many people use DnD, and that we also get many non-english speakers here who post the best they can to make themselves understood.

The Op's post was quite understandable, or, at least, contained enough information for you to make an educated guess at his question and TRY to supply an answer. And even if it didn't, you could still have asked for more information without the need to put him down the way you did. A simple "could you please give more information? Perhaps with some code?" would have sufficed.

As for a reason to "ill perceived my kind" (sic) if you care to check my post history I hope you'll see that I do try to be fair and just with the people on this forum. Your post came across as brash, rude and arrogant, and on top of that did nothing to help the OP with his problem. If that was not your intent, fine, it can be difficult to interpret "tone of voice" from a post! I can happily accept that we have both jumped the gun here and hopefully future encounters will be on a more amicable footing. Posted Image


He may hace lost the code of the older one account. I have been screwed like that in a forum or two.
  • 0

#10 Nocturne

Nocturne

    Nocturne Games

  • Administrators
  • 16837 posts
  • Version:GM:Studio

Posted 24 May 2012 - 08:49 AM

He may hace lost the code of the older one account. I have been screwed like that in a forum or two.

If that happens here just let an admin know and it will be sorted out with no hassles. Posted Image
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users