[cleo源码翻译]万华镜禁术——须佐能乎CLEO(susanoho)
本帖最后由 razor 于 2012-4-24 14:19 编辑源码:
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'SUSANO'
:SUSANO_11
wait 0
32@ = 0
if
0AB0: key_pressed 90
else_jump @SUSANO_286
:SUSANO_37
04ED: load_animation "SUSANO"
wait 0
if
0AB0: key_pressed 90
else_jump @SUSANO_286
if
32@ > 2500
else_jump @SUSANO_279
Model.Load(19997)
Model.Load(19996)
Model.Load(3065)
Audiostream.Load(14@, "CLEO\MP3\SUSANO_KAI.MP3")
Audiostream.Load(15@, "CLEO\MP3\SUSANO_JS.MP3")
Audiostream.Load(16@, "CLEO\MP3\SUSANO_PAO.MP3")
Audiostream.Load(17@, "CLEO\MP3\SUSANO_OVER.MP3")
Audiostream.PerformAction(14@, PLAY)
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_KAI" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB
wait 3000
jump @SUSANO_293
:SUSANO_279
jump @SUSANO_37
:SUSANO_286
jump @SUSANO_11
:SUSANO_293
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0
1@ = Object.Create(19997, 0.0, 0.0, 0.0)
19@ = Object.Create(19997, 10.0, 10.0, 10.0)
0750: set_object 19@ visibility 0
Object.CollisionDetection(1@) = False
Object.CollisionDetection(19@) = False
18@ = Actor.Health($PLAYER_ACTOR)
jump @SUSANO_404
:SUSANO_404
wait 0
31@ = 0
3@ = 0
25@ = 0
069B: attach_object 19@ to_actor $PLAYER_ACTOR with_offset 2.0 1.3 -1.5 rotation 0.0 0.0 16.0
069B: attach_object 1@ to_actor $PLAYER_ACTOR with_offset 0.0 1.3 -1.5 rotation 0.0 0.0 0.0
jump @SUSANO_512
:SUSANO_512
wait 0
27@ = Object.Angle(19@)
32@ = 50.1
30@ = 5.0
if
Player.Defined($PLAYER_CHAR)
else_jump @SUSANO_1502
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0
09E5: create_flash_light_at 7@ 8@ 9@ RGB_mask 49 31 135 radius 120.0
Actor.SetImmunities($PLAYER_ACTOR, 1, 1, 1, 1, 1)
016F: create_particle 3 rotation_factor 0.0 size 10.0 intensity 1 flags 90 54 145 at 7@ 8@ 9@
jump @SUSANO_666
:SUSANO_666
if and
0AB0: key_pressed 90
0AB0: key_pressed 88
else_jump @SUSANO_692
jump @SUSANO_1502
:SUSANO_692
25@ += 1
04C4: store_coords_to 11@ 12@ 13@ from_actor $PLAYER_ACTOR with_offset 4.0 1.0 1.5
if and
25@ > 100
00E1: player 0 pressed_key 4
0184: actor $PLAYER_ACTOR health >= 12
else_jump @SUSANO_1377
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_JS" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB
wait 200
18@ -= 10
Actor.Health($PLAYER_ACTOR) = 18@
28@ = Object.Create(19996, 0, 0, 50)
Object.CollisionDetection(28@) = False
29@ = Object.Create(3065, 11@, 12@, 13@)
0750: set_object 29@ visibility 0
069A: attach_object 28@ to_object 29@ with_offset 0.0 0.0 0.0 rotation 0.0 0.0 30.0
Object.CollisionDetection(29@) = True
04D9: object 29@ set_scripted_collision_check 1
02F6: 20@ = sine 27@ // (float)
02F7: 21@ = cosine 27@ // (float)
006B: 20@ *= 32@ // (float)
006B: 21@ *= 32@ // (float)
20@ *= -1.0
Object.ToggleInMovingList(29@) = True
Object.Throw(29@, 20@, 21@, 10)
25@ = 0
2@ = 0
jump @SUSANO_998
:SUSANO_998
wait 0
2@ += 1
Actor.SetImmunities($PLAYER_ACTOR, 1, 1, 1, 1, 1)
0400: store_coords_to 11@ 12@ 13@ from_object 29@ with_offset 0.0 0.0 0.0
016F: create_particle 3 rotation_factor 0.0 size 5.0 intensity 1 flags 90 54 145 at 11@ 12@ 13@
09E5: create_flash_light_at 11@ 12@ 13@ RGB_mask 49 31 135 radius 20.0
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0
09E5: create_flash_light_at 7@ 8@ 9@ RGB_mask 49 31 135 radius 20.0
016F: create_particle 3 rotation_factor 0.0 size 10.0 intensity 1 flags 90 54 145 at 7@ 8@ 9@
if or
04DA: has_object 29@ collided
2@ > 200
else_jump @SUSANO_998
Audiostream.PerformAction(15@, PLAY)
0400: store_coords_to 11@ 12@ 13@ from_object 29@ with_offset 0.0 0.0 0.0
066D: 33@ = attach_particle "SUSANO_LIGHT" to_object 28@ with_offset 0.0 0.0 3.0 flag 1
064F: remove_references_to_particle 33@
066D: 33@ = attach_particle "ELECTRIC_MED" to_object 28@ with_offset 0.0 0.0 0.0 flag 1
064F: remove_references_to_particle 33@
0565: create_soundless_explosion_at 11@ 12@ 13@ type 8
Object.Destroy(28@)
Object.Destroy(29@)
2@ = 0
jump @SUSANO_1377
:SUSANO_1377
31@ += 1
3@ += 1
if
31@ > 50
else_jump @SUSANO_512
18@ -= 1
Actor.Health($PLAYER_ACTOR) = 18@
31@ = 0
jump @SUSANO_1438
:SUSANO_1438
if
0184: actor $PLAYER_ACTOR health >= 5
else_jump @SUSANO_1502
jump @SUSANO_1463
:SUSANO_1463
if
3@ > 120
else_jump @SUSANO_512
Audiostream.PerformAction(16@, PLAY)
3@ = 0
jump @SUSANO_512
:SUSANO_1502
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 0, 0, 0)
Object.Destroy(1@)
Object.Destroy(19@)
32@ = 0
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_OVER" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB
Audiostream.PerformAction(17@, PLAY)
Audiostream.PerformAction(14@, STOP)
Audiostream.Release(14@)
Audiostream.PerformAction(15@, STOP)
Audiostream.Release(15@)
Audiostream.PerformAction(16@, STOP)
Audiostream.Release(16@)
wait 2670
Audiostream.PerformAction(17@, STOP)
Audiostream.Release(17@)
04EF: release_animation "SUSANO"
jump @SUSANO_11
为了手机党能看,我就不弄代码框了
注:1.续作和剑的模型编号登记在附带的DATA里面的ide文件
2.设置各种时间变量实际是用来判断主角血量和制造续作状态特效和声音所需(过后我会详细说明),并进行多个时间同时判断【包括减血,续作状态特效及 判断续作剑是否爆炸】
3.由于没有进游戏测试,很多地方都是猜得,可能有误
4.只是翻译了大概,有些语句翻译我直接省略
5.翻译的很蛋疼。。。有错请指出
sannybuilder下载地址from sannybuilder吧
http://tieba.baidu.com/p/1108373804
----------------------------分割线-----------------------------
欢迎cleo people们一起探讨,Welcome!!
还有kwanz可以帮忙校正吗?
召唤kwanz呼唤kwazn = = @kwanz@ kwanz
“好了,开始翻译”
// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007
{$VERSION 3.1.0027}
{$CLEO .cs}
//-------------MAIN---------------
thread 'SUSANO'
:SUSANO_11
wait 0
32@ = 0 // 時間變量
if
0AB0: key_pressed 90 // 如果按了Z鍵
jf @SUSANO_286 //否則跳回開頭(2次跳轉后)
:SUSANO_37
04ED: load_animation "SUSANO"//載入續作動作模組
wait 0
if
0AB0: key_pressed 90 // 如果按了Z鍵
jf @SUSANO_286 //否則跳回開頭(2次跳轉后)
if
32@ > 2500 //如果時間過了2500ms
jf @SUSANO_279 //否則跳囘上面循環 SUSANO_37 (繼續循環,直至系統判斷時間過2500ms)
Model.Load(19997) // 加載續作模組
Model.Load(19996) // 加載續作劍模組
Model.Load(3065) // 加載普通物體
Audiostream.Load(14@, "CLEO\MP3\SUSANO_KAI.MP3") //加載'發動續作'的聲音 = 14@
Audiostream.Load(15@, "CLEO\MP3\SUSANO_JS.MP3") // 加載'續作劍攻擊'的聲音 = 15@
Audiostream.Load(16@, "CLEO\MP3\SUSANO_PAO.MP3") // 加載'續作狀態'的聲音 =16@
Audiostream.Load(17@, "CLEO\MP3\SUSANO_OVER.MP3")// 加載'結束續作'的聲音 =17@
Audiostream.PerformAction(14@, PLAY)//播放聲音14@
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_KAI" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB// 令主角做發動續作動作
wait 3000 //等3000ms
jump @SUSANO_293// 跳到下面的循環 SUSANO_293
:SUSANO_279
jump @SUSANO_37
:SUSANO_286
jump @SUSANO_11
http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063分割綫 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063
:SUSANO_293
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0 //貯存主角偏移量為7@ 8@ 9@
1@ = Object.Create(19997, 0.0, 0.0, 0.0)// 生成續作模型 (19997後面的數字我猜不出什麽意思)
19@ = Object.Create(19997, 10.0, 10.0, 10.0)// 同上
0750: set_object 19@ visibility 0 // 物體19@不可見
Object.CollisionDetection(1@) = False //物體19@ 無碰撞係數
Object.CollisionDetection(19@) = False//同上
18@ = Actor.Health($PLAYER_ACTOR) // 定義主角血為18@
jump @SUSANO_404
:SUSANO_404
wait 0
31@ = 0//時間變量
3@ = 0//時間變量
25@ = 0//時間變量
069B: attach_object 19@ to_actor $PLAYER_ACTOR with_offset 2.0 1.3 -1.5 rotation 0.0 0.0 16.0 //把續作模組附在主角偏移量2.0 1.3 -1.5
069B: attach_object 1@ to_actor $PLAYER_ACTOR with_offset 0.0 1.3 -1.5 rotation 0.0 0.0 0.0 //同上
jump @SUSANO_512
http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063分割綫http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063
:SUSANO_512
wait 0
27@ = Object.Angle(19@)//續作角度
32@ = 50.1//定義時間為50.1
30@ = 5.0// 这个变量我不懂意思
if
Player.Defined($PLAYER_CHAR) //如果主角被定義
jf @SUSANO_1502
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0 //儲存主角坐標為7@ 8@ 9@
|09E5: create_flash_light_at 7@ 8@ 9@ RGB_mask 49 31 135 radius 120.0// 生成半徑120的閃光于7@ 8@ 9@
Actor.SetImmunities($PLAYER_ACTOR, 1, 1, 1, 1, 1) //主角無敵
016F: create_particle 3 rotation_factor 0.0 size 10.0 intensity 1 flags 90 54 145 at 7@ 8@ 9@ //生成粒子‘3’ 的特效類型為10
jump @SUSANO_666
:SUSANO_666
if and
0AB0: key_pressed 90 |
|-如果按Z+X
0AB0: key_pressed 88 |
jf @SUSANO_692 //否則跳轉後面循環 SUSANO_692
jump @SUSANO_1502// 結束續作語段(最後一段)
:SUSANO_692
25@ += 1 // 25@加1重新存為25@
04C4: store_coords_to 11@ 12@ 13@ from_actor $PLAYER_ACTOR with_offset 4.0 1.0 1.5 // 贮存主角偏移量4.0 1.0 1.5为11@ 12@ 13@
if and
25@ > 100 // 25@> 100
00E1: player 0 pressed_key 4 // 如果按xx功能键(忘了哪个)
0184: actor $PLAYER_ACTOR health >= 12 // 主角血量大于12
jf @SUSANO_1377 // 時間判斷語段
http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063分割綫 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063
以下是關於續作劍 (感覺這段翻譯有誤)
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_JS" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB // 丢剑的动作
wait 200
18@ -= 10// 主角的血量減10
Actor.Health($PLAYER_ACTOR) = 18@//重新定義主角的血
28@ = Object.Create(19996, 0, 0, 50) // 須佐劍
Object.CollisionDetection(28@) = False// 28@无碰撞系数
29@ = Object.Create(3065, 11@, 12@, 13@) // 普通物體
0750: set_object 29@ visibility 0 // 普通物体29@不可见
069A: attach_object 28@ to_object 29@ with_offset 0.0 0.0 0.0 rotation 0.0 0.0 30.0 // 物體28@附在劍上
Object.CollisionDetection(29@) = True // 29@有碰撞系数
以下这段不大理解,估计是制造抛物线轨迹
04D9: object 29@ set_scripted_collision_check 1 //= =不明意思
02F6: 20@ = sine 27@ // (float) // 20@ = sine 27@(續作的角度)sine為正弦波
02F7: 21@ = cosine 27@ // (float)// 20@ = cosine 27@(續作的角度)cosine為餘弦波
006B: 20@ *= 32@ // (float)
006B: 21@ *= 32@ // (float)
20@ *= -1.0 // 製造抛物綫
Object.ToggleInMovingList(29@) = True
Object.Throw(29@, 20@, 21@, 10)
25@ = 0 //時間变量
2@ = 0 //時間变量
jump @SUSANO_998
http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063分割綫 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063
以下是关于特效的,我就不翻译了:SUSANO_998
wait 0
2@ += 1 // 时间变量2@加1
Actor.SetImmunities($PLAYER_ACTOR, 1, 1, 1, 1, 1) //主角無敵
0400: store_coords_to 11@ 12@ 13@ from_object 29@ with_offset 0.0 0.0 0.0 // 儲存物體29@坐標(須佐劍)為11@ 12@ 13@
016F: create_particle 3 rotation_factor 0.0 size 5.0 intensity 1 flags 90 54 145 at 11@ 12@ 13@ // 生成粒子3于11@ 12@ 13@
09E5: create_flash_light_at 11@ 12@ 13@ RGB_mask 49 31 135 radius 20.0 //生成閃光于11@ 12@ 13@
04C4: store_coords_to 7@ 8@ 9@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0 //儲存主角坐標為7@ 8@ 9@
09E5: create_flash_light_at 7@ 8@ 9@ RGB_mask 49 31 135 radius 20.0// 製造閃光于7@ 8@ 9@
016F: create_particle 3 rotation_factor 0.0 size 10.0 intensity 1 flags 90 54 145 at 7@ 8@ 9@ // 生成粒子3于 7@ 8@ 9@
if or
04DA: has_object 29@ collided// 如果須佐劍碰撞
2@ > 200 // 或者時間過了200秒
jf @SUSANO_998
Audiostream.PerformAction(15@, PLAY)// 播放須佐劍攻擊聲音
0400: store_coords_to 11@ 12@ 13@ from_object 29@ with_offset 0.0 0.0 0.0 //儲存物體29@坐標為11@ 12@ 13@
066D: 33@ = attach_particle "SUSANO_LIGHT" to_object 28@ with_offset 0.0 0.0 3.0 flag 1 //閃電特效
064F: remove_references_to_particle 33@ //移去特效
066D: 33@ = attach_particle "ELECTRIC_MED" to_object 28@ with_offset 0.0 0.0 0.0 flag 1 //閃電特效
064F: remove_references_to_particle 33@ //移去特效
0565: create_soundless_explosion_at 11@ 12@ 13@ type 8 //製造爆炸類型為無聲並不可見的
Object.Destroy(28@) //銷毀物体 28@
Object.Destroy(29@) // 銷毀物体 29 @
2@ = 0 // 重新定義時間為0
jump @SUSANO_1377 // 時間判斷語段
http://piccache1.soso.com/face/_13096517108827562063 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063分割綫 http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063http://piccache1.soso.com/face/_13096517108827562063
時間判斷語段
:SUSANO_1377
31@ += 1 // 之前31@為零加1重新貯存為31@
3@ += 1 // 同上
if
31@ > 50 //時間大於50
jf @SUSANO_512 // 返回生成續作亮光那一段
18@ -= 1 // 主角的血減 1
Actor.Health($PLAYER_ACTOR) = 18@// 重新定義
31@ = 0 // 重新定義31@
jump @SUSANO_1438 // 判定主角血量語段
:SUSANO_1438
if
0184: actor $PLAYER_ACTOR health >= 5 主角血是否大於5
jf @SUSANO_1502 // 結束續作語段
jump @SUSANO_1463
:SUSANO_1463
if
3@ > 120 //時間判斷
jf @SUSANO_512
Audiostream.PerformAction(16@, PLAY) // 播放續作狀態聲音
3@ = 0 //重新定義時間為0
jump @SUSANO_512 // 返回生成續作亮光那一段
:SUSANO_1502// 結束續作語段
Actor.SetImmunities($PLAYER_ACTOR, 0, 0, 0, 0, 0) //撤銷主角無敵
Object.Destroy(1@) //摧毀物體1@
Object.Destroy(19@) //摧毀物體19@
32@ = 0 //時間等於0
0812: AS_actor $PLAYER_ACTOR perform_animation "SUSANO_OVER" IFP_file "SUSANO" 10.0 loopA 0 lockX 1 lockY 1 lockF 0 time -1 // versionB // 收尾的动作
Audiostream.PerformAction(17@, PLAY) //收尾的‘啊’声= =
Audiostream.PerformAction(14@, STOP)-------------------------------
Audiostream.Release(14@) |
Audiostream.PerformAction(15@, STOP) |
Audiostream.Release(15@) |
Audiostream.PerformAction(16@, STOP) |-----音效全部关闭
Audiostream.Release(16@) |
wait 2670 |
Audiostream.PerformAction(17@, STOP) |
Audiostream.Release(17@)---------------------------------------------
04EF: release_animation "SUSANO"//重置续作动作
jump @SUSANO_11 // 跳转到开头
http://piccache1.soso.com/face/_13096517108827562063
哟西,支持一个,都是比阿飞强的牛人
顶 看的我一头暮水 手機測試唔壓力,能看清 此原理已被摒弃...
新原理已有预案 kami 发表于 2012-4-16 11:02此原理已被摒弃...新原理已有预案
waa…kami要出新續作啊! 完全是不懂的说 @_@补作业中,先路过 Sidlady 发表于 2012-4-16 11:17 static/image/common/back.gif
waa…kami要出新續作啊!
真的吗真的吗:lol 支持一个~ 呵呵,感觉翻译的不错了有奖励的说
新续作的原理我等你上官方群在慢慢讨教
问题是模型有了没? 一推文字 像座山 看不懂:loveliness: 看得懂.... 本帖最后由 razor 于 2012-4-17 14:16 编辑
紫夕£夏夜 发表于 2012-4-16 19:08 呵呵,感觉翻译的不错了 有奖励的说 新续作的原理我等你上官方群在慢慢讨教 问题是模型有了没? 我在想能不能人綁人,即給續佐骨骼,然後綁在主角身上,再用cleo做動作……
就像動漫那樣 razor 发表于 2012-4-17 14:15 static/image/common/back.gif
我在想能不能人綁人,即給續佐骨骼,然後綁在主角身上,再用cleo做動作……
当然可以,这样的逻辑外国人早用了。
这是小意思,只是人物本身不能发光,晚上一团黑,没有须作的效果而已。