Hello. I have copyed and modified some Bank Event, and i was wondering...
When you leave the map in witch the event is, you still continue to get the interests?
I'm trying to make 2 different Common Event, one allowing me to get interests from the bank, and another one, to make Grow Plants where i'm away from the place i've planted them.
My Code is: For the bank in a normal Event called Bank:
NPC: Priority-As Player, Trigger-Action Button
Call Common Event: Bank
Common Event Bank:
Control Variable: [0087 Deposit]= Variable [0082 Gold in Bank]
Control Variable: [0081 Gold in Inventory]= Gold
Control Variable: [0083 Give to Bank]=0
Control Variable: [0084 Take from Bank]=0
Show Choice: [Deposit some Gold, Withdraw some Gold, How much i have?,Nothing...]
When:[Deposit some Gold]
Text: How much you will Give to the Bank to take care of?
Input Number:[0083 Give to Bank] 8 digits
Conditional Branch: Variable: [0083 Give to Bank] =< [0081 Gold in Inventory]
Control Variable: [0082 Gold in Bank] +[0083 Give to Bank]
Change Gold: -Variable: [0083 Give to Bank]
Text: Tanks, we will take care of your \v[0083] Gold.
Control Switches: [0092 Gain] =On
Control Variable: [0083 Give to Bank]=0
Else Text: Sorry, you dont have that much Gold, sir...
Control Variable: [0083 Give to Bank]=0
Branch End
When: [Withdraw some Gold]
Text: How much will you take back?
Input Number:[0084 Take from Bank] 8 digits
Conditional Branch: Variable: [0084 Withdraw from Bank] =< [0082 Gold in Bank]
Control Variable: [0082 Gold in Bank] -[0084 Withdraw from Bank]
Change Gold: +Variable: [0084 Withdraw from Bank]
Text: Here there are your \v[0084] Gold, Sir.
Control Variable: [0084 Withdraw from Bank]=0
Else Text: Sorry, you dont have that much Gold, sir...
Control Variable: [0084 Withdraw from Bank]=0
Branch End
When: [How much i have?]
Text: You have \v[0082] Gold within our Bank, sir.
Branch End
The Interests Common Event is like this: Interest: Parallel Process
Label: Start
Control Variable: [0086 Interests Rate] = Variable [0082 Gold in Bank]
Control Variable: [0085 Interests] = +1
Wait 60 frames
Conditional Branch: Variable [0085 Interests] = = 60
Control Variable: [0086 Interests Rate] / = 100
Control Variable [0082 Gold in Bank] + [0086 Interests Rate]
Control Variable Variable [0085 Interests] = 0
Jump to Label: Start
Else
Branch End
Now...it give around 1% of Bank deposit Gold every 60 seconds, if i stay on the same map of the bank. What if i leave and go around?
When i'm back after 10 minutes, i didnt have 10% more money...
if i put the Common Event in every single map of the game, it seems to work...
But it is so that i must do? Or there is another easyest way to do it?
For the Plant, the Code-Event is similar
An event in a place: Same as Bank, like this:
Event Name: Tree 1
The first page of event show the picture of a hole in the terrain:
Priority-Below Player, Trigger-Action Button
Text: Did you wish to plant a Tree there Milord? It will cost you 2000 Gold.
Show Choice: [yes, no,]
When: [yes]
Conditional Branch: Gold 2000 or more
Text: Good Milord, now i will take care of the plant when tou are away.
Come back some time later to see if it is ready to be used.
Self Switch: A= on
Change Gold: -2000
Else: Text: Sorry Milord, you dont have enought money...
Branch End
When: [no]
When Cancel:
Branch End
The second page of the same event is a Little Plant picture:
Priority-Same as Player, Trigger-Action Button, self switch A is on
Label: Tree 1
Wait: 600 frames (About 10 seconds)
Control Variable [0053 Trees Growt] = +1
Conditional Branch:[0053 Tree Growt 1] >= 60 (so it grows in ten minutes)
Control Variable [0053 Trees Growt] = -60
Control Self Switch: A = off
Control Self Switch: B = on
Else:
Jump to Label: Tree 1
End Branch:
The Third page of the same event is a Full Growt tree:
Priority-Same as Player, Trigger-Action Button, self switch B is on
(The Woodcutter Axe it is actually a weapon)
Conditional Branch:[Woodcutter Axe] is in Inventory, Include Equipment
Text: This Tree could be cut to give me some Wood...
Show Choice: [ok i will cut it, No i will do it later...]
When [ok i will cut it]
Control Variable [0051 Woodcutter Practice] = +1
Conditional Branch:[0051 Woodcutter Practice] >= 25
Control Variable [0050 Woodcutter Skill] = +1
Else:
Branch End:
Control Variable [0041 Cutting a Tree] = Random no (1...5)
Control Variable [0041 Cutting a Tree] + Variable [0050 Woodcutter Skill]
Set Move Route: Player:
Turn 90° Right
Wait 30 frames
Turn 90° Left
Wait 30 frames
Play SE: 'Slash 10' 80, 110
Set Move Route: Player:
Turn 90° Right
Wait 30 frames
Turn 90° Left
Wait 30 frames
Play SE: 'Slash 10' 80, 110
Conditional Branch:[0041 Cutting a Tree] >= 6
Control Variable [0052 Wood Gain] = Random no (1...5)
Control Variable [0052 Wood Gain] + Variable [0050 Woodcutter Skill]
Text: Good! I Chopped v\[0052] Trunks! Now i just need for the plant to grows
again to cut more...
Change Items: [Trunks] + Variable [0052 Wood Gain]
Control Self Switch: B = off
Control Self Switch: C = on
Else:
Play ME: 'Gag' ,100,75
Show Balloon Icon: Player, Esclamation
Text: Damn...i've broke my Axe!
Change Weapon: [Woodcutter Axe] -1, Include Equipment
Branch End:
When: [no, ill do later]
When Cancel:
Branch End
Else:
Branch End
Wow...almost done...
The last page of this event show a cutted trunk half-grow from terrain
Priority-Same as Player, Trigger-Action Button, self switch C is on
Label: Tree 1A
Wait: 600 frames (About 10 seconds)
Control Variable [0053 Trees Growt] = +1
Conditional Branch:[0053 Tree Growt 1] >= 60 (so it grows in ten minutes)
Control Variable [0053 Trees Growt] = -60
Control Self Switch: C = off
Control Self Switch: B = on
Else:
Jump to Label: Tree 1A
End Branch:
Thats all...but as for the bank, if i leave the place where the event is, it didnt grow at all!
Have you Experts some idea as to make the bank give interests and the trees growt if i'm away?
also i noticed that if i copy-past the tree event and call it something like Tree 2 and all the Label i modified in Tree 2, but still use the same Variable for all, Variable [0053 Trees Growt], they do growth, but after i cut them, the game freeze.
Also if i replace the event on the last page like this:
Label: Tree 1A
Conditional Branch:[0053 Tree Growt 1] >= 60 (so it grows in ten minutes)
Control Variable [0053 Trees Growt] = -60
Control Self Switch: C = off
Control Self Switch: B = on
Else:
Jump to Label: Tree 1A
End Branch:
in that case i have a common event called [Tree Grows] that start as Parallel and say just:
Wait: 600 frames (About 10 seconds)
Control Variable [0053 Trees Growt] = +1
Any idea? I know my event is a bit complex, and be aware that i'm italian so i have translated as best as i can the name of variables and text XD
I hope someone can help ^^ i'm a bit in truble eheheh