设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索
查看: 6070|回复: 10
打印 上一主题 下一主题

[已经过期] 空之轨迹整合系统加上换装

[复制链接]

Lv1.梦旅人

梦石
0
星屑
50
在线时间
28 小时
注册时间
2009-11-12
帖子
7
跳转到指定楼层
1
 楼主| 发表于 2013-1-24 00:19:01 | 只看该作者 |只看大图 回帖奖励 |倒序浏览 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有帐号?注册会员

x
本帖最后由 lnbayfz 于 2013-2-8 03:41 编辑

群里有个空之轨迹的整合系统。我想在那个系统的基础上,加上换装系统,并把战斗系统改回横版战斗。其中,换装我希望能每更换一下装备就能更换半身像图和战斗图。另外如果大侠们顺手去掉空轨整合系统中多出来的移动范围和攻击范围属性就更好了,再如果能顺手加上战斗进度条就完美了,我可以根据情况给予30-50VIP。哪位大侠有空顺手帮帮我!多谢啦!!

我看到消息提醒里有rvqsw对这个问题的答复,但是帖子里却没有是怎么回事?

补充说明:空之轨迹系统就是主站整合系统比赛里的那个空之轨迹菜单系统。我最想实现的就是菜单界面的换装刷新。不是那个系统的菜单界面换装刷新也行。

点评

你好久没处理这陈旧的帖子了  发表于 2013-7-28 22:45

Lv1.梦旅人

梦石
0
星屑
50
在线时间
28 小时
注册时间
2009-11-12
帖子
7
2
 楼主| 发表于 2013-2-5 16:05:44 | 只看该作者
为什么都没有人回答,我可以收回悬赏的VIP么

点评

LZ是不是有点太迷糊了?至少你得告诉别人你说的是哪个空之轨迹整合系统吧?  发表于 2013-2-5 16:51
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
46
在线时间
1502 小时
注册时间
2010-8-27
帖子
392
3
发表于 2013-3-23 13:03:33 | 只看该作者
把脚本发上来,否则别人可懒得自己去找你说的那几个脚本
回复 支持 反对

使用道具 举报

Lv1.梦旅人

秋寒

