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

Project1

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

真·对话加强脚本图片翻转问题.

 关闭 [复制链接]

Lv2.观梦者

梦石
0
星屑
253
在线时间
574 小时
注册时间
2006-8-25
帖子
969
跳转到指定楼层
1
发表于 2008-8-21 06:32:55 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
http://rpg.blue/web/htm/news197.htm

我用了这个脚本的\L[001]\R[001]显示图片的功能.
\L[001]会使图片翻转,刚好相反....我想\R[001]翻转,\L[001]不翻转.
于是我把在L的@left_picture.mirror = true删掉加在R里,发现出了不少问题.
谁会把它们效果反过来,脚本如下.
  1.       #——左半身像设置
  2.       if (/\\[Ll]\[(.+?)\]/.match(@now_text))!=nil then
  3.         @face = "" + $1 + ".png"
  4.         if $加密 == true
  5.           if @left_picture != nil
  6.             @left_picture.dispose
  7.           end
  8.           @left_picture = Sprite.new
  9.           @left_picture.bitmap = Bitmap.new("Graphics/battlers/#{@face}")
  10.           @left_picture.y = 0
  11.           @left_picture.x = -50
  12.           @left_picture.mirror = true
  13.           @now_text.gsub!(/\\[Ll]\[(.*?)\]/) { "" }
  14.         else         
  15.           if FileTest.exist?("Graphics/battlers/#{@face}")
  16.             if @left_picture != nil
  17.               @left_picture.dispose
  18.             end
  19.             @left_picture = Sprite.new
  20.             @left_picture.bitmap = Bitmap.new("Graphics/battlers/#{@face}")
  21.             @left_picture.y = 0
  22.             @left_picture.x = -50
  23.             @left_picture.mirror = true
  24.             @now_text.gsub!(/\\[Ll]\[(.*?)\]/) { "" }
  25.           end
  26.         end        
  27.       end
  28.       #——右半身像设置
  29.       if (/\\[Rr]\[(.+?)\]/.match(@now_text))!=nil then
  30.         @face = "" + $1 + ".png"
  31.         if $加密 == true
  32.           if @right_picture != nil
  33.             @right_picture.dispose
  34.           end
  35.           @right_picture = Sprite.new
  36.           @right_picture.bitmap = Bitmap.new("Graphics/battlers/#{@face}")
  37.           @right_picture.y = 0
  38.           @right_picture.x = 690-@right_picture.bitmap.width
  39.           @now_text.gsub!(/\\[Rr]\[(.*?)\]/) { "" }
  40.         else
  41.           if FileTest.exist?("Graphics/battlers/#{@face}")
  42.             if @right_picture != nil
  43.               @right_picture.dispose
  44.             end
  45.             @right_picture = Sprite.new
  46.             @right_picture.bitmap = Bitmap.new("Graphics/battlers/#{@face}")
  47.             @right_picture.y = 0
  48.             @right_picture.x = 690-@right_picture.bitmap.width
  49.             @now_text.gsub!(/\\[Rr]\[(.*?)\]/) { "" }
  50.           end
  51.         end
  52.       end
  53.       if (/\\[Rr]k/.match(@now_text)) != nil
  54.         @right_keep = true
  55.         @now_text.sub!(/\\[Rr]k/) { "" }
  56.       end
  57.       if (/\\[Ll]k/.match(@now_text)) != nil
  58.         @left_keep = true
  59.         @now_text.sub!(/\\[Ll]k/) { "" }
  60.       end
复制代码

版务信息:本贴由楼主自主结贴~

Lv5.捕梦者

梦石
0
星屑
39922
在线时间
5799 小时
注册时间
2006-11-10
帖子
6676
2
发表于 2008-8-21 09:18:40 | 只看该作者
我想说的是,为什么一定要改脚本?

开PS,把图左右反转后保存,然后不就是你要的效果了?- - ,别以为脚本法比美工法容易...

不过这个要改也是比较容易的,

于是我把在L的@left_picture.mirror = true删掉加在R里,发现出了不少问题.

加到R里的换成这句就可以了 @right_picture.mirror = true

系统信息:本贴由楼主认可为正确答案,66RPG感谢您的热情解答~
回复 支持 反对

使用道具 举报

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

本版积分规则

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

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

GMT+8, 2025-7-24 02:29

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

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