Set walk-to point for objects?

Started by Fekix, Fri 28/05/2004 13:24:07

Previous topic - Next topic

Fekix

I can set walk to points for hotspots but i can't set this for objects (and for characters). I really need this because my character moves to the GetHotspotpointX and Y and GetObjectX and Y but for the Object i can't set the point :(
Currently working on: My Little Real Life Adventure

strazer

#1
Quote from: Pumaman on Sat 03/04/2004 18:43:50Noted. This will probably be implemented with the more generic 'Locations' rather than object-specific walk-to points.

Fekix

sorry i should have used the search fuction  :-[ but maybe the function will now be implanted
Currently working on: My Little Real Life Adventure

Happyhelmet

what you could possibly do is to set an x and a y as a property for each object and then use the GetObjectProperty to tell the character where to walk to. the walkto point for objects would be really useful i agree, but alas i resort to custom scripting each walkto point for each object and character. this way i have better control of what happens, i hope it gets implimented in the future :)
*<@: ) ("Clown Hat, Curly Hair, Smiley-Face" - Cartman, South Park)

timmle

Could someone please let me know in basic terms how to walk to an object to pick up the object, as at the moment it looks a bit silly just standing there and it disappears. I'm only just starting to create the game and would love it if someone could tell me what scripting if any is necessary to add a walk to point for an object. I want to be able to do this with pretty much every object in the game.

Thankyou.

Shane 'ProgZmax' Stevens

#5
Depending on the name you've given the object, it's simple.

cEgo.Walk(oThing.X,oThing.Y,eBlock,eWalkableAreas) will walk cEgo to object oThing.  After that you can run an animation of cEgo picking it up or just make it disappear.  The key values you need here are the object X and Y properties.  Also, bear in mind that unlike characters, objects have their x/y coordinates relative to the upper left corner of the image so you will want to account for this by adding in an offset.

TheMagician

^^Also, the manual includes a tutorial which explains exactly what you're looking for.

SMF spam blocked by CleanTalk