This is an enemy kill quest using Variables, Item Count
(by the player) and Battle Processing .
This is not for random encounters.
In all the enemy kill quests I have looked at, ONLY the quest giver can
keep count of how many kills you have done. This way the player will know how many he has without running back to the quest giver.
By the way, this will work if you don't want to keep track yourself.
Just don't create the item to be tracked and don't do anything that has to do with the item.
I have set up a simple map(understatement) for this in case you want to
make one for this.
For this quest, the
Quest Giver wants
5 Skeletons killed.
First, create the
Skeleton .
I used the Skeleton From the
Monster 1 page
Page1
[/url]
Autonomous : Random
Options : Walking, Stepping
Priority : Same as Characters
Trigger : Autorun
Page2
Conditions : Create a Switch . Call it Took KIll Quest .
This is so you can't interact with the Skeletons before you take the Quest.
Autonomous : Random
Options : Walking, Stepping
Priority : Same as characters
Trigger : Player touch
Now you need to create an Item call it Kill .
Make it a Key Item
Price : 0,
Consume : No
Scope : None
You can add an icon if you have one but, not necessary.
Back to Page2
Now, under Comments :
(Optional)Set move route [this event] Turn toward Player
so the enemy will face the player before the battle starts.
Next@Control Variables
Create a Variable Call it Kill .
Variable : Single
Operation : Add
Constant : 1
Click OK .
This will add one Kill to the Quest Giver's count each time you kill one.
Under that the next@
Change Item Kill +1
This will add one Kill to your Key Item count.
This will add one Skeleton Kil l to your Key Items so you will know how many you have at all times.
Next@
Battle Processing
Make sure not to check Can Escape or Continue if lose..
Next@
Control Self Switch A is ON
That page is done.
Page3
Conditions : Self Switch A is ON.
Graphic : none
Options : Through
Priority : Below Characters so you don't bump into the event
You will also need to create an Enemy in the Enemy section of the database. You can use the one in the Enemy list, but I borrowed one from Thalzon's Battlers. I made them very weak so I could test quicker.
Once you have done that, make a Troop for it.
Make sure to leave Don't Run as is.
Now , for the Quest Giver
He wants you to kill 5 Skeletons.
Page 1
Choose a character graphic for your Quester.
Priority : Same as Characters
Trigger : Action Button
Under Comments :
Just create a conversation of your liking with the Quester establishing what he wants and that you will do it.
Once you have accepted the Quest :
@ Control Switches : Took Skull Quest is ON
@ Control Self Switch A is ON
Page 2
Condition : Self Switch A is ON
Priority : Same as Characters
Trigger : Action Button
Under Comments[ /b]:
Open a Conditional Branch
Variable
Equal to
0
Make sure Set Handling is not checked.
@ Open another Conditional Branch directly under Branch End .
This time do it the same but make it Equal to 1 .
Make sure Set Handling is not checked.
Open another Conditional Branch directly under Branch End .
This time do it the same but make it Not Equal to 5 .
Make sure Set Handling is not checked.
Directly under this one,@ make a Show Text
(Quester ) You have \V[0002] Kills.
Whereas this is Not Equal to 5 , the only numbers not covered by a branch are 2, 3 and 4 .
With the code \V[0002] , the Quester will tell you if you have 2, 3,or 4 Kills.
One more Conditional Branch This time Equal to 5
directly under Branch End .
Make sure Set Handling is not checked.
This one will be for when you have them all .
Directly under the Conditional Branch.
[url=https://forums.rpgmakerweb.com/members/97924/]@show Text:
Quester Wow, you got them all!
Next@ Show Text no graphic Here is your 500G.
Next@ you can make a text for the player saying
Something like "We can sure use this"
Next@ Text no graphic Got 500G.
Next@ Change Gold +500
Play SE Item or Coin work fine for this.
Next@ Change Items Kill
decrease by 5 . This removes the
5 Kills from your
Key Items .
Next@ Control Self Switch B is
ON
Page 3
This is where
Self Switch B takes you.
So, all you have to do is click on
Condition :
Self Switch B is
ON
and
Show Text : Quester Thank you.
Now all he will say is
Thank you .
And that's it.
Any questions, feel free to leave a message. I check no less than daily.
本贴来自国际rpgmaker官方论坛作者:dnel57处,因国际论坛即将永久关站,为了存档多年珍贵资料,署名转载到本论坛存档,由于官方帖子为英文原帖,需要中文翻译请点击论坛顶部切换语言为中文就可以将帖子翻译成中文浏览,方便大家随时查看,原文地址:
https://forums.rpgmakerweb.com/threads/enemy-kill-quest-tutorial-no-script.131406/