I created a NPC who is a salesman who sells items for half of the buy price, except the catch, he appears in the beginning town, 1/7 chance. At the beginning, their just items like Potions, Ethers, and Antidotes..etc...is there way I can regulate the type of items he sells depending on the Player's level/progress?; Using Variables?
Please.......
Read more tutorials?
Quote from: Leventhan on October 25, 2007, 03:29:33 AM
Please.......
Read more tutorials?
>_>
Your not being any help.
Of course you can,,that's what CONDITIONAL BRANCH is for.
Quote from: djkdjl on October 25, 2007, 04:15:19 AM
Of course you can,,that's what CONDITIONAL BRANCH is for.
What I meant to him was that...
I looked on google, and here for Variable tuts, all of them never explained how to use the Hero's X(Level, EXP, HP, etc...) sub-function, or any uses for it.
I assume you are using rpg maker xp.
1) Page 1 command: CONTROL VARIABLES
name the variable #001: HERO level [name can be different,,variable # can be different]
Set it to: ACTOR, select your main hero, then LEVEL
2) Page 1 command: CONDITIONAL BRANCH
Variabe: #001 HERO level
greater than or equal to
Constant: 40 [checkmark the set handling when conditions do not apply
Call SHOP [add items for level 40 hero]
3) in the ELSE section
Repeat step 2, except make the Constant: 30 [or 20, or 10, or 1]
4) Repeat step 3
I don't want to post the full tutorial with pictures for this.
Thanks.
For constant, can I use random numbers instead? Like 1-10, for deciding level range.
You can't really set range that way. If you follow the tutorial,,what happens is this:
IF 40 <= hero_level <=99, then CALL SHOP 1 [Range: 40-99]
ELSE
IF 30<= hero_level <=40, then CALL SHOP 2 [Range: 30-40]
ELSE
IF 20<= hero_level <= 30, then CALL SHOP 3 [Range: 20-30]
etc....
Of course by writing down different constants you create a different range.