State Requirement Skills
Authors: [Faint]
Version: 1.0
Type: Skill Add-On
Key Term: Custom Skill System
IntroductionSimple script that allows you to set state requirements for skills.
Features
ScreenshotsN/A
DemoN/A
Script
#*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=#
# State Requirement Skills #
# Author: [Faint] #
# Version: 1.0 #
# Date: 11/10/2009 #
#*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=#
# #
# This Add-on allows you to make skills require a specified state to be #
# inflicted upon the actor before they can use said skill. #
#*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=#
module SRConfigs
def self.req_state(id)
case id
#*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=#
# Configs #
# #
# when SKILL_ID then return REQUIRED_STATE_ID #
# SKILL_ID - ID of the Skill. #
# REQUIRED_STATE_ID - ID of the State required to use the Skill. #
#*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=#
when 1 then return 17
end
return
end
end
#==============================================================================#
# Game_Battler #
#==============================================================================#
class Game_Battler
alias state_met? skill_can_use?
def skill_can_use?(skill_id)
data = SRConfigs.req_state(skill_id)
return data != nil && !self.state?(data) ? false : state_met?(skill_id)
end
end
InstructionsPlace above Main.
CompatibilityNo none compatibility issues.
Credits and Thanks
- Everyone here at chaos-project that has helped me out in understanding RGSS.
Author's NotesWoot for first working script.
Very nice, I may use this in the future.
*databases*
Want me to add this to Tons? I could also add a few other of your scripts. :P
sure :D I didnt think this would be worth to add to tons but if you want to add it then by all means feel free to.
I'll get to it as soon as I can.
ok cool ;)
->Pretty good script...
*levels up*
†
:^_^': Thanks it's my first working script so naturally it's not very complex.
->Yeah, I remember when we were still asking so much questions... :) Sadly, I still am... :P
†
I just read lots of guides and such. Then I decided to make a new Project folder and just mess around and find what stuff did while referencing how to guides and syntax guides. :^_^':
->Yeah, I guess I'm just unlucky... The semester just started so I'll probably be slowing down on my project, and a girl just rejected me so I'm feeling reaaaaaaaaalllly bad right now... :^_^': Anyway, good luck on your project! :D
†
Nice little script, I'll probably be using it ;)
Thanks, nice to know some other people besides myself have use for this.