Project1

标题: 横板2.7的战斗提示信息求助 [打印本页]

作者: samelidifinte    时间: 2011-2-26 15:39
提示: 作者被禁止或删除 内容自动屏蔽
作者: cangyu2004    时间: 2011-2-26 17:22
- - :L 没有啥是不可能的,就是要脚本高手来处理下
作者: Rion幻音    时间: 2011-2-26 17:48
脚本在这:
http://kaisouryouiki.web.fc2.com ... l_time_gain_exp.txt
作者: samelidifinte    时间: 2011-2-27 01:30
提示: 作者被禁止或删除 内容自动屏蔽
作者: Rion幻音    时间: 2011-2-27 15:14
我是可以打开,但会变成乱码……
算了,脚本在这:
  1. =begin
  2.       仛儕傾儖僞僀儉EXP仛

  3.       宱尡抣偺庢摼傪丄愴摤廔椆帪偱偼側偔揋傪搢偟偨偦偺弖娫偵峴偄傑偡丅
  4.       儗儀儖傾僢僾傕偦偺僞僀儈儞僌偱峴偄傑偡丅
  5.       
  6.       ver1.00

  7.       Last Update : 2009/11/28
  8.       11/28 : 怴婯
  9.       
  10.       傠偐傫丂丂丂http://kaisouryouiki.web.fc2.com/
  11. =end

  12. #===========================================
  13. #   愝掕売強
  14. #===========================================
  15. module Rokan
  16. module RealTimeGainExp
  17.     # 摨偠僄僱儈乕偐傜偼俀夞埲忋宱尡抣傪庢摼偟側偄傛偆偵偡傞偐偳偆偐
  18.     # 乽搢偡仺宱尡抣庢摼仺暅妶仺搢偡仺宱尡抣庢摼仺暅妶乿偲偄偆棳傟傪杊偖堊丅
  19.     EDEG = false
  20.     # 宱尡抣庢摼帪偵昞帵偡傞儊僢僙乕僕
  21.     # (愴摤晄擻儊僢僙乕僕偺捈屻偵憓擖偝傟傑偡)
  22.     GRE_MESSAGE = "%s 偺宱尡抣庢摼両"
  23. end
  24. end
  25. #===========================================
  26. #   偙偙傑偱
  27. #===========================================

  28. $rsi = {} if $rsi == nil
  29. $rsi["儕傾儖僞僀儉EXP"] = true

  30. class Game_Enemy < Game_Battler
  31.   #--------------------------------------------------------------------------
  32.   # 仠 僀儞僋儖乕僪 Rokan::DeadActorGainExp
  33.   #--------------------------------------------------------------------------
  34.   include Rokan::RealTimeGainExp
  35.   #--------------------------------------------------------------------------
  36.   # 仠 岞奐僀儞僗僞儞僗曄悢
  37.   #--------------------------------------------------------------------------
  38.   attr_accessor :collapse_exp          # 寕攋宱尡僼儔僌
  39.   #--------------------------------------------------------------------------
  40.   # 仠 僆僽僕僃僋僩弶婜壔
  41.   #--------------------------------------------------------------------------
  42.   alias set_collapse_exp initialize
  43.   def initialize(index, enemy_id)
  44.     set_collapse_exp(index, enemy_id)
  45.     @collapse_exp = false
  46.   end
  47.   #--------------------------------------------------------------------------
  48.   # 仠 僐儔僾僗偺幚峴
  49.   #--------------------------------------------------------------------------
  50.   alias send_exp_troop perform_collapse
  51.   def perform_collapse
  52.     send_exp_troop
  53.     if $game_temp.in_battle && dead?
  54.       $game_troop.realtime_exp += exp if ! @collapse_exp || ! EDEG
  55.       @collapse_exp = true
  56.     end
  57.   end
  58. end

  59. class Game_Troop < Game_Unit
  60.   #--------------------------------------------------------------------------
  61.   # 仠 岞奐僀儞僗僞儞僗曄悢
  62.   #--------------------------------------------------------------------------
  63.   attr_accessor :realtime_exp          # 偦偺僞乕儞偺庢摼宱尡抣検
  64.   #--------------------------------------------------------------------------
  65.   # 仠 僋儕傾
  66.   #--------------------------------------------------------------------------
  67.   alias rtexp_initialize clear
  68.   def clear
  69.     rtexp_initialize
  70.     rtexp_clear
  71.   end
  72.   #--------------------------------------------------------------------------
  73.   # 仠 儕傾儖僞僀儉EXP偺僋儕傾
  74.   #--------------------------------------------------------------------------
  75.   def rtexp_clear
  76.     @realtime_exp = 0
  77.   end
  78.   #--------------------------------------------------------------------------
  79.   # 仠 宱尡抣偺崌寁寁嶼丂丂丂仸嵞掕媊
  80.   #--------------------------------------------------------------------------
  81.   def exp_total
  82.     return 0
  83.   end
  84. end

  85. class Scene_Battle < Scene_Base
  86.   #--------------------------------------------------------------------------
  87.   # 仠 僀儞僋儖乕僪 Rokan::DeadActorGainExp
  88.   #--------------------------------------------------------------------------
  89.   include Rokan::RealTimeGainExp
  90.   #--------------------------------------------------------------------------
  91.   # 仠 峴摦寢壥偺昞帵
  92.   #--------------------------------------------------------------------------
  93.   alias rtexp_result display_action_effects
  94.   def display_action_effects(target, obj = nil)
  95.     rtexp_result(target, obj = nil)
  96.     gain_rtexp
  97.   end
  98.   #--------------------------------------------------------------------------
  99.   # 仠 儕傾儖僞僀儉EXP傪儊儞僶乕偵暘攝
  100.   #--------------------------------------------------------------------------
  101.   def gain_rtexp
  102.     return if $game_troop.realtime_exp == 0
  103.     member = $rsi["愴摤晄擻幰宱尡抣庢摼"] ?
  104.     $game_party.members : $game_party.existing_members
  105.     exp = $game_troop.realtime_exp
  106.     for actor in member
  107.       point = exp
  108.       point *= (DEPP / 100.0) if $rsi["愴摤晄擻幰宱尡抣庢摼"] && actor.dead?
  109.       last_level = actor.level
  110.       last_skills = actor.skills
  111.       actor.gain_exp(point.to_i, true)
  112.     end
  113.     wait_for_message
  114.     $game_troop.rtexp_clear
  115.   end
  116.   #--------------------------------------------------------------------------
  117.   # 仠 儕傾儖僞僀儉EXP庢摼偺昞帵
  118.   #--------------------------------------------------------------------------
  119.   def display_rtexp(target)
  120.     return if target.actor?
  121.     text = sprintf(GRE_MESSAGE, $game_troop.realtime_exp)
  122.     @message_window.add_instant_text(text)
  123.   end
  124.   #--------------------------------------------------------------------------
  125.   # 仠 晅壛偝傟偨僗僥乕僩偺昞帵
  126.   #--------------------------------------------------------------------------
  127.   alias rtexp? display_added_states
  128.   def display_added_states(target, obj = nil)
  129.     rtexp?(target, obj = nil)
  130.     display_rtexp(target) unless $game_troop.realtime_exp == 0
  131.   end
  132. end
复制代码

作者: samelidifinte    时间: 2011-2-27 16:00
提示: 作者被禁止或删除 内容自动屏蔽




欢迎光临 Project1 (https://rpg.blue/) Powered by Discuz! X3.1