梦石
0
星屑
63
在线时间
801 小时
注册时间
2013-1-17
帖子
1992
4
发表于 2013-4-28 18:30:55 | 只看该作者
换装可以用事件啊——设置角色移动路线——更改角色图形
半身像依然可以用事件
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
62 小时
注册时间
2013-3-14
帖子
53
5
发表于 2013-4-30 20:37:48 | 只看该作者
@lnbayfz
换着不必要脚本,只需要事件
上楼就是,你可以制作上半身或者下半身,来代表穿衣服,或者换装。
横版战斗脚本:
RUBY 代码复制
  1. #==============================================================================
  2. # * Animated_Sprite                                Scripted by: SiR_VaIlHoR
  3. #                                                  Edited by: 柳柳
  4.  
  5. #------------------------------------------------------------------------------
  6. #  A class for animated sprites.
  7. #==============================================================================
  8.  
  9. #66RPG,超级横版战斗脚本简要说明:
  10.  
  11.  
  12. #默认情况下,把一张战斗图截成4列,>8行,如果感觉4列4帧的动画还不能满足要求,看
  13.  
  14. #def pose(number,frame = 4),更改=4,以及相关部分。
  15.  
  16.  
  17.  
  18. #战斗图从上到下:前进图,等待图,防御图,挨打图,普通攻击图(默认的武器),施展魔法,
  19.  
  20. #倒地不行了,胜利姿势,自定义武器1,自定义武器2……
  21.  
  22.  
  23. #这个脚本的模型是老外编写的,其中参考了XMXS的一个方法,我添加了一些功能,去掉素材限制。
  24.  
  25.  
  26. #不同职业拥有的图片数可以不一样,参考工程和录像教学
  27.  
  28.  
  29. #==============================================================================
  30.  
  31. # □ RPG::Class
  32.  
  33. #==============================================================================
  34.  
  35. module RPG
  36.  
  37.   class Class
  38.  
  39.     def name
  40.  
  41.       name = @name.split(/,/)[0]
  42.  
  43.       return name != nil ? name : ''
  44.  
  45.     end
  46.  
  47.     def name2
  48.  
  49.       name = @name.split(/,/)[1]
  50.  
  51.       return name != nil ? name : ''
  52.  
  53.     end
  54.   end
  55.  
  56.   class Weapon
  57.  
  58.     def name
  59.  
  60.       name = @name.split(/,/)[0]
  61.  
  62.       return name != nil ? name : ''
  63.  
  64.     end
  65.  
  66.     def name2
  67.  
  68.       name = @name.split(/,/)[1]
  69.  
  70.       return name != nil ? name : ''
  71.  
  72.     end   
  73.   end  
  74.  
  75. end
  76.  
  77.  
  78. class Game_Actor
  79.  
  80.   #--------------------------------------------------------------------------
  81.  
  82.   # ● 更改名称
  83.  
  84.   #     name : 新的名称
  85.  
  86.   #--------------------------------------------------------------------------
  87.  
  88.   def picturephase
  89.  
  90.     name = $data_classes[class_id].name2
  91.  
  92.     return name != nil ? name : "66RPG"
  93.  
  94.   end
  95.  
  96. end
  97.  
  98.  
  99. class Game_Enemy
  100.  
  101.   #--------------------------------------------------------------------------
  102.  
  103.   # ● 获取名称
  104.  
  105.   #--------------------------------------------------------------------------
  106.  
  107.   def name
  108.  
  109.     name = $data_enemies[@enemy_id].name.split(/,/)[0]
  110.  
  111.     return name != nil ? name : ''
  112.  
  113.   end
  114.  
  115.   def picturephase
  116.  
  117.     name = $data_enemies[@enemy_id].name.split(/,/)[1]
  118.  
  119.     return name != nil ? name : "66RPG"
  120.  
  121.   end  
  122.  
  123. end
  124.  
  125.  
  126. class Animated_Sprite < RPG::Sprite
  127. #--------------------------------------------------------------------------
  128. # - Accessible instance variables.
  129. #--------------------------------------------------------------------------
  130. attr_accessor :frames        # Number of animation frames
  131. attr_accessor :delay         # Delay time between frames (speed)
  132. attr_accessor :frame_width   # Width of each frame
  133. attr_accessor :frame_height  # Height of each frame
  134. attr_accessor :offset_x      # X coordinate of the 1st frame
  135. attr_accessor :offset_y      # Y coordinate of all frames
  136. attr_accessor :current_frame # Current animation frame
  137. attr_accessor :moving        # Is the sprite moving?
  138.  
  139. #--------------------------------------------------------------------------
  140. # - Initialize an animated sprite
  141. #   viewport : Sprite viewport
  142. #--------------------------------------------------------------------------
  143. def initialize(viewport = nil)
  144.    super(viewport)
  145.    @frame_width, @frame_height = 0, 0
  146.    change    # A basic change to set initial variables
  147.    @old = Graphics.frame_count  # For the delay method
  148.    @goingup = true    # Increasing animation? (if @rm2k_mode is true)
  149.    @once = false      # Is the animation only played once?
  150.    @animated = true   # Used to stop animation when @once is true
  151. end
  152.  
  153. #--------------------------------------------------------------------------
  154. # Comment by RPG
  155. #   - Change the source rect (change the animation)
  156. #   frames : Number of animation frames
  157. #   delay : Frame delay, controls animation speed
  158. #   offx : X coordinate of the 1st frame
  159. #   offy : Y coordinate of all frames
  160. #   startf : Starting frame for animation
  161. #   once : Is the animation only played once?
  162. #   rm2k_mode : Animation pattern: 1-2-3-2 if true, 1-2-3-1 if false
  163. #
  164. # Comment by cybersam
  165. #
  166. # the rm2k_mode isnt pressent anymore...
  167. # if you want that feature then use rm2k or use RPG's scrîpt...
  168. #--------------------------------------------------------------------------
  169. def change(frames = 0, delay = 0, offx = 0, offy = 0,
  170.             startf = 0, once = false)
  171.    @frames = frames
  172.    @delay = delay
  173.    @offset_x, @offset_y = offx, offy
  174.    @current_frame = startf
  175.    @once = once
  176.    x = @current_frame * @frame_width + @offset_x
  177.    self.src_rect = Rect.new(x, @offset_y, @frame_width, @frame_height)
  178.    @goingup = true
  179.    @animated = true
  180. end
  181.  
  182.  
  183. #--------------------------------------------------------------------------
  184. # - Update animation and movement
  185. #--------------------------------------------------------------------------
  186. def update
  187.    super
  188.    if self.bitmap != nil and delay(@delay) and @animated
  189.      x = @current_frame * @frame_width + @offset_x
  190.      self.src_rect = Rect.new(x, @offset_y, @frame_width, @frame_height)
  191.        @current_frame = (@current_frame + 1) unless @frames == 0
  192.        @animated = false if @current_frame == @frames and @once
  193.        @current_frame %= @frames
  194.    end
  195. end
  196.  
  197.  
  198. #--------------------------------------------------------------------------
  199. # - Move the sprite
  200. #   x : X coordinate of the destination point
  201. #   y : Y coordinate of the destination point
  202. #   speed : Speed of movement (0 = delayed, 1+ = faster)
  203. #   delay : Movement delay if speed is at 0
  204. #--------------------------------------------------------------------------
  205. def move(x, y, speed = 1, delay = 0)
  206.    @destx = x
  207.    @desty = y
  208.    @move_speed = speed
  209.    @move_delay = delay
  210.    @move_old = Graphics.frame_count
  211.    @moving = true
  212. end
  213.  
  214.  
  215. #--------------------------------------------------------------------------
  216. # - Move sprite to destx and desty
  217. #--------------------------------------------------------------------------
  218. def update_move
  219.    return unless @moving
  220.    movinc = @move_speed == 0 ? 1 : @move_speed
  221.    if Graphics.frame_count - @move_old > @move_delay or @move_speed != 0
  222.      self.x += movinc if self.x < @destx
  223.      self.x -= movinc if self.x > @destx
  224.      self.y += movinc if self.y < @desty
  225.      self.y -= movinc if self.y > @desty
  226.      @move_old = Graphics.frame_count
  227.    end
  228.    if @move_speed > 1  # Check if sprite can't reach that point
  229.      self.x = @destx if (@destx - self.x).abs % @move_speed != 0 and
  230.                         (@destx - self.x).abs <= @move_speed
  231.      self.y = @desty if (@desty - self.y).abs % @move_speed != 0 and
  232.                         (@desty - self.y).abs <= @move_speed
  233.    end
  234.    if self.x == @destx and self.y == @desty
  235.      @moving = false
  236.    end
  237. end
  238.  
  239.  
  240. #--------------------------------------------------------------------------
  241. # - Pause animation, but still updates movement
  242. #   frames : Number of frames
  243. #--------------------------------------------------------------------------
  244. def delay(frames)
  245.    update_move
  246.    if (Graphics.frame_count - @old >= frames)
  247.      @old = Graphics.frame_count
  248.      return true
  249.    end
  250.    return false
  251. end
  252. end
  253.  
  254. #=============================================================================
  255. #
  256. # here we go...
  257. # this makes the scrîpt very easy to implement
  258. # just add a new scrîpt above the "Main" scrîpt
  259. # and insert this whole thing in there
  260. #
  261. # as you can see the sprite changing code is from the japanese scrîpt
  262. # so the credits for the sprite changin goes to them....
  263. # i edit it a little so it can show more sprites and sprite animations
  264. # and added some other stuff... the next things are player movement...
  265. #
  266. #
  267. #
  268. # i got the battler changing scrîpt in this scrîpt...
  269. # the credits for this goes to the guy who made this...
  270. #
  271. # ▼▲▼ XRXS11. 戦闘・バトラーモーション ver.0 ▼▲▼
  272. #
  273. # since this isnt used anymore... it isnt need for credit anymore...
  274. # but i'll let it here since it helped me a lot...
  275. #
  276. #
  277. # as for the ideas... missy provided me with really good ideas
  278. # that helped me alot when i didnt find a way to some of these features...
  279. #
  280. # here one more Credit to place...
  281. # its RPG's scrîpt...
  282. # not the whole thing here...
  283. # but some snipplet you'll know witch one when read the comments
  284. #
  285. #
  286. # if you want some more explaines about this scrîpt...
  287. # the most stuff are commented... but if you still have questions or
  288. # sugestions then you can contact me
  289. #
  290. # how or where you can contact me...
  291. # at the [url]http://www.rmxp.net[/url] forum via pm, email: [email][email protected][/email]
  292. # or via AIM: cych4n or ICQ: 73130840
  293. #
  294. # remember this is still in testing phase...
  295. # and i'm trying to work on some other additions... like character movements...
  296. # but that wont be added now... couse i need to figure it out first...
  297. #
  298. #
  299. #
  300. # oh hehe.... before i forget...
  301. # sorry for the bad english... ^-^''''
  302. #
  303. #
  304. #==============================================================================
  305. #
  306. # here i'm going to tell you what names you need to give for your chara
  307. # battle sprites....
  308. #
  309. # ok... here... since i'm using RPG's movement scrîpt...
  310. # there are a lot of changes...
  311. #
  312. # when you look at the scrîpt you'll find line with "pose(n)" or "enemy_pose(n)"
  313. # since i want my sprites have different sprites... i added one more option
  314. # to these...
  315. # so now if you add a number after the n (the n stands for witch sprite is used)
  316. # fo example 8... ("pose(4, 8)") this will tell the scrîpt that the 4th animation
  317. # have 8 frames...
  318. # pose is used for the player... and enemy_pose for the enemy...
  319. # there is nothing more to this...
  320. # i used my old sprite numbers... (this time in only one sprite...)
  321. #
  322. # explains about the animation sprites... (the digits)
  323. #
  324. #
  325. # 0 = move (during battle)
  326. # 1 = standby
  327. # 2 = defend
  328. # 3 = hit (being attacked)
  329. # 4 = attack
  330. # 5 = skill use
  331. # 6 = dead
  332. # 7 = winning pose... this idea is from RPG....
  333. #
  334. #
  335. # of course this is just the begining of the code...
  336. # so more animations can be implemented...
  337. # but for now this should be enough...
  338. #
  339. # alot has changed here... and now it looks like it is done...
  340. # of course the fine edit needs to be done so it looks and works great with your
  341. # game too...
  342. #
  343. #
  344. #
  345. # 1st character movement...                             done
  346. # 2nd character movement during attack...               done
  347. # 3rd character apears at the enemy while attacking...  done
  348. #
  349. # 4th enemies movement...                               done
  350. # 5th enemy movement during attack...                   done
  351. # 6th enemy apears at the enemy while attacking...      done
  352. #
  353. # 7th each weapon has its own animation...              done
  354. # 8th each skill has its own animation...               done
  355. #
  356. #
  357. #
  358. # for the ones interisted... my nex project is an Movie player
  359. # (that actualy plays avi, mpgs and such...
  360. # but dont think this will be done soon... ^-^''
  361. #
  362. # but i'll may be try something else before i begin to code that one...
  363. #==============================================================================
  364.  
  365.  
  366.  
  367. class Game_Actor < Game_Battler
  368.  
  369.  
  370. # you dont have to change your game actor to let the characters schows
  371. # from the side...
  372. # this will do it for you... ^-^
  373.  
  374. def screen_x
  375.    if self.index != nil
  376.      return self.index * 30 + 430
  377.    else
  378.      return 0
  379.    end
  380. end
  381.  
  382. def screen_y
  383.    return self.index * 40 + 150
  384. end
  385.  
  386.  
  387. def screen_z
  388.    if self.index != nil
  389.      return self.index
  390.    else
  391.      return 0
  392.    end
  393. end
  394. end
  395.  
  396.  
  397. # RPG's snipplet...
  398. class Spriteset_Battle
  399. attr_accessor :actor_sprites
  400. attr_accessor :enemy_sprites
  401.  
  402.  
  403.  
  404.  
  405. alias original_initialize initialize
  406. def initialize
  407.    #@start_party_number = $game_party.actors.size
  408.    # ビューポートを作成
  409.    @viewport0 = Viewport.new(0, 0, 640, 480)
  410.    @viewport1 = Viewport.new(0, 0, 640, 320)
  411.    @viewport2 = Viewport.new(0, 0, 640, 480)
  412.    @viewport3 = Viewport.new(0, 0, 640, 480)
  413.    @viewport4 = Viewport.new(0, 0, 640, 480)
  414.    @viewport1.z = 50
  415.    @viewport2.z = 50
  416.    @viewport3.z = 200
  417.    @viewport4.z = 5000
  418.  
  419.    @battleback_sprite = Sprite.new(@viewport0)
  420.  
  421.    @enemy_sprites = []
  422.    for enemy in $game_troop.enemies #.reverse
  423.      @enemy_sprites.push(Sprite_Battler.new(@viewport1, enemy))
  424.    end
  425.  
  426.    @actor_sprites = []
  427.    @actor_sprites.push(Sprite_Battler.new(@viewport2,$game_party.actors[0]))
  428.    @actor_sprites.push(Sprite_Battler.new(@viewport2,$game_party.actors[1]))
  429.    @actor_sprites.push(Sprite_Battler.new(@viewport2,$game_party.actors[2]))
  430.    @actor_sprites.push(Sprite_Battler.new(@viewport2,$game_party.actors[3]))
  431.  
  432.    @weather = RPG::Weather.new(@viewport1)
  433.    @picture_sprites = []
  434.    for i in 51..100
  435.      @picture_sprites.push(Sprite_Picture.new(@viewport3,
  436.        $game_screen.pictures[i]))
  437.    end
  438.    @timer_sprite = Sprite_Timer.new
  439.    update
  440. end
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447. alias original_update update
  448. def update
  449.    @viewport1.z = 50 and @viewport2.z = 51 if $actor_on_top == true
  450.    @viewport1.z = 51 and @viewport2.z = 50 if $actor_on_top == false
  451.     # 刷新角色的活动块 (对应角色的替换)
  452.  
  453.     @actor_sprites[0].battler = $game_party.actors[0]
  454.  
  455.     @actor_sprites[1].battler = $game_party.actors[1]
  456.  
  457.     @actor_sprites[2].battler = $game_party.actors[2]
  458.  
  459.     @actor_sprites[3].battler = $game_party.actors[3]
  460.  
  461.     # 战斗背景的文件名与现在情况有差异的情况下
  462.  
  463.     if @battleback_name != $game_temp.battleback_name
  464.  
  465.       @battleback_name = $game_temp.battleback_name
  466.  
  467.       if @battleback_sprite.bitmap != nil
  468.  
  469.         @battleback_sprite.bitmap.dispose
  470.  
  471.       end
  472.  
  473.       @battleback_sprite.bitmap = RPG::Cache.battleback(@battleback_name)
  474.  
  475.       @battleback_sprite.src_rect.set(0, 0, 640, 480)
  476.  
  477.     end
  478.  
  479.     # 刷新战斗者的活动块
  480.  
  481.     for sprite in @enemy_sprites + @actor_sprites
  482.  
  483.       sprite.update
  484.  
  485.     end
  486.  
  487.     # 刷新天气图形
  488.  
  489.     @weather.type = $game_screen.weather_type
  490.  
  491.     @weather.max = $game_screen.weather_max
  492.  
  493.     @weather.update
  494.  
  495.     # 刷新图片活动块
  496.  
  497.     for sprite in @picture_sprites
  498.  
  499.       sprite.update
  500.  
  501.     end
  502.  
  503.     # 刷新计时器活动块
  504.  
  505.     @timer_sprite.update
  506.  
  507.     # 设置画面的色调与震动位置
  508.  
  509.     @viewport1.tone = $game_screen.tone
  510.  
  511.     @viewport1.ox = $game_screen.shake
  512.  
  513.     # 设置画面的闪烁色
  514.  
  515.     @viewport4.color = $game_screen.flash_color
  516.  
  517.     # 刷新显示端口
  518.  
  519.     @viewport1.update
  520.  
  521.     @viewport2.update
  522.  
  523.     @viewport4.update
  524.  
  525. end
  526. end
  527. # end
  528.  
  529. #==============================================================================
  530. # Sprite Battler for the Costum Battle System
  531. #==============================================================================
  532. # here we are making some animations and stuff...
  533. # i know its not the best way...
  534. # but this is the first working way that i found....
  535. # this needs propper understanding how the animation works...
  536. # if you want to change some stuff...
  537. # in this i'll not explain much couse its realy easy if you know what you do
  538. # otherwise it will take you time to understand it, but i think the one who
  539. # is trying to edit this will know what he/she do... ^-^
  540. #
  541. #
  542. #
  543. # here i'll completely replace the "Sprite_Battler" class...
  544. # so if you've changed something in there you need to change it here as well
  545. # (i think... i didnt tested it... so its up to you)
  546. # i'll mark the stuff i added just with --> #
  547. # something that need to be explained have a comment...
  548. # but its not all commented...
  549. # so if you dont know what it means or you just want to know why it is there and
  550. # what it does then you need to contact me or anyone who understand this... ^-^
  551. # how you can contact me see above... at the top of this scrîpt...
  552.  
  553.  
  554. class Sprite_Battler < Animated_Sprite
  555.  
  556. attr_accessor :battler
  557. attr_reader   :index
  558. attr_accessor :target_index
  559. attr_accessor :frame_width
  560.  
  561.  
  562.  
  563. def initialize(viewport, battler = nil)
  564.    super(viewport)
  565.    [url=home.php?mod=space&uid=133701]@battler[/url] = battler
  566.    @pattern_b = 0 #
  567.    @counter_b = 0 #
  568.    @index = 0     #
  569.    if @battler != nil
  570.  
  571.      tempbitmap = RPG::Cache.battler(@battler.battler_name, @battler.battler_hue)
  572.  
  573.      @frame_width = tempbitmap.width/4
  574.  
  575.      picturephase = @battler.picturephase
  576.  
  577.      if picturephase == "66RPG"
  578.  
  579.        @frame_height = tempbitmap.height/8
  580.  
  581.      else
  582.  
  583.        @frame_height = tempbitmap.height/8.to_i
  584.  
  585.      end     
  586.  
  587.    else
  588.  
  589.      @frame_width, @frame_height = 1,1
  590.  
  591.    end   
  592.  
  593.    # start sprite
  594.    @battler.is_a?(Game_Enemy) ? enemy_pose(1) : pose(1)
  595.    @battler_visible = false
  596.    if $target_index == nil
  597.      $target_index = 0
  598.    end
  599. end
  600.  
  601.  
  602. def index=(index) #
  603.    @index = index  #
  604.    update          #
  605. end               #
  606.  
  607.  
  608. def dispose
  609.    if self.bitmap != nil
  610.      self.bitmap.dispose
  611.    end
  612.    super
  613. end
  614.  
  615.  
  616. def enemy                                             #
  617.    $target_index += $game_troop.enemies.size
  618.    $target_index %= $game_troop.enemies.size
  619.    return $game_troop.enemies[$target_index]           #
  620. end                                                   #
  621.  
  622.  
  623. def actor                                             #
  624.    $target_index += $game_party.actors.size
  625.    $target_index %= $game_party.actors.size
  626.    return $game_party.actors[$target_index]            #
  627. end            
  628.  
  629.  
  630. #==============================================================================
  631. # here is a snipplet from RPG's scrîpt...
  632. # i changed only to lines from this...
  633. #
  634. # here you can add more sprite poses... if you have more... ^-^
  635. #==============================================================================
  636. def pose(number, frames = 4)
  637.     case number
  638.     when 0  # run
  639.     change(frames, 5, 0, 0, 0)
  640.     when 1  # standby
  641.     change(frames, 5, 0, @frame_height)
  642.     when 2 # defend
  643.     change(frames, 5, 0, @frame_height * 2)
  644.     when 3 # Hurt, loops
  645.     change(frames, 5, 0, @frame_height * 3)
  646.     when 4 # attack no loop
  647.     change(frames, 5, 0, @frame_height * 4, 0, true)
  648.     when 5 # skill
  649.     change(frames, 5, 0, @frame_height * 5)
  650.     when 6 # death
  651.     change(frames, 5, 0, @frame_height * 6)
  652.     when 7 # winning pose
  653.     change(frames, 5, 0, @frame_height * 7)
  654.     when 8 # no sprite
  655.     change(frames, 5, 0, @frame_height * 8)
  656.     when 9 # no sprite
  657.     change(frames, 5, 0, @frame_height * 9)
  658.  
  659.     when 10 # no sprite
  660.     change(frames, 5, 0, @frame_height * 10)
  661.     when 11 # no sprite
  662.     change(frames, 5, 0, @frame_height * 11)
  663.  
  664.     when 12 # no sprite
  665.     change(frames, 5, 0, @frame_height * 12)
  666.     when 13 # no sprite
  667.     change(frames, 5, 0, @frame_height * 13)
  668.  
  669.     when 14 # no sprite
  670.     change(frames, 5, 0, @frame_height * 14)
  671.     when 15 # no sprite
  672.     change(frames, 5, 0, @frame_height * 15)
  673.  
  674.     when 16 # no sprite
  675.     change(frames, 5, 0, @frame_height * 16)
  676.  
  677.     when 17 # no sprite
  678.     change(frames, 5, 0, @frame_height * 17)
  679.  
  680.     when 18 # no sprite
  681.     change(frames, 5, 0, @frame_height * 18)
  682.  
  683.     when 19 # no sprite
  684.     change(frames, 5, 0, @frame_height * 19)
  685.  
  686.     when 20 # no sprite
  687.     change(frames, 5, 0, @frame_height * 20)
  688.  
  689.     # ...etc.
  690.    else
  691.      change(frames, 5, 0, @frame_height * number, 0)
  692.    end
  693. end
  694.  
  695.  
  696. #--------------------------------------------------------------------------
  697. # - Change the battle pose for an enemy
  698. #   number : pose' number
  699. #--------------------------------------------------------------------------
  700. def enemy_pose(number ,enemy_frames = 4)
  701.    case number
  702.    when 0  # run
  703.      change(enemy_frames, 5, 0, 0, 0)
  704.    when 1  # standby
  705.      change(enemy_frames, 5, 0, @frame_height)
  706.    when 2 # defend
  707.      change(enemy_frames, 5, 0, @frame_height * 2)
  708.    when 3 # Hurt, loops
  709.      change(enemy_frames, 5, 0, @frame_height * 3)
  710.    when 4 # attack
  711.      change(enemy_frames, 5, 0, @frame_height * 4, 0, true)
  712.    when 5 # skill
  713.      change(enemy_frames, 5, 0, @frame_height * 5)
  714.    when 6 # death
  715.      change(enemy_frames, 5, 0, @frame_height * 6)
  716.    when 7 # no sprite
  717.      change(enemy_frames, 5, 0, @frame_height * 7)
  718.      # ...etc.
  719.    else
  720.      change(enemy_frames, 5, 0, @frame_height * number, 0)
  721.    end
  722. end
  723. #==============================================================================
  724. # sniplet end...
  725. #==============================================================================  
  726.  
  727.  
  728.  
  729.  
  730.  
  731. def update
  732.    super
  733.  
  734.    if @battler == nil                                                      
  735.  
  736.      self.bitmap = nil                                                      
  737.  
  738.      loop_animation(nil)                                                   
  739.      return                                                               
  740.    end                                                                     
  741.    if @battler.battler_name != @battler_name or
  742.       @battler.battler_hue != @battler_hue
  743.  
  744.      @battler_name = @battler.battler_name
  745.      @battler_hue = @battler.battler_hue
  746.      self.bitmap = RPG::Cache.battler(@battler_name, @battler_hue)
  747.      @width = bitmap.width
  748.      [url=home.php?mod=space&uid=291977]@height[/url] = bitmap.height
  749.      self.ox = @frame_width / 2
  750.      self.oy = @frame_height
  751.  
  752.      if @battler.dead? or @battler.hidden
  753.        self.opacity = 0
  754.      end
  755.      self.x =  @battler.screen_x
  756.      self.y =  @battler.screen_y
  757.      self.z = @battler.screen_z
  758.    end
  759.  
  760.    if @battler.damage == nil and
  761.       @battler.state_animation_id != @state_animation_id
  762.      @state_animation_id = @battler.state_animation_id
  763.      loop_animation($data_animations[@state_animation_id])
  764.    end
  765.  
  766.    if @battler.is_a?(Game_Actor) and @battler_visible
  767.      if $game_temp.battle_main_phase
  768.        self.opacity += 3 if self.opacity < 255
  769.      else
  770.        self.opacity -= 3 if self.opacity > 207
  771.      end
  772.    end
  773.  
  774.    if @battler.blink
  775.      blink_on
  776.    else
  777.      blink_off
  778.    end
  779.  
  780.    unless @battler_visible
  781.      if not @battler.hidden and not @battler.dead? and
  782.         (@battler.damage == nil or @battler.damage_pop)
  783.        appear
  784.        @battler_visible = true
  785.      end
  786.      if not @battler.hidden and
  787.         (@battler.damage == nil or @battler.damage_pop) and
  788.         @battler.is_a?(Game_Actor)
  789.        appear
  790.        @battler_visible = true
  791.      end
  792.    end
  793.    if @battler_visible
  794.      if @battler.hidden
  795.        $game_system.se_play($data_system.escape_se)
  796.        escape
  797.        @battler_visible = false
  798.      end
  799.      if @battler.white_flash
  800.        whiten
  801.        @battler.white_flash = false
  802.      end
  803.      if @battler.animation_id != 0
  804.        animation = $data_animations[@battler.animation_id]
  805.        animation(animation, @battler.animation_hit)
  806.        @battler.animation_id = 0
  807.      end
  808.      if @battler.damage_pop
  809.        damage(@battler.damage, @battler.critical)
  810.        @battler.damage = nil
  811.        @battler.critical = false
  812.        @battler.damage_pop = false
  813.      end
  814.      if @battler.damage == nil and @battler.dead?
  815.        if @battler.is_a?(Game_Enemy)
  816.          $game_system.se_play($data_system.enemy_collapse_se)
  817.          collapse
  818.          @battler_visible = false
  819.        else
  820.          $game_system.se_play($data_system.actor_collapse_se) unless @dead
  821.          @dead = true
  822.          pose(6)
  823.        end
  824.      else
  825.        @dead = false
  826.      end
  827.    end                                                                #
  828. end
  829. end
  830.  
  831.  
  832. #==============================================================================
  833. # Scene_Battle Costum  Battle System
  834. #==============================================================================
  835.  
  836. class Scene_Battle
  837.  
  838.  
  839.  
  840.  
  841. def update_phase4
  842.    case @phase4_step
  843.    when 1
  844.      update_phase4_step1
  845.    when 2
  846.      update_phase4_step2
  847.    when 3
  848.      update_phase4_step3
  849.    when 4
  850.      update_phase4_step4
  851.    when 5
  852.      update_phase4_step5
  853.    when 6
  854.      update_phase4_step6
  855.    when 7
  856.      update_phase4_step7
  857.    when 8
  858.     update_phase4_step8   
  859.    end
  860. end
  861.  
  862.  
  863.  
  864.  
  865. def make_basic_action_result
  866.  
  867.    if @active_battler.is_a?(Game_Actor)
  868.      $actor_on_top = true
  869.    elsif @active_battler.is_a?(Game_Enemy)
  870.      $actor_on_top = false
  871.    end
  872.  
  873.    if @active_battler.current_action.basic == 0
  874. #============================================================================
  875. # WEAPONS START...
  876. #============================================================================
  877. #
  878. #================================= Different Weapons with different animations
  879. #
  880. # this is quite simple as you can see...
  881. # if you want to add a weapon to the animation list then look at the scrîpt below...
  882. # and i hope you'll find out how this works...
  883. #
  884. #
  885. # if not...
  886. # here is the way...
  887. # first thing...
  888. # just copy and paste "elseif @active_battler_enemy.weapon_id == ID..."
  889. # just after the last @weapon_sprite....
  890. #
  891. # here the ID is you need to look in you game databse the number that stands before
  892. # your weapon name is the ID you need to input here...
  893. #
  894. # same thing goes for the monster party... ^-^
  895. # monster normaly dont need more sprites for weapons....
  896. #
  897. # if you want to use more... then replace the "@weapon_sprite_enemy = 4"
  898. # with these lines... (but you need to edit them)
  899. #
  900. #        if @active_battler.weapon_id == 1 # <--  weapon ID number
  901. #          @weapon_sprite_enemy = 4 # <-- battle animation
  902. #        elsif @active_battler.weapon_id == 5 # <-- weapon ID number
  903. #          @weapon_sprite_enemy = 2 # <-- battle animation
  904. #        elsif @active_battler.weapon_id == 9 # <-- weapon ID number
  905. #          @weapon_sprite_enemy = 0 # <-- battle animation
  906. #        elsif @active_battler.weapon_id == 13 # <-- weapon ID number
  907. #          @weapon_sprite_enemy = 6 # <-- battle animation
  908. #        else
  909. #          @weapon_sprite_enemy = 4
  910. #        end
  911. #
  912. #================================= END
  913.  
  914.      if @active_battler.is_a?(Game_Actor)
  915.        if $data_weapons[@active_battler.weapon_id] == nil
  916.  
  917.          @weapon_sprite = 4
  918.        else
  919.  
  920.          if $data_weapons[@active_battler.weapon_id].name2 == nil or
  921.  
  922.            $data_weapons[@active_battler.weapon_id].name2 == ""
  923.            @weapon_sprite = 4
  924.          else
  925.            @weapon_sprite = $data_weapons[@active_battler.weapon_id].name2.to_i
  926.  
  927.          end
  928.        end
  929.  
  930.  
  931.  
  932. # monster section is here... ^-^
  933.  
  934.      else # @active_battler.is_a?(Game_Enemy)
  935.          @weapon_sprite_enemy = 4
  936.      end
  937.  
  938.  
  939. #
  940. #=============================================================================
  941. # WEAPONS END....
  942. #=============================================================================
  943.  
  944.  
  945.  
  946.  
  947.      @animation1_id = @active_battler.animation1_id
  948.      @animation2_id = @active_battler.animation2_id
  949.      if @active_battler.is_a?(Game_Enemy)
  950.        if @active_battler.restriction == 3
  951.          target = $game_troop.random_target_enemy
  952.        elsif @active_battler.restriction == 2
  953.          target = $game_party.random_target_actor
  954.        else
  955.          index = @active_battler.current_action.target_index
  956.          target = $game_party.smooth_target_actor(index)
  957.        end
  958. #======== here is the setting for the movement & animation...
  959.          x = target.screen_x - RPG::Cache.battler(@active_battler.battler_name, @active_battler.battler_hue).width/6
  960.  
  961.          @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0)
  962.          @spriteset.enemy_sprites[@active_battler.index].move(x, target.screen_y, 10)
  963. #========= here if you look at the RPG's movement settings you'll see
  964. #========= that he takes the number 40 for the speed of the animation...
  965. #========= i thing thats too fast so i settet it down to 10 so looks smoother...
  966.      end
  967.      if @active_battler.is_a?(Game_Actor)
  968.        if @active_battler.restriction == 3
  969.          target = $game_party.random_target_actor
  970.        elsif @active_battler.restriction == 2
  971.          target = $game_troop.random_target_enemy
  972.        else
  973.          index = @active_battler.current_action.target_index
  974.          target = $game_troop.smooth_target_enemy(index)
  975.        end
  976. #======= the same thing for the player... ^-^
  977.        x = target.screen_x + RPG::Cache.battler(@active_battler.battler_name, @active_battler.battler_hue).width/8
  978.        @spriteset.actor_sprites[@active_battler.index].pose(0)
  979.        @spriteset.actor_sprites[@active_battler.index].move(x, target.screen_y, 10)
  980.      end
  981.      @target_battlers = [target]
  982.      for target in @target_battlers
  983.        target.attack_effect(@active_battler)
  984.      end
  985.      return
  986.    end
  987.    if @active_battler.current_action.basic == 1
  988.      if @active_battler.is_a?(Game_Actor)
  989.        @spriteset.actor_sprites[@active_battler.index].pose(2) #defence
  990.      else
  991.        @spriteset.enemy_sprites[@active_battler.index].enemy_pose(2) #defence
  992.      end
  993.      @help_window.set_text($data_system.words.guard, 1)
  994.      return
  995.    end
  996.    if @active_battler.is_a?(Game_Enemy) and
  997.       @active_battler.current_action.basic == 2
  998.      @help_window.set_text("逃走", 1)
  999.      @active_battler.escape
  1000.      return
  1001.    end
  1002.    if @active_battler.current_action.basic == 3
  1003.      $game_temp.forcing_battler = nil
  1004.      @phase4_step = 1
  1005.      return
  1006.    end
  1007.  
  1008.    if @active_battler.current_action.basic == 4
  1009.      if $game_temp.battle_can_escape == false
  1010.        $game_system.se_play($data_system.buzzer_se)
  1011.        return
  1012.      end
  1013.      $game_system.se_play($data_system.decision_se)
  1014.      update_phase2_escape
  1015.      return
  1016.    end
  1017. end
  1018. #--------------------------------------------------------------------------
  1019. # skill aktion...
  1020. #--------------------------------------------------------------------------
  1021. def make_skill_action_result
  1022.    @skill = $data_skills[@active_battler.current_action.skill_id]
  1023.    unless @active_battler.current_action.forcing
  1024.      unless @active_battler.skill_can_use?(@skill.id)
  1025.        $game_temp.forcing_battler = nil
  1026.        @phase4_step = 1
  1027.        return
  1028.      end
  1029.    end
  1030.    @active_battler.sp -= @skill.sp_cost
  1031.    @status_window.refresh
  1032.    @help_window.set_text(@skill.name, 1)
  1033.  
  1034. #=============================================================================
  1035. # SKILL SPRITES START
  1036. #=============================================================================
  1037. # this one is the same as the one for the weapons...
  1038. # for the one who have this for the first time
  1039. # look at the scrîpt i hope it is easy to understand...
  1040. #
  1041. # the other one that have the earlier versions of this scrîpt they dont need explenation
  1042. # ... i think....
  1043. # the think that changed is the line where the animation ID is given to the sprite...
  1044. # the number after the "pose" is the animation ID... it goes for every other animation as well..
  1045. # if you have an animation for a skill that have more frames...
  1046. # then just insert the number of frames after the first number...
  1047. # so it looks like this.... "pose(5, 8)" <-- 5 is the animation...
  1048. # 8 is the max frame (that means your animation have 8 frames...) ^-^
  1049.  
  1050.    if @active_battler.is_a?(Game_Actor)
  1051.      if @skill.name != "one of the skills" # <--skill doesn't exist => all the skills have the skill animation!
  1052.        @spriteset.actor_sprites[@active_battler.index].pose(5) # <-- sprite number
  1053.      end
  1054.    else
  1055.      if @skill.name != "one of the skills" # <-- first skill name
  1056.        @spriteset.enemy_sprites[@active_battler.index].enemy_pose(5) # <-- sprite number
  1057.      end
  1058.    end
  1059. #=============================================================================
  1060. # SKILL SPRITES END
  1061. #=============================================================================
  1062.  
  1063.    @animation1_id = @skill.animation1_id
  1064.    @animation2_id = @skill.animation2_id
  1065.    @common_event_id = @skill.common_event_id
  1066.    set_target_battlers(@skill.scope)
  1067.    for target in @target_battlers
  1068.      target.skill_effect(@active_battler, @skill)
  1069.    end
  1070. end
  1071. #--------------------------------------------------------------------------
  1072. # how here we make the item use aktions
  1073. #--------------------------------------------------------------------------
  1074. def make_item_action_result
  1075.    # sorry i didnt work on this...
  1076.    # couse i dont have a sprite that uses items....
  1077.    # so i just added the standby sprite here...
  1078.    # when i get more time for this i'll try what i can do for this one... ^-^
  1079.    # its the same as the ones above...
  1080.    if @active_battler.is_a?(Game_Actor)
  1081.      @spriteset.actor_sprites[@active_battler.index].pose(1)
  1082.    else
  1083.      @spriteset.enemy_sprites[@active_battler.index].enemy_pose(1)
  1084.    end
  1085.  
  1086.    @item = $data_items[@active_battler.current_action.item_id]
  1087.    unless $game_party.item_can_use?(@item.id)
  1088.      @phase4_step = 1
  1089.      return
  1090.    end
  1091.    if @item.consumable
  1092.      $game_party.lose_item(@item.id, 1)
  1093.    end
  1094.    @help_window.set_text(@item.name, 1)
  1095.    @animation1_id = @item.animation1_id
  1096.    @animation2_id = @item.animation2_id
  1097.    @common_event_id = @item.common_event_id
  1098.    index = @active_battler.current_action.target_index
  1099.    target = $game_party.smooth_target_actor(index)
  1100.    set_target_battlers(@item.scope)
  1101.    for target in @target_battlers
  1102.      target.item_effect(@item)
  1103.    end
  1104. end
  1105.  
  1106.  
  1107. #==============================================================================
  1108. # here again.... snipplet from RPG's scrîpt
  1109. #==============================================================================
  1110.  
  1111.  
  1112. # this one here is for the winning pose...
  1113. # if you happen to use my old costum level scrîpt then you need to add the
  1114. # marked line to you "def start_phase5" in  "Scene_Battle 2" and delete this one...
  1115. # the ->  =*****=
  1116. # marks the end where you need to delete...
  1117. # and -> {=====}
  1118. # marks the line you need to copy and paste in the other one...
  1119. # you need to add it at the same position...
  1120.  
  1121. def start_phase5
  1122.    @phase = 5
  1123.    $game_system.me_play($game_system.battle_end_me)
  1124.    $game_system.bgm_play($game_temp.map_bgm)
  1125.    exp = 0
  1126.    gold = 0
  1127.    treasures = []
  1128.    for enemy in $game_troop.enemies
  1129.      unless enemy.hidden
  1130.        exp += enemy.exp
  1131.        gold += enemy.gold
  1132.        if rand(100) < enemy.treasure_prob
  1133.          if enemy.item_id > 0
  1134.            treasures.push($data_items[enemy.item_id])
  1135.          end
  1136.          if enemy.weapon_id > 0
  1137.            treasures.push($data_weapons[enemy.weapon_id])
  1138.          end
  1139.          if enemy.armor_id > 0
  1140.            treasures.push($data_armors[enemy.armor_id])
  1141.          end
  1142.        end
  1143.      end
  1144.    end
  1145.    treasures = treasures[0..5]
  1146.    for i in 0...$game_party.actors.size
  1147.      actor = $game_party.actors[i]
  1148.      @spriteset.actor_sprites[i].pose(7) unless actor.dead? # {=====}
  1149.      if actor.cant_get_exp? == false
  1150.        last_level = actor.level
  1151.        actor.exp += exp
  1152.        if actor.level > last_level
  1153.          @status_window.level_up(i)
  1154.        end
  1155.      end
  1156.    end
  1157.    $game_party.gain_gold(gold)
  1158.    for item in treasures
  1159.      case item
  1160.      when RPG::Item
  1161.        $game_party.gain_item(item.id, 1)
  1162.      when RPG::Weapon
  1163.        $game_party.gain_weapon(item.id, 1)
  1164.      when RPG::Armor
  1165.        $game_party.gain_armor(item.id, 1)
  1166.      end
  1167.    end
  1168.    @result_window = Window_BattleResult.new(exp, gold, treasures)
  1169.    @phase5_wait_count = 100
  1170. end
  1171. #   =*****=
  1172. #--------------------------------------------------------------------------
  1173. # updating the movement
  1174. # since RPG isnt used to comments... i'll comment it again...
  1175. #--------------------------------------------------------------------------
  1176. def update_phase4_step3
  1177.    if @active_battler.current_action.kind == 0 and
  1178.       @active_battler.current_action.basic == 0
  1179.       # in this one... we have our weapon animations... for player and monster
  1180.      if @active_battler.is_a?(Game_Actor)
  1181.        @spriteset.actor_sprites[@active_battler.index].pose(@weapon_sprite)
  1182.      elsif @active_battler.is_a?(Game_Enemy)
  1183.        @spriteset.enemy_sprites[@active_battler.index].enemy_pose(@weapon_sprite_enemy)
  1184.      end
  1185.    end
  1186.    if @animation1_id == 0
  1187.      @active_battler.white_flash = true
  1188.    else
  1189.      @active_battler.animation_id = @animation1_id
  1190.      @active_battler.animation_hit = true
  1191.    end
  1192.    @phase4_step = 4
  1193. end
  1194.  
  1195. def update_phase4_step4
  1196.    # this here is for the hit animation...
  1197.    for target in @target_battlers
  1198.      if target.is_a?(Game_Actor) and !@active_battler.is_a?(Game_Actor)
  1199.        if target.guarding?
  1200.          @spriteset.actor_sprites[target.index].pose(2)
  1201.        else
  1202.          @spriteset.actor_sprites[target.index].pose(3)
  1203.        end
  1204.        elsif target.is_a?(Game_Enemy) and !@active_battler.is_a?(Game_Enemy)
  1205.        if target.guarding?
  1206.          @spriteset.enemy_sprites[target.index].enemy_pose(2)
  1207.        else
  1208.          @spriteset.enemy_sprites[target.index].enemy_pose(3)
  1209.        end
  1210.      end
  1211.      target.animation_id = @animation2_id
  1212.      target.animation_hit = (target.damage != "Miss")
  1213.    end
  1214.    @wait_count = 8
  1215.    @phase4_step = 5
  1216. end
  1217.  
  1218. def update_phase4_step5
  1219.    if @active_battler.hp > 0 and @active_battler.slip_damage?
  1220.      @active_battler.slip_damage_effect
  1221.      @active_battler.damage_pop = true
  1222.    end
  1223.  
  1224.    @help_window.visible = false
  1225.    @status_window.refresh
  1226.    # here comes the guard animations....
  1227.    if @active_battler.is_a?(Game_Actor)
  1228.      @spriteset.actor_sprites[@active_battler.index].pose(1)
  1229.    else
  1230.      @spriteset.enemy_sprites[@active_battler.index].enemy_pose(1)
  1231.    end
  1232.    for target in @target_battlers
  1233.      if target.damage != nil
  1234.        target.damage_pop = true
  1235.        if @active_battler.is_a?(Game_Actor)
  1236.          @spriteset.actor_sprites[@active_battler.index].pose(1)
  1237.        else
  1238.          @spriteset.enemy_sprites[@active_battler.index].enemy_pose(1)
  1239.        end
  1240.      end
  1241.    end
  1242.    @phase4_step = 6
  1243. end
  1244. #--------------------------------------------------------------------------
  1245. # ● フレーム更新 (メインフェーズ ステップ 6 : リフレッシュ)
  1246. #--------------------------------------------------------------------------
  1247. def update_phase4_step6
  1248.  
  1249.    # here we are asking if the player is dead and is a player or an enemy...
  1250.    # these lines are for the running back and standby animation....
  1251.    if @active_battler.is_a?(Game_Actor) and !@active_battler.dead?
  1252.      @spriteset.actor_sprites[@active_battler.index].move(@active_battler.screen_x, @active_battler.screen_y, 20)
  1253.      @spriteset.actor_sprites[@active_battler.index].pose(0)
  1254.    elsif !@active_battler.dead?
  1255.      @spriteset.enemy_sprites[@active_battler.index].move(@active_battler.screen_x, @active_battler.screen_y, 20)
  1256.      @spriteset.enemy_sprites[@active_battler.index].enemy_pose(0)
  1257.    end
  1258.    for target in @target_battlers
  1259.      if target.is_a?(Game_Actor) and !target.dead?
  1260.          @spriteset.actor_sprites[target.index].pose(1)
  1261.        elsif !target.dead?
  1262.          @spriteset.enemy_sprites[target.index].enemy_pose(1)
  1263.      end
  1264.    end
  1265.    $game_temp.forcing_battler = nil
  1266.    if @common_event_id > 0
  1267.      common_event = $data_common_events[@common_event_id]
  1268.      $game_system.battle_interpreter.setup(common_event.list, 0)
  1269.    end
  1270.    @phase4_step = 7
  1271. end
  1272.  
  1273. def update_phase4_step7
  1274.  
  1275.    # here we are asking if the player is dead and is a player or an enemy...
  1276.    # these lines are for the running back and standby animation....
  1277.    if @active_battler.is_a?(Game_Actor) and !@active_battler.dead?
  1278.      @spriteset.actor_sprites[@active_battler.index].pose(1)
  1279.    elsif !@active_battler.dead?
  1280.      @spriteset.enemy_sprites[@active_battler.index].enemy_pose(1)
  1281.    end
  1282.  
  1283.    $game_temp.forcing_battler = nil
  1284.    if @common_event_id > 0
  1285.      common_event = $data_common_events[@common_event_id]
  1286.      $game_system.battle_interpreter.setup(common_event.list, 0)
  1287.    end
  1288.    @phase4_step = 1
  1289. end
  1290.  
  1291.  
  1292. # this one is an extra... without this the animation whill not work correctly...
  1293.  
  1294. def update
  1295.    if $game_system.battle_interpreter.running?
  1296.      $game_system.battle_interpreter.update
  1297.      if $game_temp.forcing_battler == nil
  1298.        unless $game_system.battle_interpreter.running?
  1299.          unless judge
  1300.            setup_battle_event
  1301.          end
  1302.        end
  1303.        if @phase != 5
  1304.          @status_window.refresh
  1305.        end
  1306.      end
  1307.    end
  1308.    $game_system.update
  1309.    $game_screen.update
  1310.    if $game_system.timer_working and $game_system.timer == 0
  1311.      $game_temp.battle_abort = true
  1312.    end
  1313.    @help_window.update
  1314.    @party_command_window.update
  1315.    @actor_command_window.update
  1316.    @status_window.update
  1317.    @message_window.update
  1318.    @spriteset.update
  1319.    if $game_temp.transition_processing
  1320.      $game_temp.transition_processing = false
  1321.      if $game_temp.transition_name == ""
  1322.        Graphics.transition(20)
  1323.      else
  1324.        Graphics.transition(40, "Graphics/Transitions/" +
  1325.          $game_temp.transition_name)
  1326.      end
  1327.    end
  1328.    if $game_temp.message_window_showing
  1329.      return
  1330.    end
  1331.    if @spriteset.effect?
  1332.      return
  1333.    end
  1334.    if $game_temp.gameover
  1335.      $scene = Scene_Gameover.new
  1336.      return
  1337.    end
  1338.    if $game_temp.to_title
  1339.      $scene = Scene_Title.new
  1340.      return
  1341.    end
  1342.    if $game_temp.battle_abort
  1343.      $game_system.bgm_play($game_temp.map_bgm)
  1344.      battle_end(1)
  1345.      return
  1346.    end
  1347.    if @wait_count > 0
  1348.      @wait_count -= 1
  1349.      return
  1350.    end
  1351.  
  1352.    # this one holds the battle while the player moves
  1353.    for actor in @spriteset.actor_sprites
  1354.      if actor.moving
  1355.        return
  1356.      end
  1357.    end
  1358.    # and this one is for the enemy...
  1359.    for enemy in @spriteset.enemy_sprites
  1360.      if enemy.moving# and $game_system.animated_enemy
  1361.        return
  1362.      end
  1363.    end
  1364.  
  1365.    if $game_temp.forcing_battler == nil and
  1366.       $game_system.battle_interpreter.running?
  1367.      return
  1368.    end
  1369.    case @phase
  1370.    when 1
  1371.      update_phase1
  1372.    when 2
  1373.      update_phase2
  1374.    when 3
  1375.      update_phase3
  1376.    when 4
  1377.      update_phase4
  1378.    when 5
  1379.      update_phase5
  1380.    end
  1381. end
  1382.  
  1383.  
  1384. #==============================================================================
  1385. # end of the snipplet
  1386. # if you want the comments that where here just look at the scene_battle 4...
  1387. # i added some comments since RPG hasnt add any....
  1388. #==============================================================================
  1389. end

