Is there a script call for the page 3 conditional branch option for the direction the player is facing?
Script Call Equivalent of Events
RPG Maker VXAce Support$game_player.direction
2 = down
4 = left
6 = right
8 = up
2 = down
4 = left
6 = right
8 = up
So...
$game_player.direction==2
Would provide a true if player was facing down?
$game_player.direction==2
Would provide a true if player was facing down?
yes.
Could we use a command like this to check a character's oisition within the party(1st, 2nd, 3rd, etc..) when battle starts and assign each a TRG based on their position?
A command like what?
To find a character's position in the party, you just do $game_actors[id].index where id is the actor id, and index is their position (0 is the leader).
To find a character's position in the party, you just do $game_actors[id].index where id is the actor id, and index is their position (0 is the leader).
Umm.. when requesting a script on the script forum one guy's response was:
and perhaps I'm inquiring the wrong way, this stuff is a bit advanced for me.
$game_actors[id].index will give you the position in the party of that character. Now you should take that information back over to your other request thread and find out how to use that to do exactly what you're after, as anything outside of that script snippet is also off topic for this thread 🙂
Back in the earlier pages of this topic, there was the Show Choices command equivalent and the branches equivalent. Unfortunately, I am having some troubles with the branch part.
I am using the script calls with Fomar's Aeon Party script, and am using this in my summoning skill's common event script call:
command_skip if @branch[@indent] != @params[0]if @branch[@indent] == 0RPG::SE.new("evil laugh", 125, 150).playa = $game_actors[9]$game_party.aeons.push(a)$game_actors[9].change_level($game_actors[6].level, FALSE)SceneManager.scene.create_spritesetcommand_314 # this probably needs fixingelsif @branch[@indent] == 1RPG::SE.new("079-Monster01", 125, 50).playa = $game_actors[10]$game_party.aeons.push(a)$game_actors[10].change_level($game_actors[6].level, FALSE)SceneManager.scene.create_spritesetcommand_314endThis shows the choices, but whenever I select a choice, nothing happens and the battle continues on its merry way.
Does anyone know what I am doing wrong?
(is this the correct place to post it?)
I am using the script calls with Fomar's Aeon Party script, and am using this in my summoning skill's common event script call:
command_skip if @branch[@indent] != @params[0]if @branch[@indent] == 0RPG::SE.new("evil laugh", 125, 150).playa = $game_actors[9]$game_party.aeons.push(a)$game_actors[9].change_level($game_actors[6].level, FALSE)SceneManager.scene.create_spritesetcommand_314 # this probably needs fixingelsif @branch[@indent] == 1RPG::SE.new("079-Monster01", 125, 50).playa = $game_actors[10]$game_party.aeons.push(a)$game_actors[10].change_level($game_actors[6].level, FALSE)SceneManager.scene.create_spritesetcommand_314endThis shows the choices, but whenever I select a choice, nothing happens and the battle continues on its merry way.
Does anyone know what I am doing wrong?
(is this the correct place to post it?)
For the move picture equivalent:
screen.pictures[n].move(0/1 (top left or center), x, y, zoom1, zoom2, opacity, blend type (0,1, 2), wait)I'm assuming "wait" means the Time in frames?
There's also a check mark for "Wait for Completion" in the event command, but I don't see where you would put that parameter in the script call.
screen.pictures[n].move(0/1 (top left or center), x, y, zoom1, zoom2, opacity, blend type (0,1, 2), wait)I'm assuming "wait" means the Time in frames?
There's also a check mark for "Wait for Completion" in the event command, but I don't see where you would put that parameter in the script call.
screen.pictures[@params[0]].move(@params[2], x, y, @params[6],
@params[7], @params[8], @params[9], @params[10])
wait(@params[10]) if @params[11]
Yes, the wait is the number of frames the process should take. Wait for Completion doesn't actually get passed through to the method. You can see the next line tells the interpreter to wait for that many frames, if the box (@params[11]) is checked.
@params[7], @params[8], @params[9], @params[10])
wait(@params[10]) if @params[11]
Yes, the wait is the number of frames the process should take. Wait for Completion doesn't actually get passed through to the method. You can see the next line tells the interpreter to wait for that many frames, if the box (@params[11]) is checked.
interesting. So how would you go about changing the 11th parameter if it isn't passed through to the method?
The method doesn't care about it. It's just a true/false, and it tells the interpreter not to process any more commands until the delay is over.
So I suppose the easiest workaround is to simply add a wait event command equal to the move picture duration, after the script call. Thanks Shaz~
I will just say that you are not going to do very well with trying to create choice branching using script calls.
This is because you have no control over the event command's branch which is critical for correct branching functionality.
I have not looked into an actual working solution so I can't give you any useful info.
If this topic is not closed, I would appreciate help with a script call to determine if an actor is in position one.
Idea: You have a member of your party that you need to speak with an NPC. You move them up to leader position.
Then when the member interacts with the NPC, the NPC can use a conditional branch to check if that party member
is in the party, then a second conditional branch to check if that person is the actual one talking to them.
This is the script call I need. How to determine if player X that was in position 4, now moved to position 0 is really there
as far as the NPC would know.
Idea: You have a member of your party that you need to speak with an NPC. You move them up to leader position.
Then when the member interacts with the NPC, the NPC can use a conditional branch to check if that party member
is in the party, then a second conditional branch to check if that person is the actual one talking to them.
This is the script call I need. How to determine if player X that was in position 4, now moved to position 0 is really there
as far as the NPC would know.
$game_party.leader.id == n
where n is their position in the database.
where n is their position in the database.
I will soonish after I get some stuff sorted out.
And thanks for all the help so far guys! You guys rock <3
Thanks Rachael. I will give that a try immediately. Again thanks so much.
Here is what I did.
@Conditional Branch: [Techie] is in the Party
@Conditional Branch: Script: $game_party.leader.(5) == 5. (the Techie was 5 in the database and 5th in the party)
Text:
Yes
Else
No
Branch End
Error message I receive is Script'Game_Interpreter' line 450: NoMethodError occured.
undefined method 'call' for #<Game_Actor:0x8bafd1c>
This occurs whether or not the Techie has actually been placed as the party leader through the player menu system.
No idea what is wrong here. Should I not have the ( ) around the 5 as in .(5)?
Duh, so stupid of me. just put in the $game_party.leader.id as given and voila! Again thanks to you and everyone in this forum for all they help everyone accomplish.
Here is what I did.
@Conditional Branch: [Techie] is in the Party
@Conditional Branch: Script: $game_party.leader.(5) == 5. (the Techie was 5 in the database and 5th in the party)
Text:
Yes
Else
No
Branch End
Error message I receive is Script'Game_Interpreter' line 450: NoMethodError occured.
undefined method 'call' for #<Game_Actor:0x8bafd1c>
This occurs whether or not the Techie has actually been placed as the party leader through the player menu system.
No idea what is wrong here. Should I not have the ( ) around the 5 as in .(5)?
Duh, so stupid of me. just put in the $game_party.leader.id as given and voila! Again thanks to you and everyone in this forum for all they help everyone accomplish.
I'm no expert, but I think you're supposed to go "$game_party.leader.id == 5" to check if actor 005 is the party leader. Correct me if I'm wrong.
Original thread: https://forums.rpgmakerweb.com/threads/script-call-equivalent-of-events.6248/