找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 22744|回复: 9

[求助] 想要汉化 renpy youx 拆包 反编译 文件完成以后导入renpy 出错...

[复制链接]
发表于 2020-1-12 21:04:34 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?立即注册

×
显示如下,这个怎么办了
I'm sorry, but errors were detected in your script. Please correct the
errors listed below, and try again.


File "game/cl/class_ui.rpy", line 350: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    timer 1 action clean_notifications repeat True
    ^

File "game/cl/class_ui.rpy", line 646: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    on "show" action Hide("quick_menu")
    ^

File "game/screens.rpy", line 366: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    style_prefix "main_menu"
    ^

File "game/screens.rpy", line 569: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    use game_menu(_("About"), scroll="viewport"):
    ^

File "game/screens.rpy", line 647: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    use file_slots(_("Save"))
    ^

File "game/screens.rpy", line 654: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    use file_slots(_("Load"))
    ^

File "game/screens.rpy", line 774: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    if renpy.mobile:
    ^

File "game/screens.rpy", line 988: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    predict False
    ^

File "game/screens.rpy", line 1069: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
    default device = "keyboard"
    ^

Ren'Py Version: Ren'Py 7.3.5.606
Sun Jan 12 20:55:58 2020


发表于 2020-1-15 17:23:01 | 显示全部楼层
本帖最后由 小猪 于 2020-1-15 17:32 编辑

首先使用最新版反编译工具来反编译代码。unrpyc开源地址:https://github.com/CensoredUsername/unrpyc/releases

其次,7.3.x版本,不再支持tag xxx和screen语句放在同一行的语法(描述可能不准确和完整,但是目前遇到的都是这个问题),要将tag xxx放到screen语句的代码块之中,不知你的问题是不是因为这个导致的。

示例如下:
[RenPy] 纯文本查看 复制代码
init -501 screen main_menu() tag menu:

要改成:
[RenPy] 纯文本查看 复制代码
init -501 screen main_menu():
    tag menu


反编译工具作者还未更新该特性,我自己在工具里修复了下这个问题,但是又导致了别的bug(特定语句会出错),就不献丑上传了。
目前版本的工具在反编译后,手动改一下语句就可以了,就是麻烦了一点罢了。
回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 14:47:24 | 显示全部楼层
TIM截图20200204144533.jpg 这个tag xx 是在哪个文件了。
我的文件夹结构是这个,刚开始学这个还搞不太清楚。麻烦了
回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 14:58:04 | 显示全部楼层
TIM截图20200204145713.jpg
TIM截图20200204145552.jpg
按照楼主之前的说明
修改改了之后出现如下错误。
回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 16:47:19 | 显示全部楼层

  1. I'm sorry, but errors were detected in your script. Please correct the
  2. errors listed below, and try again.


  3. File "game/cl/class_ui.rpy", line 350: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
  4.     timer 1 action clean_notifications repeat True
  5.     ^

  6. File "game/cl/class_ui.rpy", line 646: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
  7.     on "show" action Hide("quick_menu")
  8.     ^

  9. File "game/screens.rpy", line 363: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  10.     tag menu:
  11.     ^

  12. File "game/screens.rpy", line 564: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  13.     tag menu:
  14.     ^

  15. File "game/screens.rpy", line 646: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  16.     tag menu:
  17.     ^

  18. File "game/screens.rpy", line 654: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  19.     tag menu:
  20.     ^

  21. File "game/screens.rpy", line 775: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  22.     tag menu:
  23.     ^

  24. File "game/screens.rpy", line 989: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  25.     tag menu:
  26.     ^

  27. File "game/screens.rpy", line 1072: Line is indented, but the preceding screen statement does not expect a block. Please check this line's indentation.
  28.     tag menu:
  29.     ^

  30. Ren'Py Version: Ren'Py 7.3.5.606
  31. Tue Feb 04 16:46:15 2020
复制代码

回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 17:00:36 | 显示全部楼层

  1. I'm sorry, but errors were detected in your script. Please correct the
  2. errors listed below, and try again.


  3. File "game/cl/class_ui.rpy", line 350: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
  4.     timer 1 action clean_notifications repeat True
  5.     ^

  6. File "game/cl/class_ui.rpy", line 646: Line is indented, but the preceding tag statement does not expect a block. Please check this line's indentation.
  7.     on "show" action Hide("quick_menu")
  8.     ^

  9. Ren'Py Version: Ren'Py 7.3.5.606
  10. Tue Feb 04 17:00:15 2020
复制代码

回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 17:01:11 | 显示全部楼层
仔细看了下代码,修改了上面的部分然后就剩下这边两个有问题了?
回复 支持 抱歉

使用道具 举报

 楼主| 发表于 2020-2-4 17:03:00 | 显示全部楼层
可以了谢谢楼主了
回复 支持 抱歉

使用道具 举报

发表于 2020-3-14 15:49:40 | 显示全部楼层
小猪 发表于 2020-1-15 17:23
首先使用最新版反编译工具来反编译代码。unrpyc开源地址:https://github.com/CensoredUsername/unrpyc/rel ...

评分

参与人数 1活力 -100 收起 理由
BuErShen -100 违规警告:纯表情

查看全部评分

回复 支持 抱歉

使用道具 举报

发表于 2020-3-14 15:50:30 | 显示全部楼层
小猪 发表于 2020-1-15 17:23
首先使用最新版反编译工具来反编译代码。unrpyc开源地址:https://github.com/CensoredUsername/unrpyc/rel ...

前辈方便加下v嘛 有个问题咨询
回复 支持 抱歉

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|RenPy中文空间 ( 苏ICP备17067825号|苏公网安备 32092302000068号 )

GMT+8, 2024-12-23 21:50 , Processed in 0.137405 second(s), 28 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

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