希望得VIP,我已经很努力了
远古之谜 ....<换了N次名>
无封面
回复 支持 反对

使用道具 举报

Lv1.梦旅人

秋寒

梦石
0
星屑
63
在线时间
801 小时
注册时间
2013-1-17
帖子
1992
6
发表于 2013-6-16 12:34:01 | 只看该作者
本帖最后由 1426 于 2013-6-16 14:53 编辑

http://www.66rpg.com/articles/4937
http://www.66rpg.com/articles/4961
http://www.66rpg.com/articles/4964

找了几个整合系统,看看有没有可以的

抱歉,一不小心挖坟了。。不过这是悬赏贴,悬赏贴有特殊处理吧..

点评

你这算挖坟么。。。  发表于 2013-6-16 14:36
回复 支持 反对

使用道具 举报

Lv2.观梦者

故九江太守

梦石
0
星屑
623
在线时间
2166 小时
注册时间
2012-12-5
帖子
4464
7
发表于 2013-6-16 14:35:40 | 只看该作者
给出空之轨迹的脚本还有换装脚本才能够帮助你改啊
回复 支持 反对

使用道具 举报

Lv2.观梦者

梦石
0
星屑
275
在线时间
1373 小时
注册时间
2005-10-16
帖子
5113

贵宾

8
发表于 2013-6-16 14:41:05 | 只看该作者
本帖最后由 亿万星辰 于 2013-6-16 14:42 编辑
Baby丶小CC 发表于 2013-4-30 20:37
@1426 @Baby丶小CC
换着不必要脚本,只需要事件
上楼就是,你可以制作上半身或者下半身,来代表穿衣服,或者换装。


