Script Call Support Boards

how do I change the background when a character touches a certain point? ex: attempting to step out of the screen in a forest brings the player into a town.
how do I change the background when a character touches a certain point? ex: attempting to step out of the screen in a forest brings the player into a town.
That has absolutely nothing to do with script calls, it can be done by eventing alone.
Please check on the tutorials to learn how it's done, transfer events are explained in the basic tutorials you'll need to learn anyway.


If you do not know where to start, follow the link in my signature.
Hello, there. 😀

So I know that by default, you can only show pictures from "Graphics/Pictures" and I know that you can only show change battleback for the battle screen.

But what if I want to show pictures from "Graphics/Battlebacks1" and/or "Graphics/Battlebacks2" when the player is not in the battle screen?

And what if I want to show battlers picture taken from RPG::Enemy complete with the hue? Is it possible to do these two using some script call? 🤔

Or do I have to ask this somewhere else? :|
Take a look in the Cache script at the picture and battleback methods. See if they hardcode the path. If they don't, you just need to make the appropriate script calls (see what Game_Interpreter does when you use the Show Picture event command - or look at the original event command script reference thread linked in the first post of this thread to see what the script command is to show a picture) and pass in the correct location. You wouldn't be able to set a hue in a Show Picture command, but see if there's a tint picture command that you might be able to use.
Heh. Not sure what "hardcode" means, but... here's what's written in Cache.

Spoiler
#-------------------------------------------------------------------------- # * Get Picture Graphic #-------------------------------------------------------------------------- def self.picture(filename) load_bitmap("Graphics/Pictures/", filename) end #-------------------------------------------------------------------------- # * Get Battle Background (Floor) Graphic #-------------------------------------------------------------------------- def self.battleback1(filename) load_bitmap("Graphics/Battlebacks1/", filename) end #-------------------------------------------------------------------------- # * Get Battle Background (Wall) Graphic #-------------------------------------------------------------------------- def self.battleback2(filename) load_bitmap("Graphics/Battlebacks2/", filename) end #-------------------------------------------------------------------------- # * Get Battle Graphic #-------------------------------------------------------------------------- def self.battler(filename, hue) load_bitmap("Graphics/Battlers/", filename, hue) end
Hmm. Guess I have to request a script to make things easier... 😀

Anyway, just taken a look again at the Script Call Collection thread. According to Archeia, this is the format I should write in the script call if I want to tint the pic:

screen.pictures[n].start_tone_change(Tone.new(0, 0, 0, 0), wait)So, following above, after using Show Picture in index number 1, this was what I wrote next:

screen.pictures[1].start_tone_change(Tone.new(24, -26, -25, 0), wait)But instead of tinting the pic, what happened was an error. 'Game Interpreter' line 1411: wrong number of arguments (0 for 1). What did I do wrong here? 🤔
wait is wrong, you need to put a number there.
Ahh I see. Should've known. lol. Thank you, Shaz. Thank you, Archeia 😀
I want to activate a switch when a skill is selected , before it calculates the success rate , in order to have a conditional branch inside the calculate rate section that increases the success rate to 100% when the certain skill is used and another switch is on. 

if #skill selected is [Skill] rate = 1 if ($game_switches[switch_id] == true && $game_switches[swtich_id]== true)endHow can I call the skill selected ?
Are you doing this as a script call? From where? Seems you want to alter the default scripts, which means this question doesn't belong in this thread. Please make a new thread in RGSSx Script Requests.
I can't seem to figure out why this is failing!!

post-36340-0-32151100-1433311330_thumb.png


This is the script call

$game_party.gain_item($data_items[\v[66]],$game_variables[34])I wanted to add an Item (variable 66) whose quantity is determined by a variable 34.

error.png
I can't seem to figure out why this is failing!!

post-36340-0-32151100-1433311330_thumb.png


This is the script call

$game_party.gain_item($data_items[\v[66]],$game_variables[34])I wanted to add an Item (variable 66) whose quantity is determined by a variable 34.
'\v[66]' only works when used within message windows. Otherwise, use '$game_variables[x]' :

Code:
$game_party.gain_item($data_items[$game_variables[66]],$game_variables[34]) 
'\v[66]' only works when used within message windows. Otherwise, use '$game_variables[x]' :

$game_party.gain_item($data_items[$game_variables[66]],$game_variables[34]) 
 Argh...so simple

Thanks a bunch!!
How can I call the change enemy Hp . There is an event for it but I need its script call...
In Game_BattlerBase:

Code:
  #--------------------------------------------------------------------------  # * Change HP (for Events)  #     value:         Amount of increase/decrease  #     enable_death:  Allow knockout  #--------------------------------------------------------------------------  def change_hp(value, enable_death)    if !enable_death && @hp + value <= 0      self.hp = 1    else      self.hp += value    end  end
Hey guy's question. I am currently building a save system that uses disposable items that can be crafted and it will be replacing the one I made that runs off common events and events on every map waiting to be used. So my question is, is there a script that can "create" a temporary event, name it something like "temp_event_1"?

It literally doesn't have to do anything but sit there and be pretty. I want to change it's graphic to like a crystal of something, but I already know how to do that. all I'm snagged on is this event creation. If I have to have an event on every map just to get this to work, it defeats the purpose of making it into a script. If anyone can help me I would appreciate it.

Made my own topic for this question,
How can I call the change enemy Hp . There is an event for it but I need its script call...
Code:
$game_troop.members[index].change_hp(value, true/false)
where true or false is whether you want to allow knockout.
For all members ,what do I have as an index .

Do I use an array with all the numbers or is it a number
What do you mean, "for all members"?


If you want to do something to all members, you have to do it to them one at a time.


Look through the Game_Interpreter class and see how it handles the command you're trying to execute.

Code:
$game_party.members.each {|mbr| mbr.change_hp(value, true/false)}
If I want something to happen when a player is on an event I use 2 variables to get the players x and y

I then have 2 conditionals, first checking if the player's x = event's x, then if the player's y = event's y.

Is it possible to use a script call in one conditional which simply asks if the players x,y is the same as the event's?

Thank you
yes, use this:

Code:
$game_player.x == $game_map.events[id].x && $game_player.y == $game_map.events[id].y
You can also use the "Player Touch" event trigger 😳

Original thread: https://forums.rpgmakerweb.com/threads/script-call-support-boards.25767/