Jump to content


Photo

Event Follow Event (like "Move Toward Player")


  • This topic is locked This topic is locked
8 replies to this topic

#1 Dark Horseman

Dark Horseman

    NPC

  • Ace Member
  • 323 posts
  • RM Skill - Artist

Posted 17 May 2012 - 03:58 AM

Is there anything with this functionality where I can set a parallel event to continually follow another event? It would make similar calls to the "Move Toward Player" command, but change the target.

Scenarios I can think of are:
- Children following parents
- NPCs following each other
- And in my situation, "guided arrows" for a cutscene/minigame

#2 shaz

shaz

    Advanced Member

  • Ace Member
  • 611 posts
  • LocationAustralia
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 May 2012 - 04:16 AM

I plan to have something like this in my game as well - it has a LOT of uses, especially if it can be turned on and off, and if you can control how far behind the "target" event it always stays.

If you want to tackle this yourself, I'd suggest you take a look at how the party followers system is set up, or the caterpillar scripts from XP and VX.

#3 The Nine

The Nine

    The Idea Man

  • + Premium Members
  • 2,619 posts
  • LocationTonawanda, New York
  • RM Skill - Writer

Posted 17 May 2012 - 10:38 AM

Hm... well, I don't see a way to make it follow another event, but the player is easy.

Just set the event as a parallel process with the move route "Move Towards Player" as the only thing in the event page.

Hello, I'm Obrusnine, or Niko, or Obs... doesn't matter. I'm a writer who loves games as an interactive story-telling medium! ...and as a way to have fun.

 

Check out my game!

 

Userbar_zps004c446d.png

Quotes:

Spoiler

#4 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 6,372 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 May 2012 - 10:38 AM

Really simple since RM devs designed their code fairly well for this

http://www.rpgmakerv...fp-move-routes/

Scripted move commands:

move_toward_event(EVENT_ID)

Since you didn't need things like conditions and distance I haven't done those yet.
By conditions I mean things like

-move towards closest event
-move towards farthest event
-move towards event within a certain range
-move to certain position
-always jump, don't walk normally
-jump n tiles at a time, etc

I also currently just finished writing a simple script call that allows you to specify your move command like

"3D5R4U2RLRLRLR"

Saves you a whole lot of effort.
But now I'm out of letters to designate diagonals.

Maybe...
Q W
A S?

Edited by Tsukihime, 17 May 2012 - 12:00 PM.

My Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!

himeworks011.png

Like on Facebook: HimeWorks
Follow me on Twitter for the latest updates! @HimeWorks

#5 shaz

shaz

    Advanced Member

  • Ace Member
  • 611 posts
  • LocationAustralia
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 May 2012 - 02:51 PM

Why don't you use numbers instead of directions, just like the system already does to determine passability? It just means you'd have to go 222 instead of 3D

#6 Tsukihime

Tsukihime

    Advanced Member

  • Ace Member
  • 6,372 posts
  • LocationToronto
  • RM Skill - Coder

Awards Bar:

Users Awards

Posted 17 May 2012 - 02:56 PM

Why don't you use numbers instead of directions, just like the system already does to determine passability? It just means you'd have to go 222 instead of 3D


Because "15D15R" looks better than "8888888888888888888866666666666666666666"

Numbers would solve my diagonal direction problem though, but allowing arbitrary strings means I can extend it fairly easily. Like maybe if I wanted to specify that it's a jump movement rather than a normal move in a certain direction via

15JD

Edited by Tsukihime, 17 May 2012 - 03:09 PM.

My Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!

himeworks011.png

Like on Facebook: HimeWorks
Follow me on Twitter for the latest updates! @HimeWorks

#7 efeberk

efeberk

    Alone Maker

  • Ace Member
  • 175 posts
  • RM Skill - Coder

Posted 05 August 2012 - 03:43 PM

use move_straight method. If you don't understand, send pm.

#8 Spearnear

Spearnear

    Wanderer

  • Ace Member
  • 13 posts
  • RM Skill - Designer

Posted 05 June 2013 - 04:35 PM

Since you didn't need things like conditions and distance I haven't done those yet.
By conditions I mean things like

-move towards closest event
-move towards farthest event
-move towards event within a certain range
-move to certain position
-always jump, don't walk normally
-jump n tiles at a time, etc
----

Sorry to bump a very old topic, but I was wondering if you ever made a script with these features?  I scoured Google for days and this thread is about as close as it gets to what I need. 

 

This OTHER post http://forums.rpgmak...-to-events-ids/ was pretty close to what I was looking for too, but apparently this is a bad way to do it and impossible so I dropped that idea.  If I could identify an event and set it somewhere as a "target", that could certainly make things easier.

 

I also don't just want to copy/paste someone else's battle system either.  I'd like to understand it myself if possible, because I don't want my game to be mostly consisting of someone else's work.  I don't mind borrowing a couple useful scripts (like mouse movement and a time system) here and there, but a complete battle system rip off seems cheap to me and I'd like to avoid it if possible.

 

I'm trying to make an friendly NPC event "aggro" (move toward) the nearest enemy event in it's range after a battle has started or if I push a certain button.  The only way I could do this was to set a move route to move to that SPECIFIC event (which is "move_toward_event(#), but that way proved cumbersome since I had to do it for every single enemy NPC.

 

I'm also trying to make enemy events aggro the player OR a friendly NPC based on proximity or the NPC's ID (for example, a cat enemy event would aggro a bird friendly event before the player), but I don't understand how to set that up either.

 

I know it's possible to do these things, since I have seen them used in other videos.  I was hoping to use as little scripts as possible because I have zero scripting know-how (apart from using plug and play scripts I can't do much) so I am really at a dead zone here. :(   I also don't like to use other people's work that much because I like to be as creative as possible because it helps me learn, but this proximity aggro stuff really boggles me. >_<

 

Anyways, help would be really appreciated with this and sorry again for bumping such a dead topic, it's truly my last hope. 


Edited by Spearnear, 05 June 2013 - 04:42 PM.


#9 Galv

Galv

    Forum Defender

  • Staff Manager/Global Mod
  • 5,224 posts
  • LocationAustralia
  • RM Skill - Jack of All Trades

Awards Bar:

Users Awards

Posted 05 June 2013 - 04:51 PM

You might find useful:

http://www.rpgmakerv...fp-move-routes/

http://galvs-scripts...e-route-extras/

 

Please start your own topic with what you need instead of necroposting. Thanks.


galv-plea.png sig-kickstarter_zpsda2cb57e.png


gs-banner_zpsfc59b073.png bb-logo_zps34dc32d8.pngconstellation1_zps9e598b08.png





1 user(s) are reading this topic

1 members, 0 guests, 0 anonymous users