Group: Member
Posts: 35
Type: Developer
RM Skill: Skilled
(Pretty sure this is in the right spot) I was having a custom script being done for my game, but the person scripting it hasn't improved upon this script and hasn't even started and it's been around a month.
The script was made to allow the damage of a skill happen DURING the skill's animation. This allows battles to go a lot faster, and gives the game a more realistic perspective.
The problems with this script are two things: 1. Using "Attack" makes the Attack hit twice, or 4 times for "Dual attack" attacks. 2. Same thing using items that heal/damage ETC.
I normally wouldn't post it, I'm not sure if he wants others using it, but it doesn't work in it's current state due to these 2 problems.
Hungrysnake's Show Damage
CODE
# ============================================================================ # # Quick snippet by HungrySnake # # # # This snippet simply shows the dealt damage directly after using a skill. # # It's plug and play # # ============================================================================ #
def display_normal_animation(targets, animation_id, mirror = false) animation = $data_animations[animation_id] if animation != nil to_screen = (animation.position == 3) # Is the positon "screen"? for target in targets.uniq target.animation_id = animation_id target.animation_mirror = mirror for target1 in targets target1.skill_effect(@active_battler, @skill_lol) display_action_effects(target1, @skill_lol) end wait(20, true) unless to_screen # If for one, wait end wait(20, true) if to_screen # If for all, wait end end end
__________________________
My epic game. Put this in your siggy if you support it! Demo was just updated, check it out!
Group: Global Mod
Posts: 1,414
Type: Scripter
RM Skill: Advanced
Rev Points: 15
What engine is this for? I tried to do something in VX Ace. It doesn't draw at the same time, but it pretty much instant.
CODE
#============================================================================== # :: Show Damage Instantly :: #------------------------------------------------------------------------------ # Author : Legacy # Date : 17.08.2012 #------------------------------------------------------------------------------ # Instructions: # To instal the script, open you script editor and paste this script on # a new section bellow the Materials section. # #------------------------------------------------------------------------------ # Description: # This is a snippet to allow for the damage to be drawn instantly after the # animation is executed.
class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # * Wait Until Animation Display has Finished #-------------------------------------------------------------------------- def wait_for_animation update_for_wait end #-------------------------------------------------------------------------- # * Wait Until Effect Execution Ends #-------------------------------------------------------------------------- def wait_for_effect update_for_wait end #-------------------------------------------------------------------------- # * Show Attack Animation # targets : Target array # Account for dual wield in the case of an actor (flip left hand weapon # display). If enemy, play the [Enemy Attack] SE and wait briefly. #-------------------------------------------------------------------------- def show_attack_animation(targets) if @subject.actor? show_normal_animation(targets, @subject.atk_animation_id1, false) show_normal_animation(targets, @subject.atk_animation_id2, true) else Sound.play_enemy_attack abs_wait(5) end end #-------------------------------------------------------------------------- # * Show Normal Animation # targets : Target array # animation_id : Animation ID # mirror : Flip horizontal #-------------------------------------------------------------------------- def show_normal_animation(targets, animation_id, mirror = false) animation = $data_animations[animation_id] if animation targets.each do |target| target.animation_id = animation_id target.animation_mirror = mirror abs_wait(5) unless animation.to_screen? end abs_wait(5) if animation.to_screen? end end end