manji
RPG Making Novice
Posts: 64
|
Post by manji on Feb 22, 2006 12:38:59 GMT -5
how do i get to change what an NPC says based on who the party leader is at the time?
i would guess a conditional variable or flag that would check who's in front, but is there a pre-made variable/flag like that? would i make it myself?
|
|
|
Post by LunarMoon2 on Feb 22, 2006 13:54:33 GMT -5
Try creating a condition with variable 86: Member Number.
|
|
|
Post by BloodKnight on Feb 22, 2006 14:12:46 GMT -5
Let's see:
-Data:Variable"Member Order" = 0 -Data:Member Info:Use Member Order(or something like that) -Member Info Load -Condition:Variable"Member Number" = X *whatever happens -Condtiion End
I think that's how you check for the first member in your party.
|
|
|
Post by christi on Feb 22, 2006 14:18:41 GMT -5
Are you using the Default Menu System, and allowing players to chose who the leader is at any given time? If that's the case, I'm not sure how you'd go about doing that...
But, if you're switching leaders manually through script commands, just make a flag for each potential "leader," and turn it on when you change the leader. Then you could do Script Branch Conditions for each potential scenario.
As far as presets, I know there's a preset condition in the Event Editor that checks if a member is in your party before executing the page... but, to my knowledge, there's not one specifically for the leader.
|
|
|
Post by Doan the Nado on Feb 22, 2006 16:59:18 GMT -5
BloodKnight's code is almost perfect. The only thing is that you do not need to use the "Member Info: Load" command. When you use "Data:Member Info:Use Member Order(or something like that)", it places the Member number of the leader in Variable 86. This is typically followed by a load to obtain his stats, but in this case, it is [not] necessary because you are interested only in the member number.
Edit by Doan: added the [not] because my previous post was a typo
|
|
manji
RPG Making Novice
Posts: 64
|
Post by manji on Feb 22, 2006 23:12:00 GMT -5
awesome. thank you everyone.
|
|
|
Post by Dungeon Warden on Mar 4, 2006 15:41:59 GMT -5
Unless you change it, Member order contains the number of the currently active character, which is the leader 99% of the time (Only if a party member is selected or preforms an action [ex. adds/removes equipment] will they become active.) The leader is always the active character when the party is walking around or activates an event.
You could also sort Input 2: Leader Name, which will always contain the leader's name. However, if you are planing to give something to the leader, you should make sure the Member Order value is correct first, and then use Member Info: Load (remember to use Member Info: Save afterword).
|
|