Kill counter issue.

Started by fjshrr5, October 18, 2014, 10:16:51 pm

Previous topic - Next topic

fjshrr5

I'm trying to get this kill counter to work, Though i'm a noob when it comes to things like this, sad yes, i know.
I've got no idea where to put what script calls, I assume that is what i have to do? Using "Comments" ? I'm not really sure.
I'm totally confused, i'm sorry.

Below is the link to the kill counter script, He does say what "script calls" To use.
Though i'm not sure where to use them.. On the quest giver, on the monster? Anybody care to give me a step by step with more details as to where exaclty i place them. and do i use Comments or something else?


http://forum.chaos-project.com/index.php/topic,7733.0.html

KK20

First off, script calls are used with the 'Script' event command, located at the very bottom right on tab 3. 'Comment' will do nothing for you (however, some scripts say to use Comments in order for their scripts to work, so be sure to watch for that).

Starting the counter should be done in your quest-giver event. The 'id' can be any integer number, so long as you remember this number to refer back to later on. If you accidentally use the same number for a second counter, you're going to override your first counter and lose your count. 'enemy_id' is an integer associated with the enemy's database ID.

This will start counters for how many Ghosts and Zombies you kill.
$game_player.start_counter(1, 1)
$game_player.start_counter(2, 9)


Now go and be happy killing all the monsters you want.

When you return to your quest-giver event, use a 'Conditional Branch', go to the 4th tab and select the 'Script' radio button. In the text box, paste this:
$game_player.get_counter(2) >= 5

If your player kills 5 Zombies or more, this conditional branch will return TRUE and should reward the player. Here's an example:


The stop_counter script call is best left for situations such as "Kill 10 Ghosts in 1 minute!", where you start the counter for number of Ghosts killed and starting a timer with the event command 'Control Timer'. When the timer hits zero, you can then call stop_counter.

I don't see much of a use for total_killed unless you NEVER use stop_counter once in your game.

Other Projects
RPG Maker XP Ace  Upgrade RMXP to RMVXA performance!
XPA Tilemap  Tilemap rewrite with many features, including custom resolution!

Nintendo Switch Friend Code: 8310-1917-5318
Discord: KK20 Tyler#8901

Join the CP Discord Server!

fjshrr5

i really appreciate it! thank you