设为首页收藏本站

仙剑之十里坡

 找回密码
 加入我们

QQ登录

只需一步,快速开始

搜索
查看: 4339|回复: 7
打印 上一主题 下一主题

脚本问题。

[复制链接]

12

主题

1

听众

148

积分

略有小成

会员等级: 2

该用户从未签到

精华
0
积分
148
历练
0
声望
1
人气
6
单身中……
帮我摆脱单身吧
跳转到指定楼层
1
发表于 2011-6-3 21:02:52 |只看该作者 |倒序浏览
我用45度脚本时,战斗测试结果还和原来一样,一点改变也没有。八方行走图的脚本用了也没反应啊。
分享到: QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
转播转播0 分享淘帖0 分享分享0 收藏收藏0

12

主题

1

听众

148

积分

略有小成

会员等级: 2

该用户从未签到

精华
0
积分
148
历练
0
声望
1
人气
6
单身中……
帮我摆脱单身吧
2
发表于 2011-6-3 21:14:11 |只看该作者
我用的脚本
#==============================================================================
# ■ Game_Actor
#------------------------------------------------------------------------------
#  处理角色的类。本类在 Game_Actors 类 ($game_actors)
# 的内部使用、Game_Party 类请参考 ($game_party) 。
#==============================================================================

class Game_Actor < Game_Battler
#--------------------------------------------------------------------------
# ● 取得战斗画面的 X 坐标
#--------------------------------------------------------------------------
def screen_x
case self.index
when 0
   return 350
when 1
   return 430
when 2
   return 510
when 3
   return 580
else
   return 600

  end
end
#--------------------------------------------------------------------------
# ● 取得战斗画面的 Y 坐标
#--------------------------------------------------------------------------
def screen_y
case self.index
when 0
   return 430
when 1
   return 395
when 2
   return 360
when 3
   return 325
else
   return 1000
  end
end
#--------------------------------------------------------------------------
# ● 取得战斗画面的 Z 坐标
#--------------------------------------------------------------------------
def screen_z
case self.index
when 0
   return 10
when 1
   return 9
when 2
   return 8
when 3
   return 7
else
   return 0
   end
end
end


#==============================================================================
# ■ Window_Base
#------------------------------------------------------------------------------
#  游戏中全部窗口的超级类。
#==============================================================================

class Window_Base < Window
#--------------------------------------------------------------------------
# ● 描绘 HP
#     actor : 角色
#     x     : 描画目标 X 坐标
#     y     : 描画目标 Y 坐标
#     width : 描画目标的宽
#--------------------------------------------------------------------------
def draw_actor_hp1(actor, x, y, width = 72)
   # 描绘字符串 "HP"
   self.contents.font.color = system_color
   self.contents.draw_text(x, y, 24, 24, $data_system.words.hp)
   # 计算描绘 MaxHP 所需的空间
   if width - 24 >= 32
     hp_x = x + 32# + width - 24
   end
   # 描绘 HP
   self.contents.font.color = actor.hp == 0 ? knockout_color :
     actor.hp <= actor.maxhp / 4 ? crisis_color : normal_color
   self.contents.draw_text(hp_x, y, 32, 24, actor.hp.to_s, 2)
end
#--------------------------------------------------------------------------
# ● 描绘 SP
#     actor : 角色
#     x     : 描画目标 X 坐标
#     y     : 描画目标 Y 坐标
#     width : 描画目标的宽
#--------------------------------------------------------------------------
def draw_actor_sp1(actor, x, y, width = 72)
   # 描绘字符串 "SP"
   self.contents.font.color = system_color
   self.contents.draw_text(x, y, 24, 24, $data_system.words.sp)
   # 计算描绘 MaxSP 所需的空间
   if width - 24 >= 32
     sp_x = x + 32# + width - 24
   end
   # 描绘 SP
   self.contents.font.color = actor.sp == 0 ? knockout_color :
     actor.sp <= actor.maxsp / 4 ? crisis_color : normal_color
   self.contents.draw_text(sp_x, y, 32, 24, actor.sp.to_s, 2)
end
end





#==============================================================================
# ■ Window_BattleStatus
#------------------------------------------------------------------------------
#  显示战斗画面同伴状态的窗口。
#==============================================================================

