Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Another noob question

Ark

Member

I don't know the right syntax for near's pathfinding script. I want to make an event which tells some other event where to go.

# Event Script Call :: self.event.find_path(x,y)

I know it's this, but just cannot get to work. I tried the following call script.

self.004.find_path(49,54)

004 is the ID of the event I want to make move.
I also tried this:

self.event[004].find_path(49,54)

But there's no good.

I know it's an easy thing to do, but...

I suck at RGSS codes.


Or is it possible to move an other event with this?

Like...

'A' says to 'B' go to xy!
 

OS

Sponsor

I am not sure how this would work, but if you want to move a different event, try: $game_map.event[4].event.find_path(x,y) or $game_map.event[4].find_path(x,y)

Or try taking the 0's out of 004 (never use leading 0s. Ever!)
 
You forgot one letter, Akahi
Code:
$game_map.event[B][SIZE=4][COLOR=Red]s[/COLOR][/SIZE][/B][4].find_path(x,y)
replacing 4 for your event id...
You can call this for any event in the current map.
:thumb:
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top