HOME PRODUCTS
DOWNLOAD
SUPPORT
BLOG
This
topic
daniacea Sign Out
View New Content Forums
Members Store Download Center
PROGRAMS
RPG MAKER VX ACE
RPG MAKER VX
RPG MAKER XP
RPG MAKER 2003
MANGA MAKER
GAME CHARACTER HUB
IG MAKER
RESOURCES
GRAPHICS
MUSIC
OTHER RESOURCES
ULTIMATE GUIDES
SERVICES
MEMBER + FREE TRIALS
RPG MAKER VX ACE
RPG MAKER VX
RPG MAKER XP
IG MAKER
FREE PROGRAMS
RPG MAKER VX ACE LITE
ADDITIONAL
SAMPLE GAMES
OTHER MATERIALS
RUN TIME PACKAGES
PRODUCTS
FAQS
TUTORIALS
UPDATES
INFORMATION
COMPARISONS
MEET THE TEAM
EULA
CONTACT US
PRESS OFFICE
SALES SUPPORT
TECHNICAL SUPPORT
ANNOUNCEMENTS
EVENTS
GAMES
RESOURCES
TIPS AND TRICKS
TUTORIALS
UNCATEGORIZED
Advanced
submit
Blogs Gallery
1. RPG Maker Forums 2. Support 3. RPG Maker VX Ace
31 Follow this topic
Script Call Equivalent of EventsStarted by Archeia, Nov 13 2012 06:44 PM
Snippets
Page 1 of 15 1 2 3 NEXT This topic is locked
298 replies to this topic
#1 ArcheiaPosted 13 November 2012 - 06:44 PMI'd like to compile a list of Call Script equivalent of events. I think it's nice to
know the script call equivalent since there might be some people who work
better with them (like me ;w;). If I posted in the wrong section, feel free to
move. Below is a list of the ones I have so far...c:
Variables$game_variables[n]
Switches
$game_switches[n]
Conditional Branchif #something
Level 99 Demi-fiend
RPG Maker Web Staff+
7,169 posts
LocationChocolateLand Primarily UsesRMVX Ace
First LanguageTaglish
User's Awards
#something
else
#something
end
Show Picturescreen.pictures[index].show(file_name, upperleft/center, x,y, x zoom, y zoom, opacity, blend type)
Move Picture
screen.pictures[n].move(0/1 (top left or center), x, y, zoom1, zoom2, opacity, blend type (0,1, 2), wait)
Picture Tonescreen.pictures[n].start_tone_change(Tone.new(0, 0, 0, 0), wait)
Looping
For
#something
end
Move Eventmove_route = RPG::MoveRoute.new
move_route.repeat = false
move_route.skippable = true
m = RPG::MoveCommand.new
m.code = 45 #The List of M Code can be found over Game_Character, this current m.code is call script
m.parameters = ["script call here"]
move_route.list.insert(0,m.clone)
$game_player.force_move_route(move_route)
Transfer Event Location$game_map.events[id].moveto(new_x, new_y)
Transfer Player
$game_player.reserve_transfer(map_id, x, y, direction)
Screen Tintt = Tone.new(red,green,blue, gray)
screen.start_tone_change(t, duration)
Shake Screen
@params = []
@params[0] = power or $game_variables[x]
@params[1] = speed or $game_variables[y]
@params[2] = duration or $game_variables[z]
Note: (Neonblack and Fomar0153 found this glitch!)
The shake screen has an option in the editor where you can add a "wait" or
not. But the glitch involves that it will wait no matter what. But it will only
wait a number of frames equal to whatever the speed is set to the default
option. For example, the setting is 5 power, 5 speed, 60 frames, and wait. It
will wait for 5 frames, no matter what.
The Infamous Bon Bon, Chaos17, Domin0e and 19 others like this Like This
Script Call Collection || RMVXA Damage Flow || RMVXA Tips and Tricks
Report
#2 Necrofear04Posted 16 November 2012 - 02:00 AMThank you very much Archeia, it's very helpful for RMVX starters like me!!
Archeia likes this Like This Report
#3 CeliannaPosted 16 November 2012 - 03:55 AMI'd also be interested in
conditional script calls
which have no equivalent
event command. Things
like
$game_player.moving?
and
Input.trigger?(Input::A)
They're so useful! And it's okay, since you're asking for script calls, it's in the
right forum.
Archeia, Mihel and Necrofear04 like this Like This
Ancient Dungeons: Base Pack released!
Variemai...
Members
36 posts
Primarily UsesRMVX Ace First LanguageGreek
VX/Ace tileset artist
RPG Maker Web Staff
7,424 posts
Primarily UsesRMVX Ace First LanguageDutch
User's Awards
Report
#4 GalvPosted 16 November 2012 - 05:20 AMThought I would add some more to the list.
Call Common Event:
$game_temp.reserve_common_event(id)
Play SE/ME/BGS/BGM:
RPG::SE.new("SE Name", volume, pitch).play
RPG::ME.new("ME Name", volume, pitch).play
RPG::BGS.new("BGS Name", volume, pitch).play
RPG::BGM.new("BGM Name", volume, pitch).play
Show Text:
$game_message.add("Text")
Gain/lose Item:
$game_party.gain_item($data_items[id], amount)
$game_party.lose_item($data_items[id], amount)
(For weapons/armor use $data_weapons or $data_armors in place of
$data_items.)
Gather Followers:
$game_player.followers.gather
Change Player Followers:
$game_player.followers.visible = true or false
Erase Event:
$game_map.events[event_id].erase
Some conditional script calls to add to Celianna's:
Button pressing
Advanced Member
Members
313 posts
LocationAustralia Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
Input.repeat?(:A)
Input.press?(:A)
Movement
$game_player.dash?
$game_player.jumping?
$game_map.events[event_id].moving?
$game_map.events[event_id].jumping?
Location
$game_map.events[event_id].x
$game_map.events[event_id].y
$game_player.x
$game_player.y
Remove Actor
$game_party.remove_actor(actor_id)
Add Actor
$game_party.add_actor(actor_id)
Remove Party Member from position (where x = party position. 0 = 1st
member, 1 = 2nd member, etc.)
m = $game_party.members
$game_party.remove_actor(m[x].id)
Of course the list can go on, but I hope that little bit helps
EDIT: Fixed some typos and shortened input text as Nicke suggested
EDIT: Added more
Edited by Galv, 27 April 2013 - 11:12 PM. Archeia, Domin0e, Corlagon and 4 others like this Like This
Report
#5 NickePosted 16 November 2012 - 02:58 PMI'll just continue then!
If you ever wanted to add every item/skills/weapons for debugging purpose
(or something else?) it can be kind of tedious to add them all if you have
alot. This small script call will help immensely:
$data_items.each { |i|
next if i.nil? or i.name == ""
$game_party.gain_item(i, 99)
}
Of course, if you want you can change $data_items to $data_weapons or
something else and the amount you want.
When checking for input triggers/pressing you can actually shorten that a
bit:
Input.trigger?(:CTRL)
There is no need to write Input::CTRL anymore.
To get the leader of the party you can do this:
$game_party.leader
Gain/lose gold:
$game_party.gain_gold(amount)
Pure Evil
Members
358 posts
LocationSweden Primarily UsesRMVX Ace First LanguageSwedish
$game_party.lose_gold(amount)
Check for current max gold:
$game_party.max_gold
Get map id and name:
$game_map.map_id
$game_map.name
To correct the screen shake bug thing do the following at Game_Interpreter:
def command_225
screen.start_shake(@params[0], @params[1], @params[2])
wait(@params[2]) if @params[2]
end
Now it will wait the right amount of frames and not 5.
Edited by Nicke, 16 November 2012 - 05:57 PM. Archeia, Domin0e, Mihel and 2 others like this Like This
Current games in development:The Mystery MansionHirion (Abandoned for now) "Fortune smiles upon you..."
Report
#6 ArcheiaPosted 19 November 2012 - 09:51 PMI can't believe I forgot an important one. Regions.
$game_player.region_id == n
$game_map.events[event_id].region_id == n
Acetonide and ct_bolt like this Like This
Level 99 Demi-fiend
RPG Maker Web Staff+
7,169 posts
LocationChocolateLand Primarily UsesRMVX Ace
First LanguageTaglish
User's Awards
Script Call Collection || RMVXA Damage Flow || RMVXA Tips and Tricks
Report
#7 ArcheiaPosted 29 November 2012 - 09:17 AMShow Choices
params = []
choices = []
choices.push("choice 1")
choices.push("choice 2")
params.push(choices)
params.push(0/1/2 this part is where you press cancel and which choice to default)
setup_choices(params)
ct_bolt likes this Like This
Level 99 Demi-fiend
RPG Maker Web Staff+
7,169 posts
LocationChocolateLand Primarily UsesRMVX Ace
First LanguageTaglish
User's Awards
Script Call Collection || RMVXA Damage Flow || RMVXA Tips and Tricks
Report
#8 Domin0ePosted 29 November 2012 - 03:34 PM
Can we bypass the choice limit by using the script commands?
Like This"Twelve highlanders and a bagpipe make a rebellion."
Report
#9 ArcheiaPosted 30 November 2012 - 06:14 AMSeems like you can!
Like a leaf in the wind
Early Adopter
188 posts
LocationGermany Primarily UsesRMVX Ace
First LanguageGerman
Level 99 Demi-fiend
RPG Maker Web Staff+
7,169 posts
LocationChocolateLand Primarily UsesRMVX Ace
First LanguageTaglish
User's Awards
GrandmaDeb likes this Like This
Script Call Collection || RMVXA Damage Flow || RMVXA Tips and Tricks
Report
#10 ShazPosted 30 November 2012 - 06:34 AMDo you know how to set up what to do when a choice is made?
Like ThisNew to RPG Maker? Need help with the basics? Go
here ...
Report
#11 SumasuunPosted 05 December 2012 - 06:38 PMAm I the only one who
runs into automatic word
wrap in the script call
which forces a line
break?
Like This
Report
#12 TsukihimePosted 05 December 2012 - 06:40 PM
'Sumasuun', on 05 Dec 2012 - 1:38 PM, said:
Am I the only one who runs into automatic word wrap in the script call which forces a line break?
Nope, that is the default behavior in the (really small) script call box
Sumasuun likes this Like This
My Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!
Like on Facebook: HimeWorksFollow me on Twitter for the latest updates! @HimeWorksI also make RPGMaker and gamedev videos on Youtube
Report
Advanced Member
Global Moderators
19,435 posts
LocationAustralia Primarily UsesN/A
User's Awards
Member
Members
18 posts
Primarily UsesN/AAdvanced Member
Members
6,309 posts
LocationToronto Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
#13 ShazPosted 05 December 2012 - 09:13 PMNo, and it can cause your game to crash depending on where it puts the
line break. It's best, if your line will be too long, to force the break yourself,
after a =+-/*( symbol so it knows it's continued on the next line and doesn't
add in its own spaces and break things.
Acetonide likes this Like This
New to RPG Maker? Need help with the basics? Go
here ...
Report
#14 Fomar0153Posted 05 December 2012 - 09:17 PMUpping my current
game's resolution upto
640 width was the best
thing I did.
I never ever have to
check my text fits
anymore. It's such a time
saver.
Shaz likes this Like This
Report
#15 TsukihimePosted 05 December 2012 - 09:50 PM
'Shaz', on 30 Nov 2012 - 01:34 AM, said:
Do you know how to set up what to do when a choice is made?
Advanced Member
Global Moderators
19,435 posts
LocationAustralia Primarily UsesN/A
User's Awards
All wrapped up for winter.
Resource Staff++
1,107 posts
LocationEngland Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
Advanced Member
Members
6,309 posts
LocationToronto Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
Do you mean like the choice branching?
Edited by Tsukihime, 05 December 2012 - 09:56 PM. Like This
My Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!
Like on Facebook: HimeWorksFollow me on Twitter for the latest updates! @HimeWorksI also make RPGMaker and gamedev videos on Youtube
Report
#16 ShazPosted 05 December 2012 - 11:00 PMYes. The code for setting up the choices themselves is above, but the
branching is normally created automatically when you use the Show
Choices command. If you're now circumventing the Show Choices
command, you also have to have a way to fake the When [**] branch that
automatically gets created. It's like that script you created the other day
where you use conditions, but this thread is for script calls that don't rely on
other scripts being installed.
Like ThisNew to RPG Maker? Need help with the basics? Go
here ...
Report
#17 TsukihimePosted 06 December 2012 - 12:53 AMIt is pretty easy to fake
the When [**] command
(402).
The definition is just
command_skip if @branch[@indent] !=@params[0]
Where @params stores
the choice number for
Advanced Member
Global Moderators
19,435 posts
LocationAustralia Primarily UsesN/A
User's Awards
Advanced Member
Members
6,309 posts
LocationToronto Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
that specific branch (0, 1, 2, ... )
So all you have to do is replace @params[0] with an integer
if @branch[@indent] == 0
# branch for first choice
elsif @branch[@indent] == 1
# branch for second choice
end
Edited by Tsukihime, 06 December 2012 - 12:55 AM. Like This
My Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!
Like on Facebook: HimeWorksFollow me on Twitter for the latest updates! @HimeWorksI also make RPGMaker and gamedev videos on Youtube
Report
#18 ShazPosted 06 December 2012 - 01:02 AMThank you. I thought it would be something like that, but the params/indent
was messing me up.
Like This
New to RPG Maker? Need help with the basics? Go
here ...
Report
Advanced Member
Global Moderators
19,435 posts
LocationAustralia Primarily UsesN/A
User's Awards
#19 TsukihimePosted 06 December 2012 - 09:20 PM
'Shaz', on 05 Dec 2012 - 8:02 PM, said:
Thank you. I thought it would be something like that, but the params/indent was messing me up.
I think the indent will still mess things up since indentation is internal to the
game interpreter and event commands and you basically have no control
over it. Which means any scripted choice branches will need to use scripts
to create event commands, which I think is starting to get a little ugly.
Like ThisMy Scripts. Go here for Bugs and Requests.
Want to write a tutorial? Submit a community tutorial!
Like on Facebook: HimeWorksFollow me on Twitter for the latest updates! @HimeWorksI also make RPGMaker and gamedev videos on Youtube
Report
#20 harvard1932Posted 13 December 2012 - 09:27 AMis there a way to make script call to have more than 10 lines?
Edited by harvard1932, 13 December 2012 - 09:27 AM. Like This Report
Page 1 of 15 1 2 3 NEXT
Back to RPG Maker VX Ace Next Unread Topic
Object 2 Object 3 Object 4
Advanced Member
Members
6,309 posts
LocationToronto Primarily UsesRMVX Ace
First LanguageEnglish
User's Awards
Newbie
Members
9 posts
Primarily UsesN/A
Object 1
Also tagged with one or more of these keywords: Snippets
1 user(s) are reading this topic0 members, 1 guests, 0 anonymous users
Change Theme English (USA) Mark Community Read Help
Community Forum Software by IP.Board
Object 5
RPG Maker Forums Support RPG Maker VX Ace Privacy Policy FORUM RULES
MAKE YOUR OWN ROLE-PLAYING GAMESHOME PRODUCTSDOWNLOAD
SUPPORT BLOG FORUMSCOMPANY PRIVACY POLICY TERMS & CONDITIONS
IMPRINT CONTACT US AFFILIATE PROGRAM
User's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsUser's AwardsScript Call Equivalent of Events#1Archeia#2Necrofear04#3Celianna#4Galv#5Nicke#6Archeia#7Archeia#8Domin0e#9Archeia#10Shaz#11Sumasuun#12Tsukihime#13Shaz#14Fomar0153#15Tsukihime#16Shaz#17Tsukihime#18Shaz#19Tsukihime#20harvard1932Also tagged with one or more of these keywords: Snippets1 user(s) are reading this topic
search_term: Widget:
Top Related