| 赞 | 1  | 
 
| VIP | 246 | 
 
| 好人卡 | 87 | 
 
| 积分 | 1 | 
 
| 经验 | 34142 | 
 
| 最后登录 | 2015-1-15 | 
 
| 在线时间 | 323 小时 | 
 
 
 
 
 
Lv1.梦旅人 
	- 梦石
 - 0 
 
        - 星屑
 - 55 
 
        - 在线时间
 - 323 小时
 
        - 注册时间
 - 2010-8-21
 
        - 帖子
 - 666
 
 
 
 | 
	
先给lz说说,这很那个...什么什么的...慎用..可能出现不可预料错误...而且效率会下降(一点点). 
慎用- class Bitmap
 
 -   Replace = [["他","她"],]
 
 -   alias draw_text_ draw_text unless $_f12_press
 
 -   $_f12_press = true
 
 -   def draw_text(*ary)
 
 -     if ary[0].is_a?(Rect)
 
 -       Replace.each{|s|
 
 -         while ary[1].include?(s[0])
 
 -           #break if !ary[1].include?(s[0])
 
 -           ary[1].sub!(s[0]) {s[1]} 
 
 -         end
 
 -         }
 
 -       draw_text_(*ary)
 
 -     else
 
 -       Replace.each{|s|
 
 -         while ary[4].include?(s[0])
 
 -           #break if !ary[4].include?(s[0])
 
 -           ary[4].sub!(s[0]) {s[1]} 
 
 -         end
 
 -         }
 
 -       draw_text_(*ary)
 
 -     end
 
 -   end
 
 - end
 
  复制代码 将它插到脚本的最上面... 
 
Replace = [["他","她"],]    
说明了替换方法... 
 [["他","她"],]   就是 把 前者替换为后者..,可以多个..比如: 
 
Replace = [["他","她"],["她","它"],["它","他"],] 
.......................... 
别忘了逗号..    |   
 
评分
- 
查看全部评分
 
 
 
 
 
 |