class Window_BattleStatus < Window_Base
#--------------------------------------------------------------------------
# ● 初始化对像
#--------------------------------------------------------------------------
#$data_system_level_up_me = "Audio/ME/升级音乐"
def initialize
   super(0, 0, 640, 480)
   self.contents = Bitmap.new(width - 10, height - 32)
   self.opacity = 0
   @level_up_flags = [false, false, false, false]
   refresh
end
#--------------------------------------------------------------------------
# ● 释放
#--------------------------------------------------------------------------
def dispose
   super
end
#--------------------------------------------------------------------------
# ● 设置升级标志
#     actor_index : 角色索引
#--------------------------------------------------------------------------
def level_up(actor_index)
   @level_up_flags[actor_index] = true
end
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
def refresh
   self.contents.clear
   @item_max = $game_party.actors.size
    for i in 0...$game_party.actors.size
     actor = $game_party.actors[i]
     case i
       when 0
        x = 310
        y = 390
       when 1
        x = 390
        y = 340
       when 2
        x = 480
        y = 300
       when 3
        x = 550
        y = 270
      end
     if @level_up_flags[i]
       self.contents.font.color = normal_color
       self.contents.draw_text(x, y, 80, 24, "LEVEL UP!")
       Audio.me_stop
#        Audio.me_play($data_system_level_up_me)
     else
     draw_actor_hp1(actor, x-15, y-15, 80)
     draw_actor_sp1(actor, x-15, y+5, 80)
    end
   end
end

#--------------------------------------------------------------------------
# ● 刷新画面
#--------------------------------------------------------------------------
def update
   super
   # 主界面的不透明度下降
   if $game_temp.battle_main_phase
     self.contents_opacity -= 50 if self.contents_opacity > 1
   else
     self.contents_opacity += 50 if self.contents_opacity < 255
   end
end
end





#==============================================================================
# ■ Window_BattleStatus
#==============================================================================
class Window_BattleStatus < Window_Base
#--------------------------------------------------------------------------
# ● 初始化
#--------------------------------------------------------------------------
alias xrxs_bp2_refresh refresh
def refresh
   xrxs_bp2_refresh
   @item_max = $game_party.actors.size
    for i in 0...$game_party.actors.size
     actor = $game_party.actors[i]
     case i
       when 0
        x = 310
        y = 390
       when 1
        x = 390
        y = 340
       when 2
        x = 480
        y = 300
       when 3
        x = 550
        y = 270
      end
     draw_actor_hp_meter(actor, x, y, 50)
     draw_actor_sp_meter(actor, x, y + 8, 50)
   end
end
end
#==============================================================================
# ■ Window_Base
#==============================================================================
class Window_Base < Window
#--------------------------------------------------------------------------
# ● HP描画
#--------------------------------------------------------------------------
def draw_actor_hp_meter(actor, x, y, width = 156, type = 0)
   if type == 1 and actor.hp == 0
     return
   end
   self.contents.font.color = system_color
   self.contents.fill_rect(x-1, y+27, width+2,6, Color.new(0, 0, 0, 25))
   w = width * actor.hp / actor.maxhp
   self.contents.fill_rect(x, y+28, w,1, Color.new(255, 96, 96, 255))
   self.contents.fill_rect(x, y+29, w,1, Color.new(255, 0, 0, 255))
   self.contents.fill_rect(x, y+30, w,1, Color.new(128, 0, 0, 255))
   self.contents.fill_rect(x, y+31, w,1, Color.new(0, 0, 0, 255))
   
   end
#--------------------------------------------------------------------------
# ● SP描画
#--------------------------------------------------------------------------
def draw_actor_sp_meter(actor, x, y, width = 156, type = 0)
   if type == 1 and actor.hp == 0
     return
   end
   self.contents.font.color = system_color
   self.contents.fill_rect(x-1, y+27, width+2,6, Color.new(0, 0, 0, 255))
   w = width * actor.sp / actor.maxsp
   self.contents.fill_rect(x, y+28, w,1, Color.new(128, 255, 255, 255))
   self.contents.fill_rect(x, y+29, w,1, Color.new(0, 255, 255, 255))
   self.contents.fill_rect(x, y+30, w,1, Color.new(0, 192, 192, 255))
   self.contents.fill_rect(x, y+31, w,1, Color.new(0, 128, 128, 255))