根据装备来变更角色的图样并不是简单的使用更换角色图像功能就能实现的,当然如果说楼主只要求某一种装备对角色图像有影响那另当别论。

换装系统,一般也叫做纸娃娃,avatar,会关联很多个部位,比如帽子、衣服、裤子、鞋、武器等等,使用这个系统的游戏有很多。我们就以上面所说的5个装备位置来说,如果每个装备位置目前只有一种装备可以穿上,或者是脱下,也就是每个装备位置对应有两个状态,那么这5件装备就可以带来一个排列组合的问题,大概(多年不用竟然忘记这个东西怎么算了<真的么?>……)是好多种行走图,而这还只是5个装备位置只有1件装备的情况,如果说每个装备位置有十几件装备的话,准备这么多种行走图来执行更换角色图像显然是不科学的。。。

所以,可以采取把每个部位的装备行走图或战斗图都分别保存的方法,在绘制角色的行走图也好战斗图也好的时候,先绘制位于最底层的角色无装备图,然后再根据层次关系依序把装备对应的图片逐层描绘,这样以实现一个根据角色当前的装备动态生成角色行走图和战斗图的方法。
我只个搬答案的
叔叔我已经当爹了~
婚后闪人了……
回复 支持 反对

使用道具 举报

Lv2.观梦者 (暗夜天使)

