Kill Count BABS Add On
Authors: game_guy
Version: 1.0
Type: Blizz ABS Add On
Key Term: Blizz-ABS Plugin
IntroductionThis keeps track of how many enemies you kill in blizz abs. This includes the ones party members kill and people on your team.
Features
- Keeps track of enemies killed in Blizz ABS
ScreenshotsNone
DemoNone
Scriptif BlizzABS::VERSION < 2.51
raise "Blizz ABS Version isnt high enough. Now Closing."
end
class BlizzABS::Processor
KillCountVariable = 1
alias exp_result_kill_count_later exp_result
def exp_result(enemy)
$game_variables[KillCountVariable] += 1
return exp_result_kill_count_later(enemy)
end
end
$BlizzABS = BlizzABS::Processor.new
InstructionsJust set the variable id to the one you want to use
CompatibilityNone yet found. Not tested with SDK.
Credits and Thanks
- game_guy ~ making it
- Blizzard ~ Death Toll add on in ToA for inspiring me to make this
- RoseSkye ~ Also inspiring me to make this
Author's NotesEnjoy
You should alias the method instead. Your code will become shorter and more compatible. :)
You should also add the checking if Blizz-ABS is there like I described in the manual.
module BlizzABS
KillCountVariable = 1 # Variable ID to store amount of enemies killed in
class Processor
if BlizzABS::VERSION < 2.51
print "Blizz ABS Version isnt high enough. Now Closing."
$scene = nil
else
alias kill_count_later exp_result
def exp_result(enemy)
$game_variables[BlizzABS::KillCountVariable] += 1
kill_count_later
end
end
end
end
Would that work?
Like this and that should do it.
if BlizzABS::VERSION < 2.51
raise "Blizz ABS Version isnt high enough. Now Closing."
end
class BlizzABS::Processor
KillCountVariable = 1
alias exp_result_kill_count_later exp_result
def exp_result(enemy)
$game_variables[KillCountVariable] += 1
return exp_result_kill_count_later(enemy)
end
end
$BlizzABS = BlizzABS::Processor.new
I changed it slightly so it looks cleaner. And the last line is necessary so the changes to the class actually apply.
Updated first post with your script Blizzard. Thanks for the help.
Quote from: Rival Blizzard on May 10, 2009, 11:03:07 am
if BlizzABS::VERSION < 2.51
raise "Blizz ABS Version isnt high enough. Now Closing."
end
what is this, the SDK? D:
No, it just prevents you from using an add-on when you don't have Blizz-ABS installed. Imagine somebody with an IQ of room temperature installs "Kill Count BABS Add On" without putting Blizz-ABS above it. In fact the person doesn't even use Blizz-ABS. And suddenly it all crashes. And the person is like "WTF" and wastes our time by posting about a problem caused by his/her own stupidity. This way the person will at least get a slat into his/her face saying "YOU NEED BLIZZ-ABS TO USE THIS SCRIPT, DUMBASS!".
And in fact it should be:
if !$BlizzABS || BlizzABS::VERSION < 2.51
raise 'Blizz-ABS v2.51 or higher not found! RMXP will now close.'
end
The SDK is not a bad concept, it was just terribly realized. If I had made the SDK, it would be compatible and people wouldn't hate it. :/
Quote from: Rival Blizzard on May 11, 2009, 03:20:40 pm
The SDK is not a bad concept, it was just terribly realized. If I had made the SDK, it would be compatible and people wouldn't hate it. :/
Arrogant much? XD. Although you may have a point there.
Cool script though G_G
Look at Blizz-ABS and Tons. Don't you think they are some sort of development kits? And yet they are compatible with loads of other stuff. :/ I would love to make some sort of SDK for RMXP, but I lack the time and people will probably not go for it anyway as there already is an SDK.
I always thought that you should expose Tons as more of a DevKit and allow better integration (with gradients and such, for example)
Quote from: game_guy on May 10, 2009, 02:20:29 am
Credits and Thanks
- game_guy ~ making it
- Blizzard ~ Death Toll add on in ToA for inspiring me to make this
Oh... well.
Quote from: RoseSkye on April 30, 2009, 08:28:10 pm
Quote from: Youngster Gi Gi on April 30, 2009, 08:24:55 pm
Its still coming along. I'll try to squeeze statistics in there but its hard to do that with 8 men in one menu
OFFTOPIC
Its still coming along. I'll try to squeeze statistics in there but its hard to do that with 8 men in one menu :naughty:
You know what'll be cool? If you removed Step count, G, and playtime and added something like an HUD for a character
or ..
"Monsters killed"
"Damage Dealt"
or something like that. . maybe both.
Quote from: game_guy on April 30, 2009, 08:29:51 pm
Quote from: RoseSkye on April 30, 2009, 08:28:10 pm
Quote from: Youngster Gi Gi on April 30, 2009, 08:24:55 pm
Its still coming along. I'll try to squeeze statistics in there but its hard to do that with 8 men in one menu
OFFTOPIC
Its still coming along. I'll try to squeeze statistics in there but its hard to do that with 8 men in one menu :naughty:
You know what'll be cool? If you removed Step count, G, and playtime and added something like an HUD for a character
or ..
"Monsters killed"
"Damage Dealt"
or something like that. . maybe both.
*gets great idea for BABS plugin :naughty:*
Thnx RoseSkye! *powers up*
I am really sorry Rose xD I was thinking someone else wanted me to do this but I forgot :^_^': there added you ;)
Quote from: game_guy on July 07, 2009, 12:40:29 pm
I am really sorry Rose xD I was thinking someone else wanted me to do this but I forgot :^_^': there added you ;)
*Ego stroked* *Flexes muscles* Oh yeaaaaah baby..
G_G you have a msn? I want you talk to one of my scripters helping with my project about your kill count thing. Your view could help me incorporate it into an HUD.
I have msn but I cant get on right now I'm about to head out to go to my grandma's house -_-
she needs help moving stuff out into the shed and I ahve to help
G_G, is it possble to use a variable or something (i dont know what else) so that when enough of certain enemy is killed, you get better items as drops or something like that. Think FF12
If possible, could it be customisised so that diffrent enemies do diffrent things... if i´m not clear just ask for more details ok...
If you could event it it'd be fine. All enemies killed are stored in a variable.
Almost a necropost, errrr, you didn't see anything, ok?
G_G, can you use this script to have a kill count for each of the actors? I'd kinda like a few of my main characters competing.
I might be able to. Not sure if Blizz-Abs detects who actually killed the enemy. I'll mess around with it later.
And the necropost is okay seeing you had a question.
I remember doing this for RoseSkye. I'll dig around for the script.
EDIT: It's not quite the same thing, but it has it for skills and weapons. g_g could use this as a reference to figure out items as well (excuse my hasty/sloppy coding, it was kinda created last minute and tacked on to the HUD I made for him).
# so, this will give kills for attacks and skills to actors. It won't for items,
# or slip damage, because that would be a much longer script. Right now, it
# stores the kill counts in variables 11-14 for easy reference but if you want
# to change, just change the +10 to and different number.
#==============================================================================
# Map_Enemy
#------------------------------------------------------------------------------
# This class handles a map enemy character. It supports pixel movement,
# complete AI handling, advanced sprite handling and battle handling.
#==============================================================================
class Map_Enemy < Map_Battler
# setting all accessible variables
attr_accessor :last_attacker
#----------------------------------------------------------------------------
# attack_effect
# character - the character that holds attack data (can be projectile)
# _battler - the attacking battler
# This method executes attack upon a map character.
#----------------------------------------------------------------------------
alias attack_effect_killcount_later attack_effect
def attack_effect(character, _battler)
result = attack_effect_killcount_later(character,_battler)
if @battler.dead? && _battler.is_a?(Game_Actor)
_battler.kill_count += 1
end
return result
end
#----------------------------------------------------------------------------
# skill_effect
# character - the character that holds skill use (can be projectile)
# _battler - the skill using battler
# skill - the skill
# This method executes skill use upon a map character.
#----------------------------------------------------------------------------
alias skill_effect_killcount_later skill_effect
def skill_effect(character, _battler, skill)
result = skill_effect_killcount_later(character, _battler, skill)
if @battler.dead? && _battler.is_a?(Game_Actor)
_battler.kill_count += 1
end
return result
end
end
#==============================================================================
# ** Game_Actor
#------------------------------------------------------------------------------
# This class handles the actor. It's used within the Game_Actors class
# ($game_actors) and refers to the Game_Party class ($game_party).
#==============================================================================
class Game_Actor < Game_Battler
attr_accessor :kill_count
attr_accessor :kill_timer
attr_accessor :kill_rank
alias initialize_kill_count_later initialize
def initialize(actor_id)
@kill_count, @kill_timer, @kill_rank = 0, 0, 0
initialize_kill_count_later(actor_id)
end
end
THanks wink. Is it missing a bit at the start?
Hehe no. As I said, I was rushed, so I just typed up a quick little explanation of what the script did so that a different scripter could finish it for him. As it says, it doesn't keep track of kills by items or slip damage, so you will need to ask g_g or somebody to add those in (and take out the stuff about rank and time, because its not needed).
Thanks winkio. I'll go off that and add it.
This is a nice basic script, but I was looking for something that would let me keep track of enemies killed by type for quests. So, I can send the player off to kill x amount of zombies or such. Has anyone seen anything like this that would be usable with Blizz-ABS?
That could easily be evented by increasing a variable when each one is killed (you will need to set the trigger to death)
Hey, i have few things i'd like to ask...
One: i'm not sure how to event the 'better item drop' thing, and besides, i'm not sure g_g undestood it right, no offense ment. I'll try to explain it better.
If you kill a certain number of the same (type) enemies, they will begin to drop better items.
Say, we kill five sahagin which have, say ten% of dropping a potion when dead. but, after weäve killed six, there's say 20% they drop potion, or 5% they frop ether. Get it?
But, if we kill say a ghost in between, the chain goes back to one, and counts ghosts now, instead of sahagins... I have a video that should explain things a bit better than me.
The chaining part starts around 1.30 to 2.00 of the vids time: http://www.youtube.com/watch?v=OxDNcGvQLrw&p=977479D95F542BBF&playnext=1&index=7 (http://www.youtube.com/watch?v=OxDNcGvQLrw&p=977479D95F542BBF&playnext=1&index=7)
Two: Could be made so that the chain number would be displayed briefly on the screen after killing an enemy (unless it's the first of that type)
Quote from: game_guy on May 15, 2010, 04:23:37 pm
Thanks winkio. I'll go off that and add it.
Did you add it?
I'm not quite sure how one would go about tracking numbers of monster kills in my game. If you mean within the monster group event box, I don't think that's possible for me, as I am using Blizz ABS, which bypasses the monster groups entirely.
I made a blizzabs counter for each type of monster with quest in mind i believe I called it individual enemy counter just look in the scripts section
Can it keep track of players u killed?