Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Damage party inside a script

Hey, I'm using a leader swap script, and I wanted it to damage the entire party whenever they swap...
But I don't know howto do that inside a script...
Someone help me please

Here is the code

Code:
class Game_Party
  def shift_forward
    @actors << @actors.shift
    $game_player.animation_id = 16
    $game_player.refresh
  end
  def shift_backwards
    @actors.insert(0, @actors.pop)
    $game_player.animation_id = 16
    $game_player.refresh
    end
  end

class Scene_Map
  alias_method :seph_partycycling_scnmap_update, :update
  def update
  if Input.trigger?(Input::CTRL)
  unless $game_system.map_interpreter.running? or
  @move_route_forcing or $game_temp.message_window_showing  
      $game_party.shift_backwards
    end
  elsif Input.trigger?(Input::ALT)
  unless $game_system.map_interpreter.running? or
  @move_route_forcing or $game_temp.message_window_showing 
      $game_party.shift_forward
    end
    end
    seph_partycycling_scnmap_update
  end
end

*Script made by SephirothSpawn, minor edits by me
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top