end
end
万般皆散
回复

使用道具 举报

12

主题

1

听众

148

积分

略有小成

会员等级: 2

该用户从未签到

精华
0
积分
148
历练
0
声望
1
人气
6
单身中……
帮我摆脱单身吧
3
发表于 2011-6-3 21:42:16 |只看该作者
发现原因。。。。。。修改完脚本没保存。。。。。。
万般皆散
回复

使用道具 举报

143

主题

5

听众

1348

积分

仗剑行侠

会员等级: 5

  • TA的每日心情
    擦汗
    2013-12-27 20:48
  • 签到天数: 60 天

    [LV.6]常住仙友II

    精华
    0
    积分
    1348
    历练
    0
    声望
    2
    人气
    178
    单身中……
    帮我摆脱单身吧
    4
    发表于 2011-6-3 21:52:39 |只看该作者
    表示楼上连贴了。。。
    新书《追梦进行曲》妄支持~http://book.hjsm.tom.com/116592/index.html
    回复

    使用道具 举报

    488

    主题

    2

    听众

    5458

    积分

    名扬四海

    会员等级: 7

  • TA的每日心情
    擦汗
    2024-2-23 10:28
  • 签到天数: 1851 天

    [LV.Master]伴坛终老

    精华
    0
    积分
    5458
    历练
    0
    声望
    246
    人气
    62

    黑色羽翼 神仙眷侣 转帖之王

    最爱菱纱
    幸福:65℃
    5
    发表于 2011-6-3 22:15:00 |只看该作者
    回复 4# 慕容晓佳

    因为没人理他
        !!
    回复

    使用道具 举报

    827

    主题

    7

    听众

    1万

    积分

    御剑江湖

    秘密

    会员等级: 8

  • TA的每日心情
    无聊
    10 小时前
  • 签到天数: 2890 天

    [LV.Master]伴坛终老

    精华
    0
    积分
    13017
    历练
    0
    声望
    411
    人气
    373

    转帖之王 匠心独运

    单身中……
    帮我摆脱单身吧
    6
    发表于 2011-6-4 13:58:02 |只看该作者
    无视晓佳吧,他凑热闹的。

    没保存...我无语
    回复

    使用道具 举报

    1008

    主题

    5

    听众

    2万

    积分

    返璞归真

    不器用な星の瞬き

    会员等级: 10

  • TA的每日心情
    擦汗
    昨天 22:11
  • 签到天数: 1364 天

    [LV.10]以坛为家III

    精华
    2
    积分
    23737
    历练
    3
    声望
    133
    人气
    2538

    转帖之王 金融巨子 黑色羽翼

    单身中……
    帮我摆脱单身吧
    7
    发表于 2011-6-4 16:50:03 |只看该作者
    保存是基本操作
    夜空の星に 捧げた願いの
    欠片積めて 爆誕する奇跡
    回复

    使用道具 举报

    183

    主题

    5

    听众

    5188

    积分

    名扬四海

    云中散仙

    会员等级: 7

  • TA的每日心情
    擦汗
    2016-2-1 12:27
  • 签到天数: 342 天

    [LV.8]以坛为家I

    精华
    1
    积分
    5188
    历练
    2
    声望
    81
    人气
    45

    家族族长 黑色羽翼

    单身中……
    帮我摆脱单身吧
    8
    发表于 2011-6-5 20:43:33 |只看该作者
    脚本要保存才能生效的……
    http://img13.poco.cn/mypoco/myphoto/20120825/09/5775223320120825091922022.jpg
    专一不是一辈子只喜欢一个人,是喜欢一个人的时候一心一意。
    回复

    使用道具 举报

    您需要登录后才可以回帖 登录 | 加入我们

    手机版|Archiver|仙剑之十里坡 ( 苏ICP备11022766号 )  

    GMT+8, 2024-5-3 18:57 , Processed in 0.696727 second(s), 63 queries .

    Powered by Discuz! X2.5

    © 2001-2012 Comsenz Inc.

    回顶部