Powered by Invision Power Board

 
    Reply to this topicStart new topicStart Poll

> [MMF2] Swinging Vines
United States
kirbyhi5
Posted: Jul 17 2008, 10:37 AM
Quote Post


your typical MMF user
[*][*][*]

Group Icon
Group: Members
Posts: 1341
Member No.: 4893
Joined: 2-January 08

Status: (0d) [--]


So for the longest I have been trying to make swinging ropes that move smoothly. It best was to use a geometric Sin/Cos formula. But anyway to the point, The vines are divided into different objects.( Yes, that means each vine segment is a different object), but I gave them all the same qualifier to group them. Group being #1
user posted image
So I make something like:

-Repeat while holding Shift
-Player sensor overlapping .Group1[The vine segments]

;Set X position of player sensor to X position of Vine Endpoint
;Set Y position of player sensor to Y position of Vine Endpoint
user posted image
This makes it so if you hold shift down while passing over any vine segment, you automatically grab on to the end of it, as long as you have shift pressed down...But

Because the Vine segments are created at the start of frame..he only goes to the vine endpoint that were LAST created. that means If I add 5 swinging vines, he only goes to number 5. not any others
user posted image

so how do I make it so he can grab any vine, and NOT just the ones that are recently duplicated/created last. sorry if this is hard to explain, but im all for tips/suggestions

This post has been edited by kirbyhi5 on Jul 17 2008, 11:05 AM


--------------------
PMEmail PosterUsers Website
Top
United States
Xgoff
Posted: Jul 17 2008, 11:27 AM
Quote Post


<):|
[*][*][*][*][*]
[*][*]

Group Icon
Group: Members
Posts: 52341
Member No.: 24
Joined: 13-October 03

Status: (0d) [--]


so... if i'm understanding this correctly, if you have more than one vine, mario only grabs the most recent "vine endpoint" object (and i'm also guessing that each vine is made up of X amount of "body segment" objects and exactly 1 "endpoint")

anyway, if that's the case, from what i can tell from this:
QUOTE
-Repeat while holding Shift
-Player sensor overlapping .Group1[The vine segments]

;Set X position of player sensor to X position of Vine Endpoint
;Set Y position of player sensor to Y position of Vine Endpoint

you're basically passing mario to the end of the vine if he touches any part of it

the problem is that when mario collides with one object (a segment), you're telling him to go to an endpoint... but MMF has no idea what endpoint you're talking about (you narrowed down the specific segment but not the specific endpoint), so it goes its usual "what the **** do i do" route and chooses whichever matching object is the most recently created

basically you need to "group" your objects in a way that MMF can get useful information out of it (qualifiers won't cut it because they group ALL of the vines together); i'm not sure how you're creating the vines (manually or through fastloops or what), but generally you'll assign a unique ID value to all of the segments (and the endpoint) of a specific vine

so something like this should work with the ID thing:
QUOTE
"Player Sensor" collides with Group.1
--> Set Global Value "MarioVine" to: ID("Group.1") [[technically groups can't have named AV's, but for clarity reasons...]]

"Player Sensor" is overlapping "Vine endpoint"
+ ID of "Vine endpoint" = MarioVine
--> [[your events to position mario]]


something like that should work, but you still need a way of assigning an ID to all the segments/endpoint in a specific vine, that's different from the other vines (fastloops would be useful for both doing this and creating the vines in the first place)

This post has been edited by Xgoff on Jul 17 2008, 11:35 AM


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

This post may contain original research or unverified claims.
Please disregard the above information and contact an administrator.

DISCLAIMER: by sending me (xgoff) a private message, you agree to the directives and their terms specified henceforth:
DIRECTIVE 1 (APPLE): i may or may not reply promptly or at all; and there are no guarantees to the usefulness of the reply. i may not acknowledge whether i have even received your private message
DIRECTIVE 2 (CHILE CON CARNE): as per my view, "private" applies only to the initial transaction, and the material of your message may or may not be made public at my discretion; as this will more than likely be a post in the CCC or IRC, you may not be able to view it
DIRECTIVE 3 (FEATHER DUSTER): you must address me (xgoff) as "Sir Master Xgofficus his Highest and Most Awesome the Third"; failure to comply with this term may invoke one or both of the above directives, and i will leave a burning bag of **** on your doorstep
DIRECTIVE 4 (BOOTSTRAP): if you have read this disclaimer, please private message me promptly, in compliance with the above terms, so i can ensure you are capable of following directions you idiot
this concludes the test of the emergency disclaimer system, your scheduled programming will now continue. satisfaction guaranteed, and 100% cash back available under certain circumstances; restrictions may or may not apply within your place of residence
NOTICE: these directives and their terms may change at any time, without notice; as a private message transaction to myself assumes an understanding and full compliance of the above, you should ensure you are fully aware of the above terms at any point before sending a private message; any message received is assumed to have been sent in compliance with the above

QUOTE
(5:25:58 PM) Mikau: xgoff
(5:26:00 PM) Mikau: guess what
(5:26:04 PM) Xgoff: chicken butt
(5:26:09 PM) Mikau: **** you
PMEmail PosterUsers WebsiteAOLMSN
Top
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

  Topic Options Topic Options Reply to this topicStart new topicStart Poll

 




[ Script Execution time: 0.0479 ]   [ 13 queries used ]   [ GZIP Enabled ]   [ Server Load: 0.58 ]