Main Menu
  • Welcome to The RPG Maker Resource Kit.

Overworld hero script

Started by dragonmagna, December 31, 2005, 01:04:13 AM

0 Members and 3 Guests are viewing this topic.

dragonmagna

Put this in the scripts database!
-------------------------------------------
1) Open up the script editor
2) Click on the script called "Scene_Map"
3) Find this section of code:

   # B ??????????
   if Input.trigger?(Input::B)
     # ????????????????????
     unless $game_system.map_interpreter.running? or
            $game_system.menu_disabled
       # ???????????? SE ?????????
       $game_temp.menu_calling = true
       $game_temp.menu_beep = true
     end
   end


4) Just below that code insert THIS code:

   if Input.trigger?(Input::R)
     actor = []
     actor.push($game_party.actors[0])
     actor.push($game_party.actors[1])
     actor.push($game_party.actors[2])
     actor.push($game_party.actors[3])
     temp = 0
     temp2 = 0
     loop do
       temp2 = temp2 + 1
       if temp2 == 4
         temp2 = 0
       end
       if actor[temp2] != nil
         $game_party.actors[temp] = actor[temp2]
         temp = temp + 1
         if temp == 4
           break
         end
       end
       if temp2 == 0
         break
       end
     end
     $game_player.refresh
     $game_party.refresh
   end

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

Now when you press the "w" key on the keyboard, it would let you walk around as the next hero in line.
That may not make sense, but  try the script to see what I mean.
Credit goes to Plystire.
:o


Interested in playing these complete games and checking out more? Go to my website!

digitaldude

i'm a noob so that code is really helpful thx

cristianraf

:^^: thats very helpful but i can just do it with events  :^^:
Project: Divine Wars Demo

58% events
45% database
72% maps

SiR_VaIlHoR

oh funny i think i can ameliorate it a little...
i'll try
I'm the Alpha and the Omega, the First and the Last, the Beginning and the End.

http://qualquek.miniville.fr/
http://www.dailymotion.com/bookmarks/ojah/video/x27l78_jake-simpson-stevie-wonder-isnt-she_music

My padawan (Tsunokiette) and me :p
http://www.team-aaa.com/root/profile.php?enter_id=614556
http://www.esl.eu/fr/player/2609080/
I'm French so forgive my bad english!

dragonmagna

Quote from: cristianraf:^^: thats very helpful but i can just do it with events  :^^:
Based on how many characters you have, this could take at least 6 hours to do on switches and variables alone. Its just easier to do it this way. And why isn't this in scripts database yet? This is a really good, constantly needed script.


Interested in playing these complete games and checking out more? Go to my website!

ShadowLink

I know this topic is a week old, but which version is the script for?
Co-Webmaster of The Gaming Alliance

Thanks to TheRaven off of The Players Guild.
R.P.G. Fan Game Status
[--TLOZ: Fierce Entity--]|||||||||||||||||||| - 3%

thatsmypie

Quote from: ShadowLinkI know this topic is a week old, but which version is the script for?
OMFG! The only Rpg Maker that uses scripts is RPG Maker XP. That was an idiotic question! Dont ask em...

ShadowLink

Quote from: thatsmypie
Quote from: ShadowLinkI know this topic is a week old, but which version is the script for?
OMFG! The only Rpg Maker that uses scripts is RPG Maker XP. That was an idiotic question! Dont ask em...

Hey, whoa, calm down there bud. It's not like I'm expert with these RPG Makers  :O_o: I got it like...a week ago and haven't been on it much  :wink: I'm sorry if my question offended you, thatsmypie.  :P

Thanks though for answering my question.  :D

And thanks to dragonmagna for posting the script as well.  :^^:
Co-Webmaster of The Gaming Alliance

Thanks to TheRaven off of The Players Guild.
R.P.G. Fan Game Status
[--TLOZ: Fierce Entity--]|||||||||||||||||||| - 3%