万兽

梦石
0
星屑
597
在线时间
2271 小时
注册时间
2006-11-4
帖子
4868

贵宾

9
发表于 2013-6-16 15:20:50 | 只看该作者
亿万星辰 发表于 2013-6-16 14:41
根据装备来变更角色的图样并不是简单的使用更换角色图像功能就能实现的,当然如果说楼主只要求某一种装备 ...

之前也想这么弄的,但是一想到一个角色要创建好几个精灵就开始担心帧率了,一直也没去尝试……
反正RM的行走图就这么大,换不换也看不出来,俺是这么说服自己的。
回复 支持 反对

使用道具 举报

Lv2.观梦者

梦石
0
星屑
275
在线时间
1373 小时
注册时间
2005-10-16
帖子
5113

贵宾

10
发表于 2013-6-16 15:51:29 | 只看该作者
本帖最后由 亿万星辰 于 2013-6-16 15:57 编辑
弗雷德 发表于 2013-6-16 15:20
之前也想这么弄的,但是一想到一个角色要创建好几个精灵就开始担心帧率了,一直也没去尝试……
反正RM的 ...


角色的行走图是Sprite_Character是个精灵没错,但是它的bitmap图片载入也不过是通过RPG::Cache.character载入了一张图片而已,只要在这里把一层一层的装备行走图画在这个bitmap上去就好了,我有写过一个纸娃娃系统,虽然写的比较捉襟见肘,但是原理就是这样的。

点评

求范例学习学习。  发表于 2013-6-16 16:46
我只个搬答案的
叔叔我已经当爹了~
婚后闪人了……
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-11-12 05:42

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表