Death Watch Status
Version: 1.05
Author: NAMKCOR
Date: Oct. 6, 2007
Version History
- v1.00 - completed version
- v1.01 - bug fixed (turns would not reset if status removed0
- v1.05- death watch affects enemies as well
Planned Future Versions
- v1.10- displays turns left beside Death Watch status (possible, but not 100% planned)
Description
Inflicts characters with the condition Death Watch, which gives them X number
turns to live before they are declared dead at the start of turn X
Features
- easily customizable
- utilizes states to make it easy to create Death Watch skills
Screenshots
N/A for this type of script
Instructions
Place the script above main, below any battle options
add a state called "Death Watch" or what have you
simply change turns_to_live to decide how long the character lasts
simply change DW_status_number to the number of the Death Watch skill in the database
make skills/items or whatnot that add the status Death Watch
you're all set
Script
#=====================================================================================================================
# Death Watch Condition v1.05
#---------------------------------------------------------------------------------------------------------------------
# Created By: NAMKCOR
# Created for the Websites: Chaos Project, RPG Maker Resource Kit
# (www.chaosproject.co.nr; www.rmrk.net)
# If this script is hosted on any other website, then it is stolen, please contact
# me at the address given below
# Requested by: gameo (RMRK)
#--------------------------------------------------------------------------------------------------------------------
# If you find any Bugs/Incompatability issues with this script, please contact me at
# the following e-mail address: Rockman922@aol.com, and please be descriptive
# with your e-mail subject, as I delete spam on sight.
#--------------------------------------------------------------------------------------------------------------------
# Function:
# Inflicts characters with the condition Death Watch, which gives them X number
# turns to live before they are declared dead at the start of the turn marked with
# Death Watch 0
#
# Compatability:
# most likely compatible with SDK (untested)
# most likely compatible with battle modifications (untested)
# no known issues at the moment
#
# Instructions to modify:
# Comments and instructions for the individual customizations will be given
# right where they are located. Only real skills needed are reading, typing,
# and copy&paste
#
# Instructions for use:
# All you need to do to give an enemy a death watch skill, is set the state
# addition for any skill to + for the death watch state
#
#--------------------------------------------------------------------------------------------------------------------
# Version History:
# 1.0 - completed system
# 1.01 - fixed bug where the dw_turns would not be reset if status was removed
# 1.05 - death watch also affects enemies
#====================================================================================================================
#================================================================================
# START DONT TOUCH
#================================================================================
class Game_Battler
attr_accessor :dw_turns
alias old_init initialize
def initialize
old_init
@dw_turns = 0
end
end
#================================================================================
# END DONT TOUCH
#================================================================================
#====================================================================================================================
# - DW_status_number - the number of the Death Watch status in the database
# - turns_to_live - the number of turns before Death Watch kills the character
#====================================================================================================================
class Scene_Battle
alias oldstart start_phase2
def start_phase2
#modify turns to live
@turns_to_live = 3
#modify DW_status_number
@DW_status_number = 17
#===========================================================================
# DO NOT EDIT BELOW THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING
#===========================================================================
oldstart
for i in 0...$game_party.actors.size
for j in 0...$game_party.actors[i].states.size
if $game_party.actors[i].hp > 0
if $game_party.actors[i].states.include?(@DW_status_number)
if $game_party.actors[i].dw_turns >= @turns_to_live
$game_party.actors[i].hp = 0
$game_party.actors[i].dw_turns = 0
@status_window.refresh
else
$game_party.actors[i].dw_turns += 1
end
else
$game_party.actors[i].dw_turns = 0
end
end
end
end
for i in 0...$game_troop.enemies.size
for j in 0...$game_troop.enemies[i].states.size
if $game_troop.enemies[i].hp > 0
if $game_troop.enemies[i].states.include?(@DW_status_number)
if $game_troop.enemies[i].dw_turns >= @turns_to_live
$game_troop.enemies[i].hp = 0
$game_troop.enemies[i].dw_turns = 0
@status_window.refresh
else
$game_troop.enemies[i].dw_turns += 1
end
else
$game_troop.enemies[i].dw_turns = 0
end
end
end
end
end
end
Credit
- Creator: NAMKCOR
- Requested By: Gameo
Thanks
- Gameo - for giving me the idea
Support
You may contact me at the email address below/found in the comments of the script
Rockman922@aol.com
or you may PM me here or on
www.chaosproject.co.nrplease title your messages accordingly, I delete spam on sight
Known Compatibility Issues
No known compatibility issues at the moment
Demo
N/A at the moment
Author's Notes
Fun Fact - the comments are longer than the script itself
Restrictions
Created for the Websites: Chaos Project, RPG Maker Resource Kit
(
www.chaosproject.co.nr; www.rmrk.net)
If this script is hosted on any other website, then it is stolen, please contact me at either of the locations given
If you use this script in your game, please link me to the topic
I love to see what my work is used for
do NOT use this script in a commercial game unless you get my permission first