mirror of
https://github.com/open-goal/jak-project
synced 2026-08-26 00:03:48 -04:00
decomp3: more misc files (#3466)
Makes a bunch of missions mostly playable, including: - `arena-training-1` - `arena-fight-1` - `wascity-chase` - `arena-fight-2` - `arena-fight-3` - `volcano-darkeco` - `desert-hover` - `nest-eggs` - `temple-climb` - `temple-oracle` - `temple-tests` - `desert-beast-battle` - `desert-turtle-training` - `desert-course-race` - `desert-artifact-race1` - `wascity-leaper-race` - `wascity-pre-game` - `sewer-met-hum` - `forest-kill-plants` - `forest-ring-chase` - `temple-defend` - `tower-destroy` - `desert-glide` --- Files: - `ripple` - `waswide-mood` - `sig-rider` - `nst-tasks` - `nst-part` - `nst-gas` - `nst-eggs-h` - `nst-obs` - `nst-mood` - `egg-spider` - `wasdoors-init` - `wasall-tasks` - `wvehicle-race` - `wcar-marauder` - `wcar-marauder-b` - `turret-control` - `was-squad-control` - `turtle-training` - `kleever-rider` - `course-race` - `artifact-race` - `desert-hover` - `desbeast-path-h` - `des-beast` - `desertg-obs` - `desertf-obs` - `desertd-obs` - `desert-dust-storm` - `des-cactus` - `race-hud` - `race-info` - `race-manager` - `tizard` - `flyingsaw` - `hover-training` - `temple-mood` - `temple-obs` - `temple-obs2` - `temple-part` - `temple-scenes` - `templex-mood` - `templex-obs` - `templex-part` - `tomb-baby-spider` - `target-turret-shot` - `target-turret` - `beast-battle-path` - `des-beast-2` - `mh-flyer` - `scorpion-gun` - `hover-enemy-h` - `hover-enemy` - `hover-formation-h` - `hover-formation` - `hover-nav-control-h` - `hover-nav-control` - `flamer-hover` - `hover-nav-templea` - `robo-hover` - `hover-nav-sewb` - `hover-nav-sewg` - `hover-nav-sewj` - `hover-nav-sewl` - `hover-nav-sewo` - `hover-nav-towera` - `tower-mood` - `tower-obs` - `tower-scenes` - `tower-part` - `eco-green-collider` - `forest-bridges` - `forest-kill-plants` - `forest-mood` - `forest-ring-chase` - `forest-tasks` - `forest-part` - `foresta-obs` - `hover-nav-foresta` - `mh-plant` - `dp-bipedal-part` - `dp-bipedal-shot` - `dp-bipedal` - `neo-spawner` - `for-turret` - `for-turret-shot` - `neo-wasp` - `neo-wasp-part` - `volcanox-scenes` - `volcanox-mood` - `volcano-scenes` - `volcano-mood` - `volcano-obs` - `volcano-obs2` - `chain-physics` - `rigid-body-plat` - `volcano-part` - `flamer-lava` - `flitter` - `spiky-frog` - `flut-wild` - `target-indax` - `target-indax-hang` - `mantis` - `volcanox-obs` - `spyder` - `wcar-faccar` - `mhcity-obs2` - `mhcity-part` - `mhcity-obs` - `dm-mine-spider` - `rapid-gunner` - `stadium-mood` - `stadium-scenes` - `stadiuma-mood` - `stadiuma-part` - `kanga-lizard` - `marauder` - `arena-scenes` - `wasstada-mood` - `wasstada-obs` - `wasstada-part` - `wasstadb-obs` - `wasstadc-obs` - `dm-flyer` - `maker-part` - `maker-projectile` - `skeet-part` - `wascity-turret` - `wasgun-h` - `wasgun-hud` - `wasgun-manager` - `nav-graph-h` - `traffic-engine-h` - `waswide-init` - `cty-borrow-manager-h` - `cty-borrow-manager` - `desert-part` - `height-map-h` - `height-map` - `traffic-height-map` - `vehicle-control` - `hvehicle-h` - `hvehicle` - `hvehicle-effects` - `hvehicle-physics` - `hvehicle-util` - `glider-h` - `glider-hud` - `glider-manager` - `glider-ring` - `glider-ring-part` - `h-glider` - `hanga-init` - `was-pre-game` - `was-leaper-race` - `flut-racer` - `desert-scenes` - `desert-lizard-h` - `desert-lizard-task` - `desert-lizard` - `throne-scenes` - `waspal-mood` - `waspala-obs` - `waspala-part` - `deswalk-obs` - `deswalk-part` - `terraformer-drone` - `terraformer-head` - `terraformer-part` - `terraformer-setup`
This commit is contained in:
@@ -6586,6 +6586,10 @@ bool try_vector_reset_inline(const Env& env,
|
||||
RegisterAccess orig;
|
||||
store = repop_passthrough_arg(store, stack, env, &orig, &got_orig);
|
||||
|
||||
if (!store) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// create the actual form
|
||||
Form* new_thing = pool.form<GenericElement>(
|
||||
GenericOperator::make_function(pool.form<ConstantTokenElement>("vector-reset!")),
|
||||
|
||||
@@ -760,6 +760,10 @@ bool Matcher::do_match(Form* input, MatchResult::Maps* maps_out, const Env* cons
|
||||
break;
|
||||
}
|
||||
|
||||
if (entries_matched == m_entry_matchers.size()) {
|
||||
break;
|
||||
}
|
||||
|
||||
if (m_entry_matchers.at(entries_matched)
|
||||
.do_match(let_body->entries().at(0), maps_out, env)) {
|
||||
entries_matched++;
|
||||
|
||||
+4272
-4673
File diff suppressed because it is too large
Load Diff
@@ -615,5 +615,167 @@
|
||||
"wvehicle": [[6, "(function collide-shape-prim none)"]],
|
||||
"pilot-states": [
|
||||
[15, "(function surface surface surface int object :behavior target)"]
|
||||
],
|
||||
"was-squad-control": [[16, "(function object object)"]],
|
||||
"des-cactus": [[13, "(function collide-shape-prim none)"]],
|
||||
"desertg-obs": [
|
||||
[4, "(function collide-shape-prim none)"],
|
||||
[7, "(function collide-shape-prim none)"]
|
||||
],
|
||||
"desertf-obs": [[7, "(function none)"]],
|
||||
"temple-obs2": [
|
||||
[43, "(function symbol)"],
|
||||
[46, "(function object :behavior tpl-watcher)"]
|
||||
],
|
||||
"temple-scenes": [
|
||||
[0, "(function none)"],
|
||||
[1, "(function none)"],
|
||||
[2, "(function none)"],
|
||||
[3, "(function none :behavior scene-player)"],
|
||||
[4, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"des-beast-2": [
|
||||
[1, "(function cspace transformq none)"],
|
||||
[2, "(function cspace transformq none)"],
|
||||
[23, "(function projectile none)"]
|
||||
],
|
||||
"scorpion-gun": [
|
||||
[33, "(function cspace transformq none)"],
|
||||
[34, "(function cspace transformq none)"]
|
||||
],
|
||||
"hover-formation": [
|
||||
[10, "(function form-search-info float)"],
|
||||
[11, "(function int int form-search-info uint)"],
|
||||
[14, "(function vector object)"],
|
||||
[15, "(function int int (pointer object) int)"]
|
||||
],
|
||||
"robo-hover": [
|
||||
[14, "(function robo-hover cspace float float vector vector int object)"]
|
||||
],
|
||||
"tower-scenes": [
|
||||
[0, "(function none :behavior scene-player)"],
|
||||
[1, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"forest-kill-plants": [
|
||||
[5, "(function engine-pers connection-pers object object symbol)"],
|
||||
[7, "(function engine-pers connection-pers object object symbol)"]
|
||||
],
|
||||
"forest-tasks": [
|
||||
[0, "(function none :behavior scene-player)"],
|
||||
[1, "(function none :behavior scene-player)"],
|
||||
[2, "(function none :behavior scene-player)"],
|
||||
[3, "(function none :behavior scene-player)"],
|
||||
[4, "(function none :behavior scene-player)"],
|
||||
[5, "(function none :behavior scene-player)"],
|
||||
[6, "(function none :behavior scene-player)"],
|
||||
[7, "(function none :behavior scene-player)"],
|
||||
[8, "(function none :behavior scene-player)"],
|
||||
[9, "(function none :behavior scene-player)"],
|
||||
[10, "(function none :behavior scene-player)"],
|
||||
[11, "(function none :behavior scene-player)"],
|
||||
[12, "(function none :behavior scene-player)"],
|
||||
[13, "(function none :behavior scene-player)"],
|
||||
[14, "(function none :behavior scene-player)"],
|
||||
[15, "(function none :behavior scene-player)"],
|
||||
[16, "(function none :behavior scene-player)"],
|
||||
[17, "(function none :behavior scene-player)"],
|
||||
[18, "(function none :behavior scene-player)"],
|
||||
[19, "(function none :behavior scene-player)"],
|
||||
[20, "(function none :behavior scene-player)"],
|
||||
[21, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"neo-wasp": [[15, "(function neo-wasp cspace transformq float float none)"]],
|
||||
"for-turret": [
|
||||
[1, "(function cspace transformq none)"],
|
||||
[2, "(function cspace transformq none)"],
|
||||
[3, "(function cspace transformq none)"],
|
||||
[4, "(function cspace transformq none)"]
|
||||
],
|
||||
"volcano-obs": [[38, "(function cspace transformq none)"]],
|
||||
"spiky-frog": [[9, "(function cspace transformq none)"]],
|
||||
"volcano-scenes": [
|
||||
[1, "(function none :behavior scene-player)"],
|
||||
[2, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"mantis": [
|
||||
[8, "(function mantis vector float int vector vector)"],
|
||||
[15, "(function mantis collide-shape-moving vector symbol)"]
|
||||
],
|
||||
"wcar-faccar": [[9, "(function handle object :behavior process)"]],
|
||||
"wasstadb-obs": [[5, "(function object)"]],
|
||||
"arena-scenes": [
|
||||
[0, "(function none :behavior scene-player)"],
|
||||
[1, "(function none :behavior scene-player)"],
|
||||
[2, "(function none :behavior scene-player)"],
|
||||
[3, "(function none :behavior scene-player)"],
|
||||
[4, "(function none :behavior scene-player)"],
|
||||
[5, "(function none :behavior scene-player)"],
|
||||
[6, "(function none :behavior scene-player)"],
|
||||
[7, "(function none :behavior scene-player)"],
|
||||
[8, "(function none :behavior scene-player)"],
|
||||
[9, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"traffic-engine": [
|
||||
[24, "(function traffic-find-segment-struct nav-segment none)"]
|
||||
],
|
||||
"desert-scenes": [
|
||||
[5, "(function none :behavior scene-player)"],
|
||||
[6, "(function none :behavior scene-player)"],
|
||||
[7, "(function none :behavior scene-player)"],
|
||||
[8, "(function none :behavior scene-player)"],
|
||||
[9, "(function none :behavior scene-player)"],
|
||||
[10, "(function none :behavior scene-player)"],
|
||||
[11, "(function none :behavior scene-player)"],
|
||||
[12, "(function none :behavior scene-player)"],
|
||||
[13, "(function none :behavior scene-player)"],
|
||||
[14, "(function none :behavior scene-player)"],
|
||||
[15, "(function none :behavior scene-player)"],
|
||||
[16, "(function none :behavior scene-player)"],
|
||||
[17, "(function none :behavior scene-player)"],
|
||||
[18, "(function none :behavior scene-player)"],
|
||||
[19, "(function none :behavior scene-player)"],
|
||||
[20, "(function none :behavior scene-player)"],
|
||||
[21, "(function none :behavior scene-player)"],
|
||||
[22, "(function none :behavior scene-player)"],
|
||||
[23, "(function none :behavior scene-player)"],
|
||||
[24, "(function none :behavior scene-player)"],
|
||||
[25, "(function none :behavior scene-player)"],
|
||||
[26, "(function none :behavior scene-player)"],
|
||||
[27, "(function none :behavior scene-player)"],
|
||||
[28, "(function none :behavior scene-player)"],
|
||||
[29, "(function none :behavior scene-player)"],
|
||||
[30, "(function none :behavior scene-player)"],
|
||||
[31, "(function none :behavior scene-player)"],
|
||||
[32, "(function none :behavior scene-player)"],
|
||||
[33, "(function none :behavior scene-player)"],
|
||||
[34, "(function none :behavior scene-player)"],
|
||||
[35, "(function none :behavior scene-player)"],
|
||||
[36, "(function symbol :behavior scene-player)"]
|
||||
],
|
||||
"throne-scenes": [[0, "(function none :behavior scene-player)"]],
|
||||
"terraformer-setup": [[38, "(function object :behavior manipy)"]],
|
||||
"mined-scenes": [
|
||||
[6, "(function none :behavior scene-player)"],
|
||||
[7, "(function process-drawable vector none :behavior scene-player)"],
|
||||
[8, "(function process-drawable vector none :behavior scene-player)"]
|
||||
],
|
||||
"wasteland-scenes": [
|
||||
[0, "(function none :behavior scene-player)"],
|
||||
[1, "(function none :behavior scene-player)"],
|
||||
[2, "(function none :behavior scene-player)"],
|
||||
[3, "(function none :behavior scene-player)"],
|
||||
[4, "(function none :behavior scene-player)"],
|
||||
[5, "(function none :behavior scene-player)"],
|
||||
[6, "(function none :behavior scene-player)"],
|
||||
[7, "(function none :behavior scene-player)"],
|
||||
[8, "(function none :behavior scene-player)"],
|
||||
[9, "(function none :behavior scene-player)"],
|
||||
[10, "(function none :behavior scene-player)"]
|
||||
],
|
||||
"wasdoors-scenes": [[2, "(function none :behavior scene-player)"]],
|
||||
"wasdef-manager": [
|
||||
[7, "(function process-tree object)"],
|
||||
[8, "(function process-tree object)"],
|
||||
[9, "(function process-tree object)"]
|
||||
]
|
||||
}
|
||||
|
||||
@@ -15,7 +15,14 @@
|
||||
"lightjak-shield": "jakb-ag",
|
||||
"freeze-screen": "collectables-ag",
|
||||
"red-3-sphere": "gun-ag",
|
||||
"gun-dark-3-sphere": "gun-ag"
|
||||
"gun-dark-3-sphere": "gun-ag",
|
||||
"marauder": "marauder-male-ag",
|
||||
"glider-ring": "des-glider-ring-ag",
|
||||
"flut-racer": "flut-wild-ag",
|
||||
"was-pre-heart": "neo-satellite-heart-ag",
|
||||
"was-pre-beam": "neo-satellite-game-ring-ag",
|
||||
"was-pre-bubble": "neo-satellite-ps-symbols-ag",
|
||||
"maker": "dm-robot-ag"
|
||||
},
|
||||
|
||||
// remap names for types in an entire file (higher priority)
|
||||
|
||||
@@ -107,11 +107,8 @@
|
||||
// jak 3
|
||||
"(method 10 manipulator)",
|
||||
"(method 46 ff-squad-control)",
|
||||
"(anon-function 65 temple-obs)",
|
||||
"(method 33 task-manager-nest-cocoons)",
|
||||
"(method 33 rub-tower)",
|
||||
"(method 261 crimson-guard)",
|
||||
"(anon-function 25 volcanox-obs)",
|
||||
"memcpy"
|
||||
],
|
||||
|
||||
@@ -219,7 +216,14 @@
|
||||
"borrow-city-expansion",
|
||||
"add-want-level",
|
||||
"level-find-borrow-slot",
|
||||
"(method 18 level)"
|
||||
"(method 18 level)",
|
||||
"(method 11 tow-tentacle)",
|
||||
"city-sound-expand-want-list",
|
||||
"(method 12 cty-borrow-manager)",
|
||||
"(method 16 cty-borrow-manager)",
|
||||
"mark-permanent-holds",
|
||||
"update-sound-info",
|
||||
"insert-into-sound-list"
|
||||
],
|
||||
|
||||
// If format is used with the wrong number of arguments,
|
||||
@@ -414,7 +418,30 @@
|
||||
"(method 118 vehicle)": [3, 4, 7, 8, 9, 10, 17, 26, 30, 31, 33],
|
||||
"(method 25 squad-control)": [0, 4, 5, 7],
|
||||
"target-pilot-post": [0, 29],
|
||||
"(method 36 was-squad-control)": [0, 8, 11, 12, 14, 16]
|
||||
"(method 36 was-squad-control)": [0, 8, 14, 16],
|
||||
"(anon-function 6 nst-tasks)": [4, 9, 10, 16, 23, 30],
|
||||
"(method 33 task-manager-nest-cocoons)": [3, 7, 13, 28],
|
||||
"(method 90 wvehicle)": [29, 37, 38, 44],
|
||||
"(anon-function 2 artifact-race)": [40, 55, 56, 57, 65, 66],
|
||||
"(anon-function 27 course-race)": [6],
|
||||
"(anon-function 65 temple-obs)": [5, 6],
|
||||
"(anon-function 5 target-turret)": [0, 1, 2, 3],
|
||||
"dp-bipedal-consider-attacks": [15, 19],
|
||||
"(anon-function 25 volcanox-obs)": [3, 5, 6],
|
||||
"(method 36 task-manager-arena-fight-base)": [11],
|
||||
"(method 28 hud-wasgun)": [0, 1, 2, 4],
|
||||
"(method 15 hud-wasgun)": [8, 28, 29, 30, 54],
|
||||
"(method 15 vehicle-controller)": [0, 3, 5, 6, 7, 10],
|
||||
"(method 51 hvehicle)": [5],
|
||||
"(method 159 hvehicle)": [0, 1, 10, 19, 21, 23, 26],
|
||||
"(method 18 vehicle-controller)": [0, 1, 74, 75],
|
||||
"glider-too-low?": [2, 19, 21],
|
||||
"(method 39 task-manager-desert-glide)": [0, 3, 4, 9],
|
||||
"(method 36 task-manager-desert-glide)": [20, 50, 60],
|
||||
"(method 37 task-manager-desert-glide)": [11, 12, 23, 29, 31],
|
||||
"(method 34 task-manager-desert-glide)": [3],
|
||||
"(anon-function 20 target-flut)": [0, 38, 39],
|
||||
"(anon-function 14 flut-racer)": [7, 17, 19]
|
||||
},
|
||||
|
||||
// Sometimes the game might use format strings that are fetched dynamically,
|
||||
@@ -448,7 +475,47 @@
|
||||
[68, 1],
|
||||
[101, 1],
|
||||
[130, 1]
|
||||
]
|
||||
],
|
||||
"(method 32 task-manager-desert-turtle-training)": [[59, 1]],
|
||||
"(method 24 race-manager)": [[97, 1]],
|
||||
"(method 25 race-manager)": [
|
||||
[97, 1],
|
||||
[126, 1]
|
||||
],
|
||||
"(method 15 hud-race-final-stats)": [[131, 0]],
|
||||
"(method 15 hud-wasbbv-goal-time)": [[74, 0]],
|
||||
"(method 32 task-manager-lightjak-training)": [[53, 0]],
|
||||
"(method 18 hover-training-manager)": [[69, 0]],
|
||||
"(method 37 task-manager-arena-training)": [[67, 1]],
|
||||
"(method 15 hud-arena-final-stats)": [
|
||||
[103, 0],
|
||||
[147, 0]
|
||||
],
|
||||
"(method 35 task-manager-arena-fight-base)": [[53, 0]],
|
||||
"(method 32 task-manager-arena-gun-training)": [[53, 0]],
|
||||
"(method 26 task-manager-arena-fight-2)": [
|
||||
[72, 0],
|
||||
[186, 0]
|
||||
],
|
||||
"(method 37 task-manager-wascity-gungame)": [
|
||||
[48, 0],
|
||||
[78, 0],
|
||||
[119, 0],
|
||||
[157, 0],
|
||||
[195, 0],
|
||||
[227, 0],
|
||||
[268, 0],
|
||||
[306, 0],
|
||||
[338, 0],
|
||||
[379, 0],
|
||||
[411, 0],
|
||||
[446, 0]
|
||||
],
|
||||
"(method 30 was-pre-game)": [
|
||||
[184, 0],
|
||||
[276, 0]
|
||||
],
|
||||
"(method 32 task-manager-throne-gun-training)": [[53, 0]]
|
||||
},
|
||||
|
||||
"mips2c_functions_by_name": [
|
||||
|
||||
@@ -36,60 +36,60 @@
|
||||
// // desert
|
||||
// "DGO/DESA.DGO",
|
||||
"DGO/DESB.DGO",
|
||||
// "DGO/DESBATTL.DGO",
|
||||
"DGO/DESBATTL.DGO",
|
||||
// "DGO/DESBCST.DGO",
|
||||
// "DGO/DESBOSS1.DGO",
|
||||
// "DGO/DESBOSS2.DGO",
|
||||
"DGO/DESBOSS1.DGO",
|
||||
"DGO/DESBOSS2.DGO",
|
||||
// "DGO/DESC.DGO",
|
||||
// "DGO/DESCHASE.DGO",
|
||||
// "DGO/DESD.DGO",
|
||||
"DGO/DESCHASE.DGO",
|
||||
"DGO/DESD.DGO",
|
||||
// "DGO/DESE.DGO",
|
||||
// "DGO/DESERROL.DGO",
|
||||
// "DGO/DESF.DGO",
|
||||
// "DGO/DESG.DGO",
|
||||
"DGO/DESF.DGO",
|
||||
"DGO/DESG.DGO",
|
||||
// "DGO/DESH.DGO",
|
||||
// "DGO/DESHOVER.DGO",
|
||||
"DGO/DESHOVER.DGO",
|
||||
// "DGO/DESHUNT.DGO",
|
||||
"DGO/DESINTER.DGO",
|
||||
// "DGO/DESJUMP.DGO",
|
||||
// "DGO/DESLIZ.DGO",
|
||||
"DGO/DESLIZ.DGO",
|
||||
// "DGO/DESOASIS.DGO",
|
||||
// "DGO/DESRACE1.DGO",
|
||||
"DGO/DESRACE1.DGO",
|
||||
// "DGO/DESRACE2.DGO",
|
||||
// "DGO/DESRALLY.DGO",
|
||||
"DGO/DESRALLY.DGO",
|
||||
// "DGO/DESRESC.DGO",
|
||||
// "DGO/DESRESCC.DGO",
|
||||
// "DGO/DESRESCG.DGO",
|
||||
// "DGO/DESTRACK.DGO",
|
||||
// "DGO/DESW.DGO",
|
||||
"DGO/DESW.DGO",
|
||||
"DGO/DST.DGO",
|
||||
// "DGO/OASISCST.DGO",
|
||||
// "DGO/WARPCAST.DGO", // air train
|
||||
// // nest
|
||||
// "DGO/NSA.DGO",
|
||||
// "DGO/NSB.DGO",
|
||||
// // temple
|
||||
// "DGO/TEMA.DGO",
|
||||
// "DGO/TEMB.DGO",
|
||||
// "DGO/TEMC.DGO",
|
||||
// "DGO/TEMD.DGO",
|
||||
// "DGO/TEMP.DGO",
|
||||
// "DGO/TEMPLEE.DGO",
|
||||
// "DGO/TEMX.DGO",
|
||||
// // hang
|
||||
// "DGO/HGA.DGO",
|
||||
// "DGO/HGB.DGO",
|
||||
// // volcano
|
||||
// "DGO/VOCA.DGO",
|
||||
// "DGO/VOCX.DGO",
|
||||
// nest
|
||||
"DGO/NSA.DGO",
|
||||
"DGO/NSB.DGO",
|
||||
// temple
|
||||
"DGO/TEMA.DGO",
|
||||
"DGO/TEMB.DGO",
|
||||
"DGO/TEMC.DGO",
|
||||
"DGO/TEMD.DGO",
|
||||
"DGO/TEMP.DGO",
|
||||
"DGO/TEMPLEE.DGO",
|
||||
"DGO/TEMX.DGO",
|
||||
// hang
|
||||
"DGO/HGA.DGO",
|
||||
"DGO/HGB.DGO",
|
||||
// volcano
|
||||
"DGO/VOCA.DGO",
|
||||
"DGO/VOCX.DGO",
|
||||
// mine
|
||||
"DGO/MIA.DGO",
|
||||
"DGO/MIB.DGO",
|
||||
"DGO/MIC.DGO",
|
||||
"DGO/MINED.DGO",
|
||||
"DGO/MINEE.DGO",
|
||||
// // city
|
||||
// "DGO/CWI.DGO", // ctywide
|
||||
// city
|
||||
"DGO/CWI.DGO", // ctywide
|
||||
// "DGO/CFA.DGO", // ctyfarm
|
||||
// "DGO/CFB.DGO",
|
||||
// "DGO/CGB.DGO", // ctygen
|
||||
@@ -137,11 +137,11 @@
|
||||
// "DGO/SEM.DGO",
|
||||
// "DGO/SEN.DGO",
|
||||
// "DGO/SEO.DGO",
|
||||
// // mhcity
|
||||
// "DGO/MHCA.DGO",
|
||||
// "DGO/MHCB.DGO",
|
||||
// "DGO/MHCTYCST.DGO",
|
||||
// // forest
|
||||
// mhcity
|
||||
"DGO/MHCA.DGO",
|
||||
"DGO/MHCB.DGO",
|
||||
"DGO/MHCTYCST.DGO",
|
||||
// forest
|
||||
"DGO/FRSTA.DGO",
|
||||
"DGO/FRSTB.DGO",
|
||||
"DGO/FRSTX.DGO",
|
||||
@@ -150,15 +150,15 @@
|
||||
// "DGO/FACB.DGO",
|
||||
// "DGO/FACC.DGO",
|
||||
// "DGO/FACD.DGO",
|
||||
// // tower
|
||||
// "DGO/TOWB.DGO",
|
||||
// "DGO/TOWERA.DGO",
|
||||
// "DGO/TOWERC.DGO",
|
||||
// tower
|
||||
"DGO/TOWB.DGO",
|
||||
"DGO/TOWERA.DGO",
|
||||
"DGO/TOWERC.DGO",
|
||||
// "DGO/TOWERCST.DGO",
|
||||
// // stadium
|
||||
// "DGO/STA.DGO",
|
||||
// "DGO/STAA.DGO",
|
||||
// "DGO/STB.DGO",
|
||||
// stadium
|
||||
"DGO/STA.DGO",
|
||||
"DGO/STAA.DGO",
|
||||
"DGO/STB.DGO",
|
||||
// // rubble
|
||||
// "DGO/RUBA.DGO",
|
||||
// "DGO/RUBA2.DGO",
|
||||
@@ -247,14 +247,14 @@
|
||||
// "DGO/LDMPCKGN.DGO",
|
||||
// "DGO/LERROL.DGO",
|
||||
// "DGO/LFACB.DGO",
|
||||
// "DGO/LFACCAR.DGO",
|
||||
// "DGO/LFACCITY.DGO",
|
||||
// "DGO/LFACO.DGO",
|
||||
"DGO/LFACCAR.DGO",
|
||||
"DGO/LFACCITY.DGO",
|
||||
"DGO/LFACO.DGO",
|
||||
// "DGO/LFACRM1.DGO",
|
||||
// "DGO/LFACRM2.DGO",
|
||||
// "DGO/LFACTORY.DGO",
|
||||
// "DGO/LFORM.DGO",
|
||||
// "DGO/LFORP.DGO",
|
||||
"DGO/LFORM.DGO",
|
||||
"DGO/LFORP.DGO",
|
||||
// "DGO/LFORRING.DGO",
|
||||
// "DGO/LFREEOUT.DGO",
|
||||
// "DGO/LGUNNORM.DGO",
|
||||
@@ -272,7 +272,7 @@
|
||||
// "DGO/LJKFEET.DGO",
|
||||
// "DGO/LJNDKLEV.DGO",
|
||||
// "DGO/LKEIRA.DGO",
|
||||
// "DGO/LKLEEVER.DGO",
|
||||
"DGO/LKLEEVER.DGO",
|
||||
"DGO/LMECH.DGO",
|
||||
// "DGO/LMHCA.DGO",
|
||||
// "DGO/LMHCB.DGO",
|
||||
@@ -306,7 +306,7 @@
|
||||
// "DGO/LTRTWHLS.DGO",
|
||||
// "DGO/LVINCST.DGO",
|
||||
// "DGO/LWASBBV.DGO",
|
||||
// "DGO/LWASSIG.DGO",
|
||||
"DGO/LWASSIG.DGO",
|
||||
// "DGO/LWLANDM.DGO",
|
||||
"DGO/LWSTDPCK.DGO"
|
||||
],
|
||||
|
||||
@@ -961,5 +961,434 @@
|
||||
"part-tester": [
|
||||
["L49", "uint64", true],
|
||||
["L44", "uint64", true]
|
||||
],
|
||||
"des-beast": [
|
||||
["L214", "attack-info"],
|
||||
["L190", "attack-info"],
|
||||
["L189", "attack-info"]
|
||||
],
|
||||
"sig-rider": [["L46", "attack-info"]],
|
||||
"nst-eggs-h": [["L1", "(inline-array talker-speech-class)", 54]],
|
||||
"nst-obs": [
|
||||
["L739", "uint64", true],
|
||||
["L733", "uint64", true],
|
||||
["L741", "uint64", true],
|
||||
["L742", "uint64", true],
|
||||
["L740", "uint64", true],
|
||||
["L735", "uint64", true],
|
||||
["L738", "uint64", true],
|
||||
["L736", "uint64", true],
|
||||
["L734", "uint64", true],
|
||||
["L737", "uint64", true],
|
||||
["L632", "uint64", true],
|
||||
["L638", "uint64", true],
|
||||
["L633", "uint64", true],
|
||||
["L640", "uint64", true],
|
||||
["L631", "uint64", true],
|
||||
["L643", "uint64", true],
|
||||
["L634", "uint64", true],
|
||||
["L644", "uint64", true],
|
||||
["L637", "uint64", true],
|
||||
["L639", "uint64", true],
|
||||
["L635", "uint64", true],
|
||||
["L641", "uint64", true],
|
||||
["L636", "uint64", true],
|
||||
["L642", "uint64", true]
|
||||
],
|
||||
"nst-gas": [["L110", "resetter-params"]],
|
||||
"egg-spider": [["L231", "attack-info"]],
|
||||
"wcar-marauder": [
|
||||
["L68", "vector"],
|
||||
["L67", "vector"],
|
||||
["L66", "vector"],
|
||||
["L65", "vector"],
|
||||
["L64", "vector"],
|
||||
["L63", "vector"],
|
||||
["L62", "vector"],
|
||||
["L61", "vector"],
|
||||
["L69", "vector"]
|
||||
],
|
||||
"wcar-marauder-b": [
|
||||
["L55", "vehicle-damage-info"],
|
||||
["L53", "vehicle-setup-info"],
|
||||
["L30", "vector"],
|
||||
["L29", "vector"],
|
||||
["L28", "vector"],
|
||||
["L27", "vector"],
|
||||
["L26", "vector"],
|
||||
["L25", "vector"],
|
||||
["L24", "vector"],
|
||||
["L23", "vector"],
|
||||
["L22", "vector"]
|
||||
],
|
||||
"wasdoors-init": [
|
||||
["L41", "vector"],
|
||||
["L40", "vector"]
|
||||
],
|
||||
"des-cactus": [
|
||||
["L130", "vector"],
|
||||
["L129", "vector"],
|
||||
["L128", "vector"]
|
||||
],
|
||||
"desertg-obs": [
|
||||
["L45", "attack-info"],
|
||||
["L44", "attack-info"]
|
||||
],
|
||||
"desertf-obs": [["L99", "(inline-array vector)", 2]],
|
||||
"desert-dust-storm": [["L89", "vector"]],
|
||||
"artifact-race": [
|
||||
["L162", "(inline-array talker-speech-class)", 16],
|
||||
["L160", "vector"],
|
||||
["L159", "vector"],
|
||||
["L158", "vector"],
|
||||
["L157", "vector"]
|
||||
],
|
||||
"turtle-training": [
|
||||
["L154", "vector"],
|
||||
["L153", "vector"],
|
||||
["L152", "vector"]
|
||||
],
|
||||
"course-race": [
|
||||
["L232", "(inline-array vector)", 2],
|
||||
["L288", "vector"],
|
||||
["L287", "vector"],
|
||||
["L286", "vector"]
|
||||
],
|
||||
"flyingsaw": [["L36", "attack-info"]],
|
||||
"temple-obs": [
|
||||
["L595", "uint64", true],
|
||||
["L606", "uint64", true],
|
||||
["L596", "uint64", true],
|
||||
["L603", "uint64", true],
|
||||
["L605", "uint64", true],
|
||||
["L597", "uint64", true],
|
||||
["L601", "uint64", true],
|
||||
["L599", "uint64", true],
|
||||
["L604", "uint64", true],
|
||||
["L600", "uint64", true],
|
||||
["L602", "uint64", true],
|
||||
["L598", "uint64", true],
|
||||
["L470", "uint64", true],
|
||||
["L474", "uint64", true],
|
||||
["L483", "uint64", true],
|
||||
["L485", "uint64", true],
|
||||
["L482", "uint64", true],
|
||||
["L480", "uint64", true],
|
||||
["L471", "uint64", true],
|
||||
["L406", "attack-info"],
|
||||
["L475", "uint64", true],
|
||||
["L476", "uint64", true],
|
||||
["L484", "uint64", true],
|
||||
["L472", "uint64", true],
|
||||
["L395", "attack-info"],
|
||||
["L479", "uint64", true],
|
||||
["L478", "uint64", true],
|
||||
["L481", "uint64", true],
|
||||
["L477", "uint64", true],
|
||||
["L473", "uint64", true]
|
||||
],
|
||||
"temple-obs2": [
|
||||
["L514", "uint64", true],
|
||||
["L516", "uint64", true],
|
||||
["L517", "uint64", true],
|
||||
["L522", "uint64", true],
|
||||
["L521", "uint64", true],
|
||||
["L519", "uint64", true],
|
||||
["L515", "uint64", true],
|
||||
["L513", "uint64", true],
|
||||
["L520", "uint64", true],
|
||||
["L518", "uint64", true],
|
||||
["L428", "uint64", true],
|
||||
["L429", "uint64", true],
|
||||
["L433", "uint64", true],
|
||||
["L432", "uint64", true],
|
||||
["L427", "uint64", true],
|
||||
["L431", "uint64", true],
|
||||
["L430", "uint64", true],
|
||||
["L338", "attack-info"],
|
||||
["L434", "uint64", true],
|
||||
["L378", "attack-info"],
|
||||
["L426", "uint64", true]
|
||||
],
|
||||
"temple-mood": [["L14", "vector"]],
|
||||
"tomb-baby-spider": [["L73", "attack-info"]],
|
||||
"templex-mood": [["L8", "vector"]],
|
||||
"scorpion-gun": [
|
||||
["L460", "(inline-array talker-speech-class)", 59],
|
||||
["L447", "vector"]
|
||||
],
|
||||
"mh-flyer": [["L159", "attack-info"]],
|
||||
"target-turret-shot": [["L22", "attack-info"]],
|
||||
"target-turret": [
|
||||
["L405", "attack-info"],
|
||||
["L397", "attack-info"],
|
||||
["L395", "attack-info"],
|
||||
["L389", "target-turret-info"]
|
||||
],
|
||||
"flamer-hover": [
|
||||
["L86", "vector"],
|
||||
["L85", "vector"],
|
||||
["L84", "vector"],
|
||||
["L92", "(pointer uint64)", 3],
|
||||
["L91", "(pointer int32)", 4]
|
||||
],
|
||||
"robo-hover": [
|
||||
["L174", "vector"],
|
||||
["L173", "vector"],
|
||||
["L172", "vector"]
|
||||
],
|
||||
"forest-mood": [["L14", "(inline-array vector4)", 3]],
|
||||
"forest-tasks": [["L904", "vector"]],
|
||||
"mh-plant": [["L111", "attack-info"]],
|
||||
"forest-ring-chase": [["L343", "vector"]],
|
||||
"dp-bipedal": [
|
||||
["L638", "uint64", true],
|
||||
["L636", "uint64", true],
|
||||
["L639", "uint64", true],
|
||||
["L637", "uint64", true],
|
||||
["L581", "uint64", true],
|
||||
["L580", "uint64", true],
|
||||
["L576", "uint64", true],
|
||||
["L579", "uint64", true],
|
||||
["L577", "uint64", true],
|
||||
["L468", "vector"],
|
||||
["L467", "vector"],
|
||||
["L578", "uint64", true],
|
||||
["L575", "uint64", true]
|
||||
],
|
||||
"neo-wasp": [
|
||||
["L181", "vector"],
|
||||
["L180", "vector"],
|
||||
["L179", "vector"]
|
||||
],
|
||||
"neo-spawner": [["L174", "vector"]],
|
||||
"for-turret": [["L256", "target-turret-info"]],
|
||||
"flitter": [
|
||||
["L154", "vector"],
|
||||
["L153", "vector"]
|
||||
],
|
||||
"target-indax": [["L379", "attack-info"]],
|
||||
"volcano-obs": [
|
||||
["L218", "attack-info"],
|
||||
["L252", "attack-info"],
|
||||
["L232", "attack-info"]
|
||||
],
|
||||
"flamer-lava": [
|
||||
["L196", "vector"],
|
||||
["L195", "vector"],
|
||||
["L194", "vector"],
|
||||
["L202", "(pointer int64)", 3],
|
||||
["L201", "(pointer int32)", 4]
|
||||
],
|
||||
"dm-mine-spider": [["L175", "attack-info"]],
|
||||
"spyder": [
|
||||
["L186", "(inline-array ik-limb-setup)", 4],
|
||||
["L176", "vector"],
|
||||
["L175", "vector"],
|
||||
["L188", "(pointer int64)", 3],
|
||||
["L187", "(pointer int32)", 4]
|
||||
],
|
||||
"rapid-gunner": [
|
||||
["L124", "vector"],
|
||||
["L123", "vector"]
|
||||
],
|
||||
"kanga-lizard": [["L276", "(inline-array talker-speech-class)", 33]],
|
||||
"stadium-obs": [
|
||||
["L212", "uint64", true],
|
||||
["L210", "uint64", true],
|
||||
["L209", "uint64", true],
|
||||
["L211", "uint64", true],
|
||||
["L208", "uint64", true],
|
||||
["L173", "uint64", true],
|
||||
["L174", "uint64", true],
|
||||
["L175", "uint64", true],
|
||||
["L176", "uint64", true]
|
||||
],
|
||||
"wcar-faccar": [
|
||||
["L51", "vector"],
|
||||
["L50", "vector"],
|
||||
["L49", "vector"],
|
||||
["L48", "vector"],
|
||||
["L47", "vector"],
|
||||
["L46", "vector"],
|
||||
["L45", "vector"],
|
||||
["L44", "vector"],
|
||||
["L43", "vector"]
|
||||
],
|
||||
"wasstadb-obs": [
|
||||
["L261", "(pointer uint64)", 2],
|
||||
["L252", "vector"]
|
||||
],
|
||||
"wasstadc-obs": [
|
||||
["L984", "uint64", true],
|
||||
["L1104", "uint64", true],
|
||||
["L1107", "uint64", true],
|
||||
["L1108", "uint64", true],
|
||||
["L1105", "uint64", true],
|
||||
["L1103", "uint64", true],
|
||||
["L1101", "uint64", true],
|
||||
["L1100", "uint64", true],
|
||||
["L1097", "uint64", true],
|
||||
["L1102", "uint64", true],
|
||||
["L1098", "uint64", true],
|
||||
["L1099", "uint64", true],
|
||||
["L1106", "uint64", true],
|
||||
["L982", "uint64", true],
|
||||
["L987", "uint64", true],
|
||||
["L981", "uint64", true],
|
||||
["L980", "uint64", true],
|
||||
["L988", "uint64", true],
|
||||
["L979", "uint64", true],
|
||||
["L986", "uint64", true],
|
||||
["L983", "uint64", true],
|
||||
["L985", "uint64", true],
|
||||
["L978", "vector"],
|
||||
["L851", "vector"],
|
||||
["L843", "vector"],
|
||||
["L825", "vector"],
|
||||
["L823", "vector"],
|
||||
["L822", "vector"],
|
||||
["L821", "vector"],
|
||||
["L820", "vector"],
|
||||
["L819", "vector"],
|
||||
["L810", "vector"],
|
||||
["L809", "vector"]
|
||||
],
|
||||
"wascity-turret-shot": [["L49", "attack-info"]],
|
||||
"dm-flyer": [["L80", "attack-info"]],
|
||||
"maker-projectile": [["L51", "attack-info"]],
|
||||
"wascity-turret": [
|
||||
["L284", "vector"],
|
||||
["L283", "vector"],
|
||||
["L339", "(inline-array talker-speech-class)", 4],
|
||||
["L290", "target-turret-info"]
|
||||
],
|
||||
"hvehicle": [
|
||||
["L200", "attack-info"],
|
||||
["L204", "attack-info"]
|
||||
],
|
||||
"glider-manager": [
|
||||
["L276", "(inline-array glider-ring-info)", 80],
|
||||
["L275", "(pointer handle)", 128],
|
||||
["L216", "(inline-array glider-thermal-info)", 16]
|
||||
],
|
||||
"was-pre-game": [
|
||||
["L723", "uint64", true],
|
||||
["L719", "uint64", true],
|
||||
["L724", "uint64", true],
|
||||
["L721", "uint64", true],
|
||||
["L722", "uint64", true],
|
||||
["L718", "uint64", true],
|
||||
["L720", "uint64", true],
|
||||
["L636", "uint64", true],
|
||||
["L627", "uint64", true],
|
||||
["L632", "uint64", true],
|
||||
["L621", "uint64", true],
|
||||
["L619", "uint64", true],
|
||||
["L623", "uint64", true],
|
||||
["L630", "uint64", true],
|
||||
["L629", "uint64", true],
|
||||
["L620", "uint64", true],
|
||||
["L633", "uint64", true],
|
||||
["L635", "uint64", true],
|
||||
["L626", "uint64", true],
|
||||
["L628", "uint64", true],
|
||||
["L631", "uint64", true],
|
||||
["L622", "uint64", true],
|
||||
["L625", "uint64", true],
|
||||
["L624", "uint64", true],
|
||||
["L634", "uint64", true]
|
||||
],
|
||||
"was-leaper-race": [["L204", "(inline-array talker-speech-class)", 21]],
|
||||
"desert-lizard-h": [["L1", "(inline-array talker-speech-class)", 50]],
|
||||
"desert-lizard-task": [
|
||||
["L203", "resetter-params"],
|
||||
["L201", "resetter-params"],
|
||||
["L199", "resetter-params"]
|
||||
],
|
||||
"desert-scenes": [["L4037", "sphere"]],
|
||||
"deswalk-obs": [
|
||||
["L388", "attack-info"],
|
||||
["L424", "attack-info"],
|
||||
["L428", "attack-info"],
|
||||
["L427", "attack-info"],
|
||||
["L474", "attack-info"],
|
||||
["L473", "attack-info"]
|
||||
],
|
||||
"terraformer-setup": [
|
||||
["L732", "uint64", true],
|
||||
["L745", "uint64", true],
|
||||
["L739", "uint64", true],
|
||||
["L731", "uint64", true],
|
||||
["L734", "uint64", true],
|
||||
["L736", "uint64", true],
|
||||
["L742", "uint64", true],
|
||||
["L733", "uint64", true],
|
||||
["L738", "uint64", true],
|
||||
["L735", "uint64", true],
|
||||
["L737", "uint64", true],
|
||||
["L744", "uint64", true],
|
||||
["L740", "uint64", true],
|
||||
["L741", "uint64", true],
|
||||
["L743", "uint64", true],
|
||||
["L600", "uint64", true],
|
||||
["L597", "uint64", true],
|
||||
["L599", "uint64", true],
|
||||
["L596", "uint64", true],
|
||||
["L595", "uint64", true],
|
||||
["L504", "attack-info"],
|
||||
["L601", "uint64", true],
|
||||
["L522", "vector"],
|
||||
["L594", "uint64", true],
|
||||
["L598", "uint64", true],
|
||||
["L593", "uint64", true]
|
||||
],
|
||||
"terraformer-head": [
|
||||
["L500", "attack-info"],
|
||||
["L502", "vector"],
|
||||
["L508", "vector"],
|
||||
["L507", "vector"],
|
||||
["L509", "vector"]
|
||||
],
|
||||
"ocean-texture": [
|
||||
["L55", "vector4w"],
|
||||
["L56", "vector"]
|
||||
],
|
||||
"wasteland-scenes": [
|
||||
["L307", "sphere"],
|
||||
["L442", "sphere"],
|
||||
["L530", "sphere"],
|
||||
["L742", "sphere"],
|
||||
["L966", "sphere"],
|
||||
["L975", "sphere"],
|
||||
["L1221", "sphere"],
|
||||
["L1234", "sphere"],
|
||||
["L1662", "sphere"],
|
||||
["L1910", "sphere"]
|
||||
],
|
||||
"wasdoors-scenes": [["L649", "vector"]],
|
||||
"wasdef-manager": [
|
||||
["L750", "uint64", true],
|
||||
["L751", "uint64", true],
|
||||
["L748", "uint64", true],
|
||||
["L749", "uint64", true],
|
||||
["L576", "(inline-array talker-speech-class)", 33],
|
||||
["L612", "uint64", true],
|
||||
["L615", "uint64", true],
|
||||
["L626", "uint64", true],
|
||||
["L619", "uint64", true],
|
||||
["L616", "uint64", true],
|
||||
["L622", "uint64", true],
|
||||
["L623", "uint64", true],
|
||||
["L620", "uint64", true],
|
||||
["L625", "uint64", true],
|
||||
["L627", "uint64", true],
|
||||
["L614", "uint64", true],
|
||||
["L618", "uint64", true],
|
||||
["L472", "vector4w"],
|
||||
["L617", "uint64", true],
|
||||
["L624", "uint64", true],
|
||||
["L613", "uint64", true],
|
||||
["L621", "uint64", true]
|
||||
]
|
||||
}
|
||||
|
||||
@@ -3,5 +3,7 @@
|
||||
"(method 29 target)": 2048,
|
||||
"(method 11 part-spawner)": 64,
|
||||
"(method 11 elevator)": 1024,
|
||||
"scene-player-init": 1024
|
||||
"scene-player-init": 1024,
|
||||
"task-manager-init-by-other": 2048,
|
||||
"race-manager-init-by-other": 1024
|
||||
}
|
||||
|
||||
@@ -1127,7 +1127,7 @@
|
||||
[640, "matrix"]
|
||||
],
|
||||
"(code target-pilot-get-off)": [[96, "matrix"]],
|
||||
"target-pilot-trans": [[16, "matrix"]],
|
||||
"target-pilot-trans": [[16, ["inline-array", "vector", 10]]],
|
||||
"(method 34 was-squad-control)": [
|
||||
[16, "cquery-with-vec"],
|
||||
[576, ["inline-array", "vector", 2]],
|
||||
@@ -1175,5 +1175,564 @@
|
||||
[64, ["inline-array", "quaternion", 2]]
|
||||
],
|
||||
"(method 17 turret-control)": [[16, "turret-control-stack-var0"]],
|
||||
"(method 9 turret-control)": [[16, "turret-control-stack-var1"]]
|
||||
"(method 9 turret-control)": [
|
||||
[16, "turret-control-stack-var1"],
|
||||
[272, "collide-query"]
|
||||
],
|
||||
"(code idle des-beast)": [[16, "vector"]],
|
||||
"des-beast-gun-swivel-callback": [
|
||||
[16, "vector"],
|
||||
[80, "vector"]
|
||||
],
|
||||
"(trans idle beast-rider)": [[16, "vector"]],
|
||||
"(method 31 beast-grenade)": [
|
||||
[16, "light-trail-tracker-spawn-params"],
|
||||
[48, "vector"]
|
||||
],
|
||||
"des-beast-gun-callback": [
|
||||
[32, "vector"],
|
||||
[80, "vector"]
|
||||
],
|
||||
"(method 84 des-beast)": [[176, "vector"]],
|
||||
"(method 167 des-beast)": [[32, ["array", "collide-shape", 64]]],
|
||||
"(method 164 des-beast)": [
|
||||
[48, "vector"],
|
||||
[176, "vector"]
|
||||
],
|
||||
"sig-pilot-trans": [[16, "matrix"]],
|
||||
"update-nst-lights": [
|
||||
[32, "vector"],
|
||||
[48, "vector"]
|
||||
],
|
||||
"(code notice nst-cocoon-a)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(code die nst-metalhead-eggs)": [[16, "vector"]],
|
||||
"birth-func-find-ground": [
|
||||
[16, "collide-query"],
|
||||
[560, "vector"]
|
||||
],
|
||||
"spt-func-check-hit-ground": [[16, "vector"]],
|
||||
"part-nest-bat1-path": [[80, "vector"]],
|
||||
"part-nest-bat2-path": [[80, "vector"]],
|
||||
"part-nest-bat3-path": [[80, "vector"]],
|
||||
"part-nest-bat4-path": [[80, "vector"]],
|
||||
"part-nest-bat5-path": [[80, "vector"]],
|
||||
"part-nest-bat6-path": [[80, "vector"]],
|
||||
"part-nest-bat7-path": [[80, "vector"]],
|
||||
"part-nest-bat8-path": [[80, "vector"]],
|
||||
"part-nest-bat9-path": [[80, "vector"]],
|
||||
"part-nest-bat10-path": [[80, "vector"]],
|
||||
"(method 160 egg-spider)": [[16, "vector"]],
|
||||
"(method 194 egg-spider)": [
|
||||
[32, "vector"],
|
||||
[80, "vector"]
|
||||
],
|
||||
"(trans jump-on-vehicle egg-spider)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"],
|
||||
[48, "vector"],
|
||||
[64, "vector"],
|
||||
[80, "vector"]
|
||||
],
|
||||
"(trans on-vehicle egg-spider)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(trans idle spider-manager)": [
|
||||
[160, "enemy-init-by-other-params"],
|
||||
[48, "vector"],
|
||||
[16, "vector"]
|
||||
],
|
||||
"(method 24 spider-manager)": [[16, "cquery-with-vec"]],
|
||||
"(method 25 spider-manager)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"],
|
||||
[48, "vector"],
|
||||
[64, "nav-poly"],
|
||||
[112, "vector"],
|
||||
[128, "vector"]
|
||||
],
|
||||
"check-drop-level-egg-spider-dirt-rubble": [[16, "vector"]],
|
||||
"vehicle-draw-laser": [[32, "vector"]],
|
||||
"vehicle-draw-beam": [[32, "vector"]],
|
||||
"(method 30 v-marauder)": [[16, "vector"]],
|
||||
"(method 79 v-marauder)": [[16, ["inline-array", "quaternion", 3]]],
|
||||
"(method 90 v-marauder)": [
|
||||
[16, "wcar-marauder-stack-var0"],
|
||||
[48, ["inline-array", "vector", 1]],
|
||||
[144, "wcar-marauder-stack-var0"],
|
||||
[160, "wcar-marauder-stack-var0"],
|
||||
[192, "wcar-marauder-stack-var0"]
|
||||
],
|
||||
"(method 79 v-marauder-b)": [[16, ["inline-array", "quaternion", 3]]],
|
||||
"wasdoors-point-inside?": [[16, ["inline-array", "vector", 3]]],
|
||||
"tizard-tilt-jmod-func": [[16, "quaternion"]],
|
||||
"(method 34 tizard)": [
|
||||
[16, "collide-query"],
|
||||
[560, ["inline-array", "sphere", 2]]
|
||||
],
|
||||
"(method 90 wvehicle)": [[16, "wvehicle-physics-work"]],
|
||||
"(method 30 des-plant)": [
|
||||
[16, "vector"],
|
||||
[32, ["inline-array", "quaternion", 10]]
|
||||
],
|
||||
"(event idle des-cactus-obstacle)": [[96, "vector"]],
|
||||
"(code idle was-artifact)": [[64, "vector"]],
|
||||
"(method 23 was-artifact)": [[16, "cquery-with-vec"]],
|
||||
"(method 25 was-artifact)": [[16, "matrix"]],
|
||||
"(code active task-manager-desert-artifact-race)": [
|
||||
[144, "matrix"],
|
||||
[96, ["inline-array", "task-arrow-params", 1]]
|
||||
],
|
||||
"(method 20 race-manager)": [[16, ["inline-array", "vector", 5]]],
|
||||
"(method 9 racer-state)": [
|
||||
[16, "matrix3"],
|
||||
[48, "race-mesh-slice-query"],
|
||||
[160, ["inline-array", "vector", 1]]
|
||||
],
|
||||
"(method 12 race-state)": [[16, ["array", "float", 10]]],
|
||||
"(method 15 race-state)": [[16, "matrix"]],
|
||||
"(method 17 race-state)": [[16, "race-manager-stack-var0"]],
|
||||
"(method 19 race-state)": [[96, "matrix"]],
|
||||
"(method 21 race-manager)": [[16, "race-manager-stack-var1"]],
|
||||
"(method 15 hud-race-timer)": [[16, ["array", "time-frame", 5]]],
|
||||
"(method 182 wvehicle)": [[16, ["inline-array", "vector", 1]]],
|
||||
"(method 177 wvehicle)": [[16, "wvehicle-race-stack-var0"]],
|
||||
"(method 185 wvehicle)": [[16, ["inline-array", "vector", 1]]],
|
||||
"(method 181 wvehicle)": [
|
||||
[16, "wvehicle-physics-work"],
|
||||
[1552, "wvehicle-physics-work"]
|
||||
],
|
||||
"(method 180 wvehicle)": [[16, ["array", "int8", 16]]],
|
||||
"kleever-pilot-trans": [[16, "kleever-rider-stack-var0"]],
|
||||
"wland-driver-pilot-trans": [[16, "kleever-rider-stack-var0"]],
|
||||
"(method 33 task-manager-race)": [[16, "course-race-stack-var0"]],
|
||||
"(method 22 tpl-elec-swing-pole)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(trans go-door tpl-token)": [
|
||||
[96, ["inline-array", "vector", 16]],
|
||||
[352, ["inline-array", "vector", 16]],
|
||||
[688, "vector"]
|
||||
],
|
||||
"(method 164 des-beast-2)": [[32, "vector"]],
|
||||
"(post hostile des-beast-2)": [
|
||||
[112, ["inline-array", "vector", 16]],
|
||||
[96, "vector"],
|
||||
[464, "vector"],
|
||||
[480, "vector"],
|
||||
[560, ["inline-array", "vector", 2]]
|
||||
],
|
||||
"(method 31 beast-grenade-2)": [[16, "light-trail-tracker-spawn-params"]],
|
||||
"(anon-function 2 des-beast-2)": [[16, "matrix"]],
|
||||
"(anon-function 1 des-beast-2)": [[16, "matrix"]],
|
||||
"(method 26 scorpion-gun-shot)": [[32, "vector"]],
|
||||
"(post active scorpion-gun-manager)": [
|
||||
[16, ["inline-array", "vector", 1]],
|
||||
[32, ["inline-array", "vector", 2]]
|
||||
],
|
||||
"control-post": [[16, "quaternion"]],
|
||||
"(code cam-scorpion-gun)": [[16, "event-message-block"]],
|
||||
"(method 157 mh-flyer)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"mh-flyer-fly-post": [
|
||||
[576, "vector"],
|
||||
[640, ["inline-array", "vector", 2]]
|
||||
],
|
||||
"(method 31 mh-flyer-shot)": [[16, "light-trail-tracker-spawn-params"]],
|
||||
"(enter impact mh-flyer-shot)": [[16, "explosion-init-params"]],
|
||||
"scorpion-gun-manager-handler": [[16, "vector"]],
|
||||
"(post firing scorpion-gun)": [
|
||||
[16, "scorpion-gun-stack-var0"],
|
||||
[272, "matrix"]
|
||||
],
|
||||
"aim-post": [
|
||||
[640, "vector"],
|
||||
[672, "vector"],
|
||||
[688, "vector"],
|
||||
[704, "vector"],
|
||||
[720, "collide-query"],
|
||||
[1264, "vector"],
|
||||
[1280, ["array", "rgba", 1]],
|
||||
[16, "event-message-block"],
|
||||
[96, "vector"]
|
||||
],
|
||||
"(method 25 turret-shot)": [[32, "vector"]],
|
||||
"(method 57 target-turret)": [[112, "vector"]],
|
||||
"(method 11 hover-formation)": [[16, "vector"]],
|
||||
"test-gen-perms": [[16, "gen-perms-context"]],
|
||||
"gen-perms": [[16, ["array", "int32", 32]]],
|
||||
"(method 14 hover-formation-control)": [[256, "vector"]],
|
||||
"(method 11 hover-formation-control)": [[16, ["inline-array", "vector", 16]]],
|
||||
"(method 11 hover-nav-control)": [[80, "vector"]],
|
||||
"(method 25 hover-nav-control)": [[80, "vector"]],
|
||||
"(method 37 nav-network)": [[16, "bounding-box"]],
|
||||
"(method 27 nav-network)": [[16, "vector"]],
|
||||
"(method 33 nav-network)": [[16, "vector"]],
|
||||
"(method 34 nav-network)": [[48, "vector"]],
|
||||
"(method 16 hover-nav-control)": [[16, "vector"]],
|
||||
"(method 15 hover-nav-control)": [[16, "vector"]],
|
||||
"(method 12 hover-nav-control)": [
|
||||
[32, "vector"],
|
||||
[48, "vector"]
|
||||
],
|
||||
"(method 169 hover-enemy)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"],
|
||||
[48, "collide-query"]
|
||||
],
|
||||
"(enter ambush hover-enemy)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 176 hover-enemy)": [[16, "vector"]],
|
||||
"(method 169 flamer-hover)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 30 hover-nav-control)": [
|
||||
[16, "vector"],
|
||||
[64, "vector"],
|
||||
[80, ["array", "float", 16]],
|
||||
[32, "vector"],
|
||||
[144, ["inline-array", "vector", 4]],
|
||||
[208, ["inline-array", "vector", 4]]
|
||||
],
|
||||
"(event ambush-attack robo-hover)": [[16, "projectile-init-by-other-params"]],
|
||||
"(anon-function 14 robo-hover)": [[112, "vector"]],
|
||||
"(method 26 tow-spawner)": [
|
||||
[16, "enemy-init-by-other-params"],
|
||||
[80, "vector"],
|
||||
[96, "vector"]
|
||||
],
|
||||
"(trans active tow-spawner)": [[16, ["inline-array", "vector", 1]]],
|
||||
"(method 11 for-tower)": [[16, "vector"]],
|
||||
"for-log-callback": [[16, "vector"]],
|
||||
"spt-forest-check-ground-lie-flat": [
|
||||
[16, "quaternion"],
|
||||
[32, "matrix"]
|
||||
],
|
||||
"spt-check-water-lie-flat": [
|
||||
[112, "vector"],
|
||||
[128, "vector"]
|
||||
],
|
||||
"spt-func-birth-on-stop": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"spt-func-for-ground-dirt-bounce1": [[16, "vector"]],
|
||||
"spt-func-for-ground-dirt-bounce2": [[16, "vector"]],
|
||||
"(code active task-manager-forest-plants)": [[176, "vector"]],
|
||||
"(method 26 task-manager-forest-plants)": [
|
||||
[96, "light-trail-tracker-spawn-params"]
|
||||
],
|
||||
"(post knocked-recover dp-bipedal)": [
|
||||
[560, "vector"],
|
||||
[576, "vector"]
|
||||
],
|
||||
"(enter shield-idle dp-bipedal)": [[16, "shield-sphere-spawn-params"]],
|
||||
"(trans hostile dp-bipedal)": [[16, ["inline-array", "vector", 1]]],
|
||||
"dp-bipedal-attack-close-post": [[16, ["inline-array", "vector", 1]]],
|
||||
"dp-bipedal-formation-post": [[16, "vector"]],
|
||||
"region-check-has-los": [
|
||||
[16, "vector"],
|
||||
[32, "vector"],
|
||||
[48, "vector"],
|
||||
[64, "vector"]
|
||||
],
|
||||
"(post idle dp-bipedal-spawner)": [
|
||||
[48, "enemy-init-by-other-params"],
|
||||
[16, ["array", "collide-shape", 1]]
|
||||
],
|
||||
"trajectory-prediction": [[16, ["inline-array", "vector", 6]]],
|
||||
"(method 206 dp-bipedal)": [[16, ["inline-array", "vector", 1]]],
|
||||
"(method 209 dp-bipedal)": [[48, "vector"]],
|
||||
"(method 208 dp-bipedal)": [[576, "vector"]],
|
||||
"(post idle neo-wasp-spawner)": [[16, "enemy-init-by-other-params"]],
|
||||
"(event attack neo-wasp)": [[16, "projectile-init-by-other-params"]],
|
||||
"(anon-function 15 neo-wasp)": [
|
||||
[32, "matrix"],
|
||||
[112, "quaternion"],
|
||||
[128, "vector"]
|
||||
],
|
||||
"(method 35 neo-spawner)": [[16, "enemy-init-by-other-params"]],
|
||||
"(enter die neo-spawner)": [[192, "vector"]],
|
||||
"(method 25 for-turret-shot)": [[32, "vector"]],
|
||||
"(method 57 for-turret)": [
|
||||
[96, "vector"],
|
||||
[16, "matrix"]
|
||||
],
|
||||
"(method 15 hud-for-turret-health)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"],
|
||||
[48, "vector"],
|
||||
[64, "vector"],
|
||||
[112, "vector"],
|
||||
[256, "vector"],
|
||||
[272, "vector"],
|
||||
[288, "vector"]
|
||||
],
|
||||
"(method 52 for-turret)": [
|
||||
[32, "vector"],
|
||||
[64, "vector"]
|
||||
],
|
||||
"(enter closed dm-spines)": [[16, ["inline-array", "vector", 2]]],
|
||||
"check-drop-level-flitter-dirt-rubble": [[16, "vector"]],
|
||||
"(method 11 chain-physics)": [
|
||||
[144, "vector"],
|
||||
[128, "vector"],
|
||||
[160, "vector"],
|
||||
[176, "vector"],
|
||||
[192, "vector"],
|
||||
[256, "vector"],
|
||||
[208, "vector"],
|
||||
[224, "vector"]
|
||||
],
|
||||
"(method 31 vol-balance-plat)": [
|
||||
[32, "vector"],
|
||||
[96, "vector"],
|
||||
[112, "vector"]
|
||||
],
|
||||
"(method 47 vol-stone-lid)": [[16, "vector"]],
|
||||
"(method 49 vol-stone-lid)": [[128, ["inline-array", "vector", 2]]],
|
||||
"(code notice spiky-frog)": [[16, "vector"]],
|
||||
"(method 121 flamer-lava)": [[16, "vector"]],
|
||||
"(method 200 flamer-lava)": [[64, "vector"]],
|
||||
"(method 204 flamer-lava)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"spt-func-birth-on-pop": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(code ambush mantis)": [[16, "vector"]],
|
||||
"(code hop-away mantis)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 74 mantis)": [[1104, ["inline-array", "sphere", 6]]],
|
||||
"(method 160 mantis)": [[16, "vector"]],
|
||||
"(code shatter mhcity-dark-eco-door-broken)": [[16, "vector"]],
|
||||
"(trans idle dm-mine-spider-spawner)": [[32, "enemy-init-by-other-params"]],
|
||||
"(method 32 dm-mine-spider-spawner)": [[16, "cquery-with-vec"]],
|
||||
"(method 33 dm-mine-spider-spawner)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 160 dm-mine-spider)": [[16, "vector"]],
|
||||
"(method 192 dm-mine-spider)": [[32, "vector"]],
|
||||
"check-drop-level-dm-mine-spider-dirt-rubble": [[16, "vector"]],
|
||||
"(method 160 spyder)": [[16, "vector"]],
|
||||
"(method 197 spyder)": [
|
||||
[640, "vector"],
|
||||
[624, "vector"]
|
||||
],
|
||||
"(method 79 v-faccar)": [[16, ["inline-array", "quaternion", 1]]],
|
||||
"part-wasstada-bird2-path": [[80, "vector"]],
|
||||
"(code ambush marauder)": [
|
||||
[32, "vector"],
|
||||
[80, "vector"]
|
||||
],
|
||||
"(code save marauder)": [[16, "vector"]],
|
||||
"(code hostile marauder)": [[16, "vector"]],
|
||||
"(trans hostile marauder)": [[32, "vector"]],
|
||||
"(method 197 marauder)": [
|
||||
[64, "vector"],
|
||||
[192, "vector"]
|
||||
],
|
||||
"(method 40 wstd-fight-plat-box)": [
|
||||
[16, ["inline-array", "vector", 4]],
|
||||
[128, "vector"]
|
||||
],
|
||||
"(method 38 wstd-fight-plat-box)": [[16, "vector"]],
|
||||
"(method 39 wstd-fight-plat-box)": [
|
||||
[32, ["array", "collide-shape", 64]],
|
||||
[16, "vector"],
|
||||
[288, "vector"]
|
||||
],
|
||||
"(enter go-down task-manager-arena-fight)": [[16, "vector"]],
|
||||
"(method 36 task-manager-arena-fight-base)": [[16, "vector"]],
|
||||
"(method 32 task-manager-arena-fight-base)": [
|
||||
[16, "marauder-init-by-other-params"]
|
||||
],
|
||||
"(enter go-down task-manager-arena-fight-2)": [[16, "vector"]],
|
||||
"(method 15 hud-wasgun)": [[48, "vector"]],
|
||||
"(method 25 wascity-turret-shot)": [[32, "vector"]],
|
||||
"(method 31 dm-flyer-shot)": [[16, "light-trail-tracker-spawn-params"]],
|
||||
"(method 31 maker-grenade)": [[32, "light-trail-tracker-spawn-params"]],
|
||||
"spawn-skeet-enum": [[16, "vector"]],
|
||||
"def-launch-circle": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 26 task-manager-wascity-gungame)": [[144, "vector"]],
|
||||
"(method 56 wascity-turret)": [[32, "vector"]],
|
||||
"(method 44 wascity-turret)": [
|
||||
[176, "vector"],
|
||||
[144, "vector"]
|
||||
],
|
||||
"(method 62 wascity-turret)": [
|
||||
[16, "matrix"],
|
||||
[80, "bounding-box"],
|
||||
[752, "vector"],
|
||||
[624, "vector"],
|
||||
[656, "vector"],
|
||||
[704, "vector"],
|
||||
[880, "vector"]
|
||||
],
|
||||
"(method 57 wascity-turret)": [[128, "vector"]],
|
||||
"wascity-turret-add-radar": [[32, "vector"]],
|
||||
"(method 21 traffic-manager)": [[16, ["array", "int8", 29]]],
|
||||
"(method 13 xz-height-map)": [[16, ["inline-array", "vector", 2]]],
|
||||
"(method 10 xz-height-map)": [[16, ["inline-array", "bounding-box", 2]]],
|
||||
"(method 20 vehicle-controller)": [[16, ["inline-array", "vector", 2]]],
|
||||
"(method 16 vehicle-controller)": [[16, ["inline-array", "vector", 2]]],
|
||||
"(method 51 hvehicle)": [[16, "vehicle-physics-work"]],
|
||||
"(method 90 hvehicle)": [[16, "vehicle-physics-work"]],
|
||||
"(method 157 hvehicle)": [[16, "matrix"]],
|
||||
"(method 94 hvehicle)": [[16, "matrix"]],
|
||||
"(method 91 hvehicle)": [[16, "vehicle-controls"]],
|
||||
"(method 54 hvehicle)": [[16, "rigid-body-move-work"]],
|
||||
"(method 30 hvehicle)": [[16, ["inline-array", "vector", 2]]],
|
||||
"(method 18 vehicle-controller)": [
|
||||
[32, "vehicle-physics-work"],
|
||||
[288, ["array", "collide-shape", 10]]
|
||||
],
|
||||
"(method 158 hvehicle)": [[16, ["inline-array", "vector", 2]]],
|
||||
"(method 20 traffic-engine)": [[16, "traffic-find-segment-struct"]],
|
||||
"(method 31 hvehicle)": [
|
||||
[960, ["inline-array", "vector", 4]],
|
||||
[1056, "vector"],
|
||||
[1072, ["inline-array", "vehicle-attach-point", 4]]
|
||||
],
|
||||
"(method 97 hvehicle)": [[16, "collide-query"]],
|
||||
"(method 78 hvehicle)": [[16, "hvehicle-effects-stack-var0"]],
|
||||
"(post idle glider-ring)": [[128, "vector"]],
|
||||
"glider-ring-standard-event-handler": [[16, ["inline-array", "vector", 2]]],
|
||||
"glider-ring-init-by-other": [
|
||||
[48, "light-trail-tracker-spawn-params"],
|
||||
[16, "vector"]
|
||||
],
|
||||
"(method 49 h-glider)": [[16, "vector"]],
|
||||
"(method 36 task-manager-desert-glide)": [[224, "vector"]],
|
||||
"(method 26 task-manager-desert-glide)": [
|
||||
[96, ["array", "symbol", 10]],
|
||||
[144, "vector"]
|
||||
],
|
||||
"(method 31 h-glider)": [[48, "vehicle-physics-work"]],
|
||||
"sparticle-shadow-update": [
|
||||
[16, "vector"],
|
||||
[32, "matrix"],
|
||||
[96, "vector"]
|
||||
],
|
||||
"(method 27 was-pre-game)": [[16, "vector"]],
|
||||
"(method 31 was-pre-game)": [
|
||||
[80, "vector"],
|
||||
[96, "vector"],
|
||||
[112, "vector"],
|
||||
[128, "vector"]
|
||||
],
|
||||
"(post attack was-pre-beam)": [[16, "vector"]],
|
||||
"(post idle was-pre-beam)": [[16, "vector"]],
|
||||
"(method 187 flut-racer)": [
|
||||
[96, ["array", "collide-shape", 384]],
|
||||
[80, "vector"]
|
||||
],
|
||||
"ring-hit-logic": [[112, "vector"]],
|
||||
"(method 30 task-manager-wascity-leaper-race)": [
|
||||
[96, ["array", "symbol", 10]]
|
||||
],
|
||||
"(code active task-manager-wascity-leaper-race)": [
|
||||
[32, ["array", "symbol", 10]]
|
||||
],
|
||||
"(enter fail task-manager-wascity-leaper-race)": [
|
||||
[16, ["array", "symbol", 10]]
|
||||
],
|
||||
"(method 26 task-manager-desert-catch-lizards)": [
|
||||
[224, ["array", "collide-shape", 32]]
|
||||
],
|
||||
"(method 33 task-manager-desert-catch-lizards)": [
|
||||
[32, ["inline-array", "vector", 2]]
|
||||
],
|
||||
"(method 165 desert-lizard)": [
|
||||
[32, "vector"],
|
||||
[48, "vector"],
|
||||
[64, ["inline-array", "vector", 1]]
|
||||
],
|
||||
"(post idle desert-lizard-spawner)": [[48, "enemy-init-by-other-params"]],
|
||||
"(anon-function 33 desert-scenes)": [[16, "vector"]],
|
||||
"(method 19 dm-tentacle-ragdoll)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"foot-impact": [[16, "vector"]],
|
||||
"launch-mine": [
|
||||
[16, "vector"],
|
||||
[48, "enemy-init-by-other-params"]
|
||||
],
|
||||
"(method 10 terraformer-foot-mark-pt-array)": [
|
||||
[592, ["inline-array", "vector", 4]],
|
||||
[1216, "bounding-box"]
|
||||
],
|
||||
"(enter run-script terraformer-head)": [[16, "vector"]],
|
||||
"(enter swing-laser terraformer-head)": [[16, "vector"]],
|
||||
"terraformer-head-launch-critter": [
|
||||
[16, "vector"],
|
||||
[32, "enemy-init-by-other-params"],
|
||||
[160, "matrix"]
|
||||
],
|
||||
"terraformer-head-always": [
|
||||
[272, "vector"],
|
||||
[256, "vector"]
|
||||
],
|
||||
"(method 12 ocean)": [[16, "vector"]],
|
||||
"(method 18 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector4"],
|
||||
[48, "vector"]
|
||||
],
|
||||
"(method 28 ocean)": [[16, "vector"]],
|
||||
"(method 33 ocean)": [[16, "vector"]],
|
||||
"(method 34 ocean)": [[16, "vector"]],
|
||||
"(method 35 ocean)": [[16, "vector"]],
|
||||
"(method 36 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 46 ocean)": [[16, "vector"]],
|
||||
"(method 59 ocean)": [[16, "vector"]],
|
||||
"(method 60 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 61 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 62 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 63 ocean)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 67 ocean)": [[16, "vector"]],
|
||||
"(post flying maker)": [[48, "vector"]],
|
||||
"(post standup maker)": [
|
||||
[16, "vector"],
|
||||
[32, "vector"]
|
||||
],
|
||||
"(method 36 maker)": [
|
||||
[64, "vector"],
|
||||
[336, "vector"]
|
||||
],
|
||||
"(method 41 maker)": [[560, "vector"]],
|
||||
"maker-init-by-other": [[32, "light-trail-tracker-spawn-params"]]
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -2011,5 +2011,50 @@
|
||||
"vars": {
|
||||
"v0-0": ["v0-0", "saberfish-find-behavior"]
|
||||
}
|
||||
},
|
||||
"(method 23 spider-manager)": {
|
||||
"vars": {
|
||||
"s3-0": ["dist", "float"]
|
||||
}
|
||||
},
|
||||
"(method 121 sewer-frog)": {
|
||||
"vars": {
|
||||
"v1-10": ["name", "sound-name"]
|
||||
}
|
||||
},
|
||||
"(trans target-board-ride-edge)": {
|
||||
"vars": {
|
||||
"a0-44": ["name", "sound-name"]
|
||||
}
|
||||
},
|
||||
"(method 9 menu-create-game-option)": {
|
||||
"vars": {
|
||||
"a0-26": ["name", "sound-name"]
|
||||
}
|
||||
},
|
||||
"(code active task-manager-forest-plants)": {
|
||||
"vars": {
|
||||
"s5-8": ["hand", "handle"]
|
||||
}
|
||||
},
|
||||
"(method 31 dm-mine-spider-spawner)": {
|
||||
"vars": {
|
||||
"s3-0": ["s3-0", "float"]
|
||||
}
|
||||
},
|
||||
"(method 26 task-manager-wascity-gungame)": {
|
||||
"vars": {
|
||||
"s4-1": ["sname", "sound-name"]
|
||||
}
|
||||
},
|
||||
"terraformer-head-always": {
|
||||
"vars": {
|
||||
"s4-2": ["sname", "sound-name"]
|
||||
}
|
||||
},
|
||||
"launch-mine": {
|
||||
"vars": {
|
||||
"v0-1": ["hand", "handle"]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -690,7 +690,7 @@ goos::Object decompile_sound_spec(const TypeSpec& type,
|
||||
the_macro.push_back(pretty_print::to_symbol(fmt::format(":num {}", num)));
|
||||
}
|
||||
if (group != 1) {
|
||||
the_macro.push_back(pretty_print::to_symbol(fmt::format(":group {}", num)));
|
||||
the_macro.push_back(pretty_print::to_symbol(fmt::format(":group {}", group)));
|
||||
}
|
||||
if ((mask & 1) || volume != 1024) {
|
||||
implicit_mask |= 1 << 0;
|
||||
@@ -976,14 +976,9 @@ const std::unordered_map<
|
||||
{"lightning-probe-vars",
|
||||
{{"probe-dirs", ArrayFieldDecompMeta(TypeSpec("vector"), 16)}}},
|
||||
{"continue-point",
|
||||
{{"want", ArrayFieldDecompMeta(TypeSpec("level-buffer-state-small"),
|
||||
8,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"want", ArrayFieldDecompMeta(TypeSpec("level-buffer-state-small"), 8)}}},
|
||||
{"task-manager-info",
|
||||
{{"sphere-array",
|
||||
ArrayFieldDecompMeta(TypeSpec("sphere"),
|
||||
16,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"sphere-array", ArrayFieldDecompMeta(TypeSpec("sphere"), 16)}}},
|
||||
{"sparticle-launcher",
|
||||
{{"init-specs", ArrayFieldDecompMeta(TypeSpec("sp-field-init-spec"), 16)}}},
|
||||
{"sparticle-launch-group",
|
||||
@@ -991,27 +986,40 @@ const std::unordered_map<
|
||||
{"simple-sprite-system",
|
||||
{{"data", ArrayFieldDecompMeta(TypeSpec("sprite-glow-data"), 64)}}},
|
||||
{"actor-hash-bucket",
|
||||
{{"data", ArrayFieldDecompMeta(TypeSpec("actor-cshape-ptr"),
|
||||
16,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"data", ArrayFieldDecompMeta(TypeSpec("actor-cshape-ptr"), 16)}}},
|
||||
{"nav-mesh",
|
||||
{{"poly-array", ArrayFieldDecompMeta(TypeSpec("nav-poly"), 64)},
|
||||
{"nav-control-array", ArrayFieldDecompMeta(TypeSpec("nav-control"), 288)}}},
|
||||
{"enemy-info",
|
||||
{{"idle-anim-script",
|
||||
ArrayFieldDecompMeta(TypeSpec("idle-control-frame"),
|
||||
32,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"idle-anim-script", ArrayFieldDecompMeta(TypeSpec("idle-control-frame"), 32)}}},
|
||||
{"nav-enemy-info",
|
||||
{{"idle-anim-script",
|
||||
ArrayFieldDecompMeta(TypeSpec("idle-control-frame"),
|
||||
32,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"idle-anim-script", ArrayFieldDecompMeta(TypeSpec("idle-control-frame"), 32)}}},
|
||||
{"vehicle-rider-info",
|
||||
{{"attach-point-array",
|
||||
ArrayFieldDecompMeta(TypeSpec("vehicle-attach-point"),
|
||||
32,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INLINE_ARR)}}},
|
||||
{{"grab-rail-array", ArrayFieldDecompMeta(TypeSpec("vehicle-grab-rail-info"), 48)},
|
||||
{"attach-point-array", ArrayFieldDecompMeta(TypeSpec("vehicle-attach-point"), 32)}}},
|
||||
{"desbeast-path", {{"node", ArrayFieldDecompMeta(TypeSpec("desbeast-node"), 32)}}},
|
||||
{"race-info",
|
||||
{{"turbo-pad-array", ArrayFieldDecompMeta(TypeSpec("race-turbo-pad"), 32)},
|
||||
{"racer-array", ArrayFieldDecompMeta(TypeSpec("race-racer-info"), 16)},
|
||||
{"decision-point-array",
|
||||
ArrayFieldDecompMeta(TypeSpec("race-decision-point"), 16)}}},
|
||||
{"flyingsaw-graph", {{"node", ArrayFieldDecompMeta(TypeSpec("flyingsaw-node"), 48)}}},
|
||||
{"nav-network-info",
|
||||
{{"adjacency", ArrayFieldDecompMeta(TypeSpec("nav-network-adjacency"), 16)}}},
|
||||
{"forest-path-points-static",
|
||||
{{"points", ArrayFieldDecompMeta(TypeSpec("vector"), 16)}}},
|
||||
{"xz-height-map",
|
||||
{{"data", ArrayFieldDecompMeta(TypeSpec("int8"),
|
||||
1,
|
||||
ArrayFieldDecompMeta::Kind::REF_TO_INTEGER_ARR)}}},
|
||||
{"was-pre-game-game",
|
||||
{{"wave", ArrayFieldDecompMeta(TypeSpec("was-pre-game-wave"), 32)}}},
|
||||
{"lizard-graph",
|
||||
{{"point", ArrayFieldDecompMeta(TypeSpec("vector"), 16)},
|
||||
{"edge", ArrayFieldDecompMeta(TypeSpec("lizard-graph-edge"), 16)}}},
|
||||
{"terraformer-graph",
|
||||
{{"node", ArrayFieldDecompMeta(TypeSpec("terraformer-node"), 32)},
|
||||
{"edge", ArrayFieldDecompMeta(TypeSpec("terraformer-edge"), 16)}}},
|
||||
}}};
|
||||
|
||||
goos::Object decompile_structure(const TypeSpec& type,
|
||||
|
||||
@@ -209,6 +209,9 @@ set(RUNTIME_SOURCE
|
||||
mips2c/jak3_functions/nav_engine.cpp
|
||||
mips2c/jak3_functions/merc_blend_shape.cpp
|
||||
mips2c/jak3_functions/wvehicle_part.cpp
|
||||
mips2c/jak3_functions/ripple.cpp
|
||||
mips2c/jak3_functions/ocean.cpp
|
||||
mips2c/jak3_functions/ocean_vu0.cpp
|
||||
mips2c/mips2c_table.cpp
|
||||
overlord/common/dma.cpp
|
||||
overlord/common/fake_iso.cpp
|
||||
|
||||
@@ -141,6 +141,9 @@ void OpenGLRenderer::init_bucket_renderers_jak3() {
|
||||
init_bucket_renderer<TextureUploadHandler>("tex-lcom-sky-pre", BucketCategory::TEX,
|
||||
BucketId::TEX_LCOM_SKY_PRE, texture_animator);
|
||||
|
||||
init_bucket_renderer<OceanMidAndFar>("ocean-mid-far", BucketCategory::OCEAN,
|
||||
BucketId::OCEAN_MID_FAR);
|
||||
|
||||
// 10
|
||||
for (int i = 0; i < LEVEL_MAX; i++) {
|
||||
#define GET_BUCKET_ID_FOR_LIST(bkt1, bkt2, idx) ((int)(bkt1) + ((int)(bkt2) - (int)(bkt1)) * (idx))
|
||||
@@ -248,6 +251,7 @@ void OpenGLRenderer::init_bucket_renderers_jak3() {
|
||||
// 461
|
||||
init_bucket_renderer<TextureUploadHandler>("tex-lcom-sky-post", BucketCategory::TEX,
|
||||
BucketId::TEX_LCOM_SKY_POST, texture_animator);
|
||||
init_bucket_renderer<OceanNear>("ocean-near", BucketCategory::OCEAN, BucketId::OCEAN_NEAR);
|
||||
|
||||
// 463
|
||||
for (int i = 0; i < LEVEL_MAX; i++) {
|
||||
|
||||
@@ -926,7 +926,7 @@ enum class BucketId {
|
||||
GMERC2_LCOM_PRIS2 = 460,
|
||||
|
||||
TEX_LCOM_SKY_POST = 461,
|
||||
BUCKET462 = 462,
|
||||
OCEAN_NEAR = 462,
|
||||
|
||||
TEX_L0_WATER = 463,
|
||||
MERC_L0_WATER = 464,
|
||||
|
||||
@@ -30,6 +30,7 @@ void OceanMidAndFar::render(DmaFollower& dma,
|
||||
render_jak1(dma, render_state, prof);
|
||||
break;
|
||||
case GameVersion::Jak2:
|
||||
case GameVersion::Jak3:
|
||||
render_jak2(dma, render_state, prof);
|
||||
break;
|
||||
}
|
||||
@@ -174,6 +175,7 @@ void OceanMidAndFar::handle_ocean_mid(DmaFollower& dma,
|
||||
m_mid_renderer.run(dma, render_state, prof);
|
||||
break;
|
||||
case GameVersion::Jak2:
|
||||
case GameVersion::Jak3:
|
||||
m_mid_renderer.run_jak2(dma, render_state, prof);
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -38,6 +38,7 @@ void OceanNear::render(DmaFollower& dma,
|
||||
render_jak1(dma, render_state, prof);
|
||||
break;
|
||||
case GameVersion::Jak2:
|
||||
case GameVersion::Jak3:
|
||||
render_jak2(dma, render_state, prof);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -68,6 +68,7 @@ void OceanTexture::init_textures(TexturePool& pool, GameVersion version) {
|
||||
m_tex0_gpu = pool.give_texture_and_load_to_vram(in, OCEAN_TEX_TBP_JAK1);
|
||||
break;
|
||||
case GameVersion::Jak2:
|
||||
case GameVersion::Jak3:
|
||||
m_tex0_gpu = pool.give_texture_and_load_to_vram(in, OCEAN_TEX_TBP_JAK2);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,381 @@
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
ExecutionContext ocean_regs_vfs;
|
||||
namespace init_ocean_far_regs {
|
||||
struct Cache {
|
||||
void* math_camera; // *math-camera*
|
||||
void* sky_work; // *sky-work*
|
||||
void* time_of_day_context; // *time-of-day-context*
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
c->load_symbol2(v1, cache.math_camera); // lw v1, *math-camera*(s7)
|
||||
c->load_symbol2(a0, cache.sky_work); // lw a0, *sky-work*(s7)
|
||||
c->daddiu(a0, a0, 1088); // daddiu a0, a0, 1088
|
||||
c->lwc1(f0, 908, v1); // lwc1 f0, 908(v1)
|
||||
c->swc1(f0, 0, a0); // swc1 f0, 0(a0)
|
||||
c->lwc1(f0, 128, v1); // lwc1 f0, 128(v1)
|
||||
c->swc1(f0, 4, a0); // swc1 f0, 4(a0)
|
||||
c->lwc1(f0, 124, v1); // lwc1 f0, 124(v1)
|
||||
c->swc1(f0, 8, a0); // swc1 f0, 8(a0)
|
||||
c->lui(a1, 16256); // lui a1, 16256
|
||||
c->mtc1(f0, a1); // mtc1 f0, a1
|
||||
c->swc1(f0, 12, a0); // swc1 f0, 12(a0)
|
||||
c->load_symbol2(a0, cache.time_of_day_context); // lw a0, *time-of-day-context*(s7)
|
||||
c->lwu(a0, 2656, a0); // lwu a0, 2656(a0)
|
||||
bc = c->sgpr64(s7) == c->sgpr64(a0); // beq s7, a0, L123
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_2;} // branch non-likely
|
||||
|
||||
c->lqc2(vf31, 1228, v1); // lqc2 vf31, 1228(v1)
|
||||
c->lqc2(vf30, 1244, v1); // lqc2 vf30, 1244(v1)
|
||||
c->lqc2(vf29, 1260, v1); // lqc2 vf29, 1260(v1)
|
||||
c->lqc2(vf28, 1276, v1); // lqc2 vf28, 1276(v1)
|
||||
c->mov128_gpr_vf(a0, vf28); // qmfc2.i a0, vf28
|
||||
//beq r0, r0, L124 // beq r0, r0, L124
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_3; // branch always
|
||||
|
||||
|
||||
block_2:
|
||||
c->lqc2(vf31, 572, v1); // lqc2 vf31, 572(v1)
|
||||
c->lqc2(vf30, 588, v1); // lqc2 vf30, 588(v1)
|
||||
c->lqc2(vf29, 604, v1); // lqc2 vf29, 604(v1)
|
||||
c->lqc2(vf28, 620, v1); // lqc2 vf28, 620(v1)
|
||||
c->mov128_gpr_vf(a0, vf28); // qmfc2.i a0, vf28
|
||||
|
||||
block_3:
|
||||
c->lqc2(vf26, 796, v1); // lqc2 vf26, 796(v1)
|
||||
c->lqc2(vf14, 780, v1); // lqc2 vf14, 780(v1)
|
||||
c->lqc2(vf25, 812, v1); // lqc2 vf25, 812(v1)
|
||||
c->load_symbol2(v1, cache.sky_work); // lw v1, *sky-work*(s7)
|
||||
c->lqc2(vf13, 1088, v1); // lqc2 vf13, 1088(v1)
|
||||
c->load_symbol2(v1, cache.sky_work); // lw v1, *sky-work*(s7)
|
||||
c->lqc2(vf27, 1072, v1); // lqc2 vf27, 1072(v1)
|
||||
c->mov128_gpr_vf(v1, vf27); // qmfc2.i v1, vf27
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
ocean_regs_vfs.copy_vfs_from_other(c);
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.math_camera = intern_from_c(-1, 0, "*math-camera*").c();
|
||||
cache.sky_work = intern_from_c(-1, 0, "*sky-work*").c();
|
||||
cache.time_of_day_context = intern_from_c(-1, 0, "*time-of-day-context*").c();
|
||||
gLinkedFunctionTable.reg("init-ocean-far-regs", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace init_ocean_far_regs
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "sky.h"
|
||||
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace draw_large_polygon_ocean {
|
||||
struct Cache {
|
||||
void* clip_polygon_against_negative_hyperplane; // clip-polygon-against-negative-hyperplane
|
||||
void* clip_polygon_against_positive_hyperplane; // clip-polygon-against-positive-hyperplane
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
[[maybe_unused]] u32 call_addr = 0;
|
||||
// nop // sll r0, r0, 0
|
||||
c->daddiu(sp, sp, -8); // daddiu sp, sp, -8
|
||||
c->mov64(t6, s7); // or t6, s7, r0
|
||||
c->sd(ra, 0, sp); // sd ra, 0(sp)
|
||||
c->load_symbol2(t9, cache.clip_polygon_against_positive_hyperplane);// lw t9, clip-polygon-against-positive-hyperplane(s7)
|
||||
c->mov64(a2, t4); // or a2, t4, r0
|
||||
c->mov64(a3, t5); // or a3, t5, r0
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->daddu(t2, a2, r0); // daddu t2, a2, r0
|
||||
// c->jalr(call_addr); // jalr ra, t9
|
||||
clip_polygon_against_positive_hyperplane::execute(ctxt);
|
||||
bc = c->sgpr64(t0) == 0; // beq t0, r0, L121
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_11;} // branch non-likely
|
||||
|
||||
c->mov64(a2, t5); // or a2, t5, r0
|
||||
c->mov64(a3, t4); // or a3, t4, r0
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->daddiu(t2, a2, 4); // daddiu t2, a2, 4
|
||||
// c->jalr(call_addr); // jalr ra, t9
|
||||
clip_polygon_against_positive_hyperplane::execute(ctxt);
|
||||
bc = c->sgpr64(t0) == 0; // beq t0, r0, L121
|
||||
c->load_symbol2(t9, cache.clip_polygon_against_negative_hyperplane);// lw t9, clip-polygon-against-negative-hyperplane(s7)
|
||||
if (bc) {goto block_11;} // branch non-likely
|
||||
|
||||
c->mov64(a2, t4); // or a2, t4, r0
|
||||
c->mov64(a3, t5); // or a3, t5, r0
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->daddu(t2, a2, r0); // daddu t2, a2, r0
|
||||
// c->jalr(call_addr); // jalr ra, t9
|
||||
clip_polygon_against_negative_hyperplane::execute(ctxt);
|
||||
bc = c->sgpr64(t0) == 0; // beq t0, r0, L121
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_11;} // branch non-likely
|
||||
|
||||
c->mov64(a2, t5); // or a2, t5, r0
|
||||
c->mov64(a3, t4); // or a3, t4, r0
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->daddiu(t2, a2, 4); // daddiu t2, a2, 4
|
||||
// c->jalr(call_addr); // jalr ra, t9
|
||||
clip_polygon_against_negative_hyperplane::execute(ctxt);
|
||||
bc = c->sgpr64(t0) == 0; // beq t0, r0, L121
|
||||
c->lw(a3, 4, a1); // lw a3, 4(a1)
|
||||
if (bc) {goto block_11;} // branch non-likely
|
||||
|
||||
bc = c->sgpr64(t6) == c->sgpr64(s7); // beq t6, s7, L119
|
||||
c->mov64(a2, t4); // or a2, t4, r0
|
||||
if (bc) {goto block_8;} // branch non-likely
|
||||
|
||||
c->sqc2(vf27, 0, a3); // sqc2 vf27, 0(a3)
|
||||
c->daddiu(a3, a3, 16); // daddiu a3, a3, 16
|
||||
c->sw(t0, -16, a3); // sw t0, -16(a3)
|
||||
// nop // sll r0, r0, 0
|
||||
|
||||
block_6:
|
||||
c->lqc2(vf1, 0, a2); // lqc2 vf1, 0(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf2, 16, a2); // lqc2 vf2, 16(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf3, 32, a2); // lqc2 vf3, 32(a2)
|
||||
c->vdiv(vf0, BC::w, vf1, BC::w); // vdiv Q, vf0.w, vf1.w
|
||||
c->vmul(DEST::xyzw, vf1, vf1, vf26); // vmul.xyzw vf1, vf1, vf26
|
||||
// nop // sll r0, r0, 0
|
||||
c->vftoi0(DEST::xyzw, vf3, vf3); // vftoi0.xyzw vf3, vf3
|
||||
// nop // sll r0, r0, 0
|
||||
c->vwaitq(); // vwaitq
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmulq(DEST::xyz, vf1, vf1); // vmulq.xyz vf1, vf1, Q
|
||||
c->sqc2(vf3, 16, a3); // sqc2 vf3, 16(a3)
|
||||
c->vmulq(DEST::xyzw, vf2, vf2); // vmulq.xyzw vf2, vf2, Q
|
||||
c->daddiu(a2, a2, 48); // daddiu a2, a2, 48
|
||||
c->vadd(DEST::xyzw, vf1, vf1, vf25); // vadd.xyzw vf1, vf1, vf25
|
||||
c->daddiu(a3, a3, 48); // daddiu a3, a3, 48
|
||||
c->vmax_bc(DEST::z, BC::z, vf1, vf1, vf0); // vmaxz.z vf1, vf1, vf0
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmini_bc(DEST::w, BC::z, vf1, vf1, vf13); // vminiz.w vf1, vf1, vf13
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmax_bc(DEST::w, BC::y, vf1, vf1, vf13); // vmaxy.w vf1, vf1, vf13
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf2, -48, a3); // sqc2 vf2, -48(a3)
|
||||
c->daddiu(t0, t0, -1); // daddiu t0, t0, -1
|
||||
c->vftoi4(DEST::xyzw, vf1, vf1); // vftoi4.xyzw vf1, vf1
|
||||
// nop // sll r0, r0, 0
|
||||
bc = c->sgpr64(t0) != 0; // bne t0, r0, L118
|
||||
c->sqc2(vf1, -16, a3); // sqc2 vf1, -16(a3)
|
||||
if (bc) {goto block_6;} // branch non-likely
|
||||
|
||||
c->sw(a3, 4, a1); // sw a3, 4(a1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->ld(ra, 0, sp); // ld ra, 0(sp)
|
||||
c->daddiu(v0, s7, 4); // daddiu v0, s7, 4
|
||||
//jr ra // jr ra
|
||||
c->daddiu(sp, sp, 8); // daddiu sp, sp, 8
|
||||
goto end_of_function; // return
|
||||
|
||||
|
||||
block_8:
|
||||
c->sqc2(vf27, 0, a3); // sqc2 vf27, 0(a3)
|
||||
c->daddiu(a3, a3, 16); // daddiu a3, a3, 16
|
||||
c->sw(t0, -16, a3); // sw t0, -16(a3)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf15, 0, a2); // sqc2 vf15, 0(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf15, 192, a2); // sqc2 vf15, 192(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf16, 48, a2); // sqc2 vf16, 48(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf17, 96, a2); // sqc2 vf17, 96(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf18, 144, a2); // sqc2 vf18, 144(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
|
||||
block_9:
|
||||
c->lqc2(vf1, 0, a2); // lqc2 vf1, 0(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf3, 32, a2); // lqc2 vf3, 32(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf2, 16, a2); // lqc2 vf2, 16(a2)
|
||||
c->vdiv(vf13, BC::x, vf1, BC::w); // vdiv Q, vf13.x, vf1.w
|
||||
c->vftoi0(DEST::xyzw, vf3, vf3); // vftoi0.xyzw vf3, vf3
|
||||
// nop // sll r0, r0, 0
|
||||
c->vwaitq(); // vwaitq
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmulq(DEST::xyz, vf1, vf1); // vmulq.xyz vf1, vf1, Q
|
||||
c->sqc2(vf3, 16, a3); // sqc2 vf3, 16(a3)
|
||||
c->vmulq(DEST::xyzw, vf2, vf2); // vmulq.xyzw vf2, vf2, Q
|
||||
c->daddiu(a2, a2, 48); // daddiu a2, a2, 48
|
||||
c->vadd(DEST::xyzw, vf1, vf1, vf25); // vadd.xyzw vf1, vf1, vf25
|
||||
c->daddiu(a3, a3, 48); // daddiu a3, a3, 48
|
||||
c->vmax_bc(DEST::z, BC::z, vf1, vf1, vf0); // vmaxz.z vf1, vf1, vf0
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmini_bc(DEST::w, BC::z, vf1, vf1, vf13); // vminiz.w vf1, vf1, vf13
|
||||
// nop // sll r0, r0, 0
|
||||
c->vmax_bc(DEST::w, BC::y, vf1, vf1, vf13); // vmaxy.w vf1, vf1, vf13
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf2, -48, a3); // sqc2 vf2, -48(a3)
|
||||
c->daddiu(t0, t0, -1); // daddiu t0, t0, -1
|
||||
c->vftoi4(DEST::xyzw, vf1, vf1); // vftoi4.xyzw vf1, vf1
|
||||
// nop // sll r0, r0, 0
|
||||
bc = c->sgpr64(t0) != 0; // bne t0, r0, L120
|
||||
c->sqc2(vf1, -16, a3); // sqc2 vf1, -16(a3)
|
||||
if (bc) {goto block_9;} // branch non-likely
|
||||
|
||||
c->sw(a3, 4, a1); // sw a3, 4(a1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->ld(ra, 0, sp); // ld ra, 0(sp)
|
||||
c->daddiu(v0, s7, 4); // daddiu v0, s7, 4
|
||||
//jr ra // jr ra
|
||||
c->daddiu(sp, sp, 8); // daddiu sp, sp, 8
|
||||
goto end_of_function; // return
|
||||
|
||||
|
||||
block_11:
|
||||
c->ld(ra, 0, sp); // ld ra, 0(sp)
|
||||
c->mov64(v0, s7); // or v0, s7, r0
|
||||
//jr ra // jr ra
|
||||
c->daddiu(sp, sp, 8); // daddiu sp, sp, 8
|
||||
goto end_of_function; // return
|
||||
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.clip_polygon_against_negative_hyperplane = intern_from_c(-1, 0, "clip-polygon-against-negative-hyperplane").c();
|
||||
cache.clip_polygon_against_positive_hyperplane = intern_from_c(-1, 0, "clip-polygon-against-positive-hyperplane").c();
|
||||
gLinkedFunctionTable.reg("draw-large-polygon-ocean", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace draw_large_polygon_ocean
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace render_ocean_quad {
|
||||
struct Cache {
|
||||
void* fake_scratchpad_data; // *fake-scratchpad-data*
|
||||
void* draw_large_polygon_ocean; // draw-large-polygon-ocean
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
c->copy_vfs_from_other(&ocean_regs_vfs);
|
||||
c->mov64(v1, a0); // or v1, a0, r0
|
||||
get_fake_spad_addr2(t4, cache.fake_scratchpad_data, 0, c);// lui t4, 28672
|
||||
c->ori(t4, t4, 12288); // ori t4, t4, 12288
|
||||
get_fake_spad_addr2(t5, cache.fake_scratchpad_data, 0, c);// lui t5, 28672
|
||||
c->ori(t5, t5, 14336); // ori t5, t5, 14336
|
||||
c->mov64(a3, t4); // or a3, t4, r0
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf1, 0, a0); // lqc2 vf1, 0(a0)
|
||||
c->addiu(t0, r0, 4); // addiu t0, r0, 4
|
||||
c->lqc2(vf2, 16, a0); // lqc2 vf2, 16(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf3, 32, a0); // lqc2 vf3, 32(a0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf31, vf1); // vmulax.xyzw acc, vf31, vf1
|
||||
c->lqc2(vf4, 48, a0); // lqc2 vf4, 48(a0)
|
||||
c->vmadda_bc(DEST::xyzw, BC::y, vf30, vf1); // vmadday.xyzw acc, vf30, vf1
|
||||
c->lqc2(vf5, 64, a0); // lqc2 vf5, 64(a0)
|
||||
c->vmadda_bc(DEST::xyzw, BC::z, vf29, vf1); // vmaddaz.xyzw acc, vf29, vf1
|
||||
c->lqc2(vf6, 80, a0); // lqc2 vf6, 80(a0)
|
||||
c->vmadd_bc(DEST::xyzw, BC::w, vf15, vf28, vf1); // vmaddw.xyzw vf15, vf28, vf1
|
||||
c->lqc2(vf7, 96, a0); // lqc2 vf7, 96(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf8, 112, a0); // lqc2 vf8, 112(a0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf31, vf4); // vmulax.xyzw acc, vf31, vf4
|
||||
c->lqc2(vf9, 128, a0); // lqc2 vf9, 128(a0)
|
||||
c->vmadda_bc(DEST::xyzw, BC::y, vf30, vf4); // vmadday.xyzw acc, vf30, vf4
|
||||
c->lqc2(vf10, 144, a0); // lqc2 vf10, 144(a0)
|
||||
c->vmadda_bc(DEST::xyzw, BC::z, vf29, vf4); // vmaddaz.xyzw acc, vf29, vf4
|
||||
c->lqc2(vf11, 160, a0); // lqc2 vf11, 160(a0)
|
||||
c->vmadd_bc(DEST::xyzw, BC::w, vf16, vf28, vf4); // vmaddw.xyzw vf16, vf28, vf4
|
||||
c->lqc2(vf12, 176, a0); // lqc2 vf12, 176(a0)
|
||||
c->vmul(DEST::xyzw, vf1, vf15, vf14); // vmul.xyzw vf1, vf15, vf14
|
||||
c->sqc2(vf2, 16, a3); // sqc2 vf2, 16(a3)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf31, vf7); // vmulax.xyzw acc, vf31, vf7
|
||||
c->sqc2(vf3, 32, a3); // sqc2 vf3, 32(a3)
|
||||
c->vmadda_bc(DEST::xyzw, BC::y, vf30, vf7); // vmadday.xyzw acc, vf30, vf7
|
||||
c->sqc2(vf5, 64, a3); // sqc2 vf5, 64(a3)
|
||||
c->vmadda_bc(DEST::xyzw, BC::z, vf29, vf7); // vmaddaz.xyzw acc, vf29, vf7
|
||||
c->sqc2(vf6, 80, a3); // sqc2 vf6, 80(a3)
|
||||
c->vmadd_bc(DEST::xyzw, BC::w, vf17, vf28, vf7); // vmaddw.xyzw vf17, vf28, vf7
|
||||
c->sqc2(vf8, 112, a3); // sqc2 vf8, 112(a3)
|
||||
c->vmul(DEST::xyzw, vf4, vf16, vf14); // vmul.xyzw vf4, vf16, vf14
|
||||
c->sqc2(vf9, 128, a3); // sqc2 vf9, 128(a3)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf31, vf10); // vmulax.xyzw acc, vf31, vf10
|
||||
c->sqc2(vf11, 160, a3); // sqc2 vf11, 160(a3)
|
||||
c->vmadda_bc(DEST::xyzw, BC::y, vf30, vf10); // vmadday.xyzw acc, vf30, vf10
|
||||
c->sqc2(vf12, 176, a3); // sqc2 vf12, 176(a3)
|
||||
c->vmadda_bc(DEST::xyzw, BC::z, vf29, vf10); // vmaddaz.xyzw acc, vf29, vf10
|
||||
c->sqc2(vf2, 208, a3); // sqc2 vf2, 208(a3)
|
||||
c->vmadd_bc(DEST::xyzw, BC::w, vf18, vf28, vf10); // vmaddw.xyzw vf18, vf28, vf10
|
||||
c->sqc2(vf3, 224, a3); // sqc2 vf3, 224(a3)
|
||||
c->vmul(DEST::xyzw, vf7, vf17, vf14); // vmul.xyzw vf7, vf17, vf14
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf1, 0, a3); // sqc2 vf1, 0(a3)
|
||||
c->vmul(DEST::xyzw, vf10, vf18, vf14); // vmul.xyzw vf10, vf18, vf14
|
||||
c->sqc2(vf1, 192, a3); // sqc2 vf1, 192(a3)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf4, 48, a3); // sqc2 vf4, 48(a3)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf7, 96, a3); // sqc2 vf7, 96(a3)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf10, 144, a3); // sqc2 vf10, 144(a3)
|
||||
c->load_symbol2(t9, cache.draw_large_polygon_ocean);// lw t9, draw-large-polygon-ocean(s7)
|
||||
// Unknown instr: jr t9
|
||||
return draw_large_polygon_ocean::execute(c);
|
||||
// nop // sll r0, r0, 0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.fake_scratchpad_data = intern_from_c(-1, 0, "*fake-scratchpad-data*").c();
|
||||
cache.draw_large_polygon_ocean = intern_from_c(-1, 0, "draw-large-polygon-ocean").c();
|
||||
gLinkedFunctionTable.reg("render-ocean-quad", execute, 256);
|
||||
}
|
||||
|
||||
} // namespace render_ocean_quad
|
||||
} // namespace Mips2C
|
||||
// add render_ocean_quad::link to the link callback table for the object file.
|
||||
// FWD DEC:
|
||||
namespace render_ocean_quad { extern void link(); }
|
||||
@@ -0,0 +1,861 @@
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace method_14_ocean {
|
||||
struct Cache {
|
||||
void* ocean_wave_frames; // *ocean-wave-frames*
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
c->mtc1(f0, a2); // mtc1 f0, a2
|
||||
c->cvtws(f0, f0); // cvt.w.s f0, f0
|
||||
c->mfc1(t1, f0); // mfc1 t1, f0
|
||||
c->dsll(v1, t1, 10); // dsll v1, t1, 10
|
||||
c->daddu(v1, r0, v1); // daddu v1, r0, v1
|
||||
c->load_symbol2(t0, cache.ocean_wave_frames); // lw t0, *ocean-wave-frames*(s7)
|
||||
c->daddu(v1, v1, t0); // daddu v1, v1, t0
|
||||
c->daddiu(t0, t1, 1); // daddiu t0, t1, 1
|
||||
c->andi(t0, t0, 63); // andi t0, t0, 63
|
||||
c->dsll(t0, t0, 10); // dsll t0, t0, 10
|
||||
c->daddu(t0, r0, t0); // daddu t0, r0, t0
|
||||
c->load_symbol2(t2, cache.ocean_wave_frames); // lw t2, *ocean-wave-frames*(s7)
|
||||
c->daddu(t0, t0, t2); // daddu t0, t0, t2
|
||||
c->mtc1(f0, a2); // mtc1 f0, a2
|
||||
c->mtc1(f1, t1); // mtc1 f1, t1
|
||||
c->cvtsw(f1, f1); // cvt.s.w f1, f1
|
||||
c->subs(f0, f0, f1); // sub.s f0, f0, f1
|
||||
c->swc1(f0, 148, a0); // swc1 f0, 148(a0)
|
||||
c->lui(a2, 16256); // lui a2, 16256
|
||||
c->mtc1(f0, a2); // mtc1 f0, a2
|
||||
c->lwc1(f1, 148, a0); // lwc1 f1, 148(a0)
|
||||
c->subs(f0, f0, f1); // sub.s f0, f0, f1
|
||||
c->swc1(f0, 144, a0); // swc1 f0, 144(a0)
|
||||
c->lwc1(f0, 144, a0); // lwc1 f0, 144(a0)
|
||||
c->mtc1(f1, a3); // mtc1 f1, a3
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 144, a0); // swc1 f0, 144(a0)
|
||||
c->lwc1(f0, 148, a0); // lwc1 f0, 148(a0)
|
||||
c->mtc1(f1, a3); // mtc1 f1, a3
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 148, a0); // swc1 f0, 148(a0)
|
||||
c->addiu(a2, r0, 32); // addiu a2, r0, 32
|
||||
c->lqc2(vf1, 144, a0); // lqc2 vf1, 144(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lw(a0, 0, v1); // lw a0, 0(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lw(a3, 0, t0); // lw a3, 0(t0)
|
||||
|
||||
block_1:
|
||||
c->pextlb(t1, a0, r0); // pextlb t1, a0, r0
|
||||
c->lw(a0, 4, v1); // lw a0, 4(v1)
|
||||
c->pextlb(t2, a3, r0); // pextlb t2, a3, r0
|
||||
c->lw(a3, 4, t0); // lw a3, 4(t0)
|
||||
c->pextlb(t3, a0, r0); // pextlb t3, a0, r0
|
||||
c->lw(a0, 8, v1); // lw a0, 8(v1)
|
||||
c->pextlb(t4, a3, r0); // pextlb t4, a3, r0
|
||||
c->lw(a3, 8, t0); // lw a3, 8(t0)
|
||||
c->pextlh(t5, t1, r0); // pextlh t5, t1, r0
|
||||
c->lw(t1, 12, v1); // lw t1, 12(v1)
|
||||
c->pextlh(t6, t2, r0); // pextlh t6, t2, r0
|
||||
c->lw(t2, 12, t0); // lw t2, 12(t0)
|
||||
c->pextlh(t3, t3, r0); // pextlh t3, t3, r0
|
||||
c->mov128_vf_gpr(vf2, t5); // qmtc2.i vf2, t5
|
||||
c->pextlh(t4, t4, r0); // pextlh t4, t4, r0
|
||||
c->mov128_vf_gpr(vf10, t6); // qmtc2.i vf10, t6
|
||||
c->pextlb(a0, a0, r0); // pextlb a0, a0, r0
|
||||
c->mov128_vf_gpr(vf3, t3); // qmtc2.i vf3, t3
|
||||
c->pextlb(a3, a3, r0); // pextlb a3, a3, r0
|
||||
c->mov128_vf_gpr(vf11, t4); // qmtc2.i vf11, t4
|
||||
c->pextlb(t4, t1, r0); // pextlb t4, t1, r0
|
||||
c->vitof15(DEST::xyzw, vf2, vf2); // vitof15.xyzw vf2, vf2
|
||||
c->pextlb(t3, t2, r0); // pextlb t3, t2, r0
|
||||
c->vitof15(DEST::xyzw, vf10, vf10); // vitof15.xyzw vf10, vf10
|
||||
c->pextlh(a0, a0, r0); // pextlh a0, a0, r0
|
||||
c->vitof15(DEST::xyzw, vf3, vf3); // vitof15.xyzw vf3, vf3
|
||||
c->pextlh(t1, a3, r0); // pextlh t1, a3, r0
|
||||
c->vitof15(DEST::xyzw, vf11, vf11); // vitof15.xyzw vf11, vf11
|
||||
c->pextlh(t2, t4, r0); // pextlh t2, t4, r0
|
||||
c->lw(t5, 16, v1); // lw t5, 16(v1)
|
||||
c->pextlh(t3, t3, r0); // pextlh t3, t3, r0
|
||||
c->lw(t6, 16, t0); // lw t6, 16(t0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf2, vf1); // vmulax.xyzw acc, vf2, vf1
|
||||
c->lw(t4, 20, v1); // lw t4, 20(v1)
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf2, vf10, vf1); // vmaddy.xyzw vf2, vf10, vf1
|
||||
c->lw(a3, 20, t0); // lw a3, 20(t0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf3, vf1); // vmulax.xyzw acc, vf3, vf1
|
||||
c->mov128_vf_gpr(vf4, a0); // qmtc2.i vf4, a0
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf3, vf11, vf1); // vmaddy.xyzw vf3, vf11, vf1
|
||||
c->mov128_vf_gpr(vf12, t1); // qmtc2.i vf12, t1
|
||||
c->pextlb(a0, t5, r0); // pextlb a0, t5, r0
|
||||
c->mov128_vf_gpr(vf5, t2); // qmtc2.i vf5, t2
|
||||
c->pextlb(t1, t6, r0); // pextlb t1, t6, r0
|
||||
c->mov128_vf_gpr(vf13, t3); // qmtc2.i vf13, t3
|
||||
c->pextlb(t2, t4, r0); // pextlb t2, t4, r0
|
||||
c->vitof15(DEST::xyzw, vf4, vf4); // vitof15.xyzw vf4, vf4
|
||||
c->pextlb(a3, a3, r0); // pextlb a3, a3, r0
|
||||
c->vitof15(DEST::xyzw, vf12, vf12); // vitof15.xyzw vf12, vf12
|
||||
c->pextlh(a0, a0, r0); // pextlh a0, a0, r0
|
||||
c->vitof15(DEST::xyzw, vf5, vf5); // vitof15.xyzw vf5, vf5
|
||||
c->pextlh(t1, t1, r0); // pextlh t1, t1, r0
|
||||
c->vitof15(DEST::xyzw, vf13, vf13); // vitof15.xyzw vf13, vf13
|
||||
c->pextlh(t2, t2, r0); // pextlh t2, t2, r0
|
||||
c->lw(t5, 24, v1); // lw t5, 24(v1)
|
||||
c->pextlh(t3, a3, r0); // pextlh t3, a3, r0
|
||||
c->lw(t6, 24, t0); // lw t6, 24(t0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf4, vf1); // vmulax.xyzw acc, vf4, vf1
|
||||
c->lw(t4, 28, v1); // lw t4, 28(v1)
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf4, vf12, vf1); // vmaddy.xyzw vf4, vf12, vf1
|
||||
c->lw(a3, 28, t0); // lw a3, 28(t0)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf5, vf1); // vmulax.xyzw acc, vf5, vf1
|
||||
c->mov128_vf_gpr(vf6, a0); // qmtc2.i vf6, a0
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf5, vf13, vf1); // vmaddy.xyzw vf5, vf13, vf1
|
||||
c->mov128_vf_gpr(vf14, t1); // qmtc2.i vf14, t1
|
||||
c->pextlb(a0, t5, r0); // pextlb a0, t5, r0
|
||||
c->mov128_vf_gpr(vf7, t2); // qmtc2.i vf7, t2
|
||||
c->pextlb(t1, t6, r0); // pextlb t1, t6, r0
|
||||
c->mov128_vf_gpr(vf15, t3); // qmtc2.i vf15, t3
|
||||
c->pextlb(t2, t4, r0); // pextlb t2, t4, r0
|
||||
c->vitof15(DEST::xyzw, vf6, vf6); // vitof15.xyzw vf6, vf6
|
||||
c->pextlb(a3, a3, r0); // pextlb a3, a3, r0
|
||||
c->vitof15(DEST::xyzw, vf14, vf14); // vitof15.xyzw vf14, vf14
|
||||
c->pextlh(a0, a0, r0); // pextlh a0, a0, r0
|
||||
c->vitof15(DEST::xyzw, vf7, vf7); // vitof15.xyzw vf7, vf7
|
||||
c->pextlh(t1, t1, r0); // pextlh t1, t1, r0
|
||||
c->vitof15(DEST::xyzw, vf15, vf15); // vitof15.xyzw vf15, vf15
|
||||
c->pextlh(t2, t2, r0); // pextlh t2, t2, r0
|
||||
c->sqc2(vf2, 0, a1); // sqc2 vf2, 0(a1)
|
||||
c->pextlh(a3, a3, r0); // pextlh a3, a3, r0
|
||||
c->sqc2(vf3, 16, a1); // sqc2 vf3, 16(a1)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf6, vf1); // vmulax.xyzw acc, vf6, vf1
|
||||
c->sqc2(vf4, 32, a1); // sqc2 vf4, 32(a1)
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf6, vf14, vf1); // vmaddy.xyzw vf6, vf14, vf1
|
||||
c->sqc2(vf5, 48, a1); // sqc2 vf5, 48(a1)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf7, vf1); // vmulax.xyzw acc, vf7, vf1
|
||||
c->mov128_vf_gpr(vf8, a0); // qmtc2.i vf8, a0
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf7, vf15, vf1); // vmaddy.xyzw vf7, vf15, vf1
|
||||
c->mov128_vf_gpr(vf16, t1); // qmtc2.i vf16, t1
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_vf_gpr(vf9, t2); // qmtc2.i vf9, t2
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_vf_gpr(vf17, a3); // qmtc2.i vf17, a3
|
||||
// nop // sll r0, r0, 0
|
||||
c->vitof15(DEST::xyzw, vf8, vf8); // vitof15.xyzw vf8, vf8
|
||||
c->daddiu(a1, a1, 128); // daddiu a1, a1, 128
|
||||
c->vitof15(DEST::xyzw, vf16, vf16); // vitof15.xyzw vf16, vf16
|
||||
c->lw(a0, 32, v1); // lw a0, 32(v1)
|
||||
c->vitof15(DEST::xyzw, vf9, vf9); // vitof15.xyzw vf9, vf9
|
||||
c->lw(a3, 32, t0); // lw a3, 32(t0)
|
||||
c->vitof15(DEST::xyzw, vf17, vf17); // vitof15.xyzw vf17, vf17
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf8, vf1); // vmulax.xyzw acc, vf8, vf1
|
||||
c->sqc2(vf6, -64, a1); // sqc2 vf6, -64(a1)
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf8, vf16, vf1); // vmaddy.xyzw vf8, vf16, vf1
|
||||
c->sqc2(vf7, -48, a1); // sqc2 vf7, -48(a1)
|
||||
c->vmula_bc(DEST::xyzw, BC::x, vf9, vf1); // vmulax.xyzw acc, vf9, vf1
|
||||
c->daddiu(a2, a2, -1); // daddiu a2, a2, -1
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf9, vf17, vf1); // vmaddy.xyzw vf9, vf17, vf1
|
||||
c->daddiu(v1, v1, 32); // daddiu v1, v1, 32
|
||||
// nop // sll r0, r0, 0
|
||||
c->daddiu(t0, t0, 32); // daddiu t0, t0, 32
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf8, -32, a1); // sqc2 vf8, -32(a1)
|
||||
bc = ((s64)c->sgpr64(a2)) > 0; // bgtz a2, L16
|
||||
c->sqc2(vf9, -16, a1); // sqc2 vf9, -16(a1)
|
||||
if (bc) {goto block_1;} // branch non-likely
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
c->gprs[v1].du64[0] = 0; // or v1, r0, r0
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.ocean_wave_frames = intern_from_c(-1, 0, "*ocean-wave-frames*").c();
|
||||
gLinkedFunctionTable.reg("(method 14 ocean)", execute, 256);
|
||||
}
|
||||
|
||||
} // namespace method_14_ocean
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace method_15_ocean {
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov64(v1, a1); // or v1, a1, r0
|
||||
c->mov64(a0, a2); // or a0, a2, r0
|
||||
c->addiu(a1, r0, 64); // addiu a1, r0, 64
|
||||
// nop // sll r0, r0, 0
|
||||
|
||||
block_1:
|
||||
c->lqc2(vf1, 0, v1); // lqc2 vf1, 0(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf2, 16, v1); // lqc2 vf2, 16(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf3, 32, v1); // lqc2 vf3, 32(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf4, 48, v1); // lqc2 vf4, 48(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf5, 0, a0); // lqc2 vf5, 0(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf6, 16, a0); // lqc2 vf6, 16(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf7, 32, a0); // lqc2 vf7, 32(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf8, 48, a0); // lqc2 vf8, 48(a0)
|
||||
// nop // sll r0, r0, 0
|
||||
c->vadd(DEST::xyzw, vf1, vf1, vf5); // vadd.xyzw vf1, vf1, vf5
|
||||
// nop // sll r0, r0, 0
|
||||
c->vadd(DEST::xyzw, vf2, vf2, vf6); // vadd.xyzw vf2, vf2, vf6
|
||||
// nop // sll r0, r0, 0
|
||||
c->vadd(DEST::xyzw, vf3, vf3, vf7); // vadd.xyzw vf3, vf3, vf7
|
||||
// nop // sll r0, r0, 0
|
||||
c->vadd(DEST::xyzw, vf4, vf4, vf8); // vadd.xyzw vf4, vf4, vf8
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf1, 0, v1); // sqc2 vf1, 0(v1)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sqc2(vf2, 16, v1); // sqc2 vf2, 16(v1)
|
||||
c->daddiu(a1, a1, -1); // daddiu a1, a1, -1
|
||||
c->sqc2(vf3, 32, v1); // sqc2 vf3, 32(v1)
|
||||
c->daddiu(v1, v1, 64); // daddiu v1, v1, 64
|
||||
bc = ((s64)c->sgpr64(a1)) > 0; // bgtz a1, L14
|
||||
c->sqc2(vf4, -16, v1); // sqc2 vf4, -16(v1)
|
||||
if (bc) {goto block_1;} // branch non-likely
|
||||
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
gLinkedFunctionTable.reg("(method 15 ocean)", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace method_15_ocean
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace method_16_ocean {
|
||||
struct Cache {
|
||||
void* level; // *level*
|
||||
void* time_of_day_context; // *time-of-day-context*
|
||||
void* ocean_vu0_block; // ocean-vu0-block
|
||||
void* sewerb; // sewerb
|
||||
void* upload_vu0_program; // upload-vu0-program
|
||||
void* vu_lights_light_group; // vu-lights<-light-group!
|
||||
void* ocean_generate_verts_vector;
|
||||
} cache;
|
||||
|
||||
void vcallms0(ExecutionContext* c) {
|
||||
// nop | mulay.x ACC, vf12, vf02 0
|
||||
c->acc.vf.mula(Mask::x, c->vf_src(vf12).vf, c->vf_src(vf02).vf.y());
|
||||
// nop | mulax.z ACC, vf12, vf03 1
|
||||
c->acc.vf.mula(Mask::z, c->vf_src(vf12).vf, c->vf_src(vf03).vf.x());
|
||||
// nop | msubx.xz vf24, vf12, vf02 2
|
||||
// ASSERT(false);
|
||||
c->acc.vf.msub(Mask::xz, c->vfs[vf24].vf, c->vf_src(vf12).vf, c->vf_src(vf02).vf.x());
|
||||
// nop | mulaz.x ACC, vf12, vf02 3
|
||||
c->acc.vf.mula(Mask::x, c->vf_src(vf12).vf, c->vf_src(vf02).vf.z());
|
||||
// nop | mulay.z ACC, vf12, vf03 4
|
||||
c->acc.vf.mula(Mask::z, c->vf_src(vf12).vf, c->vf_src(vf03).vf.y());
|
||||
// nop | msuby.xz vf25, vf12, vf02 5
|
||||
// ASSERT(false);
|
||||
c->acc.vf.msub(Mask::xz, c->vfs[vf25].vf, c->vf_src(vf12).vf, c->vf_src(vf02).vf.y());
|
||||
// nop | mulaw.x ACC, vf12, vf02 6
|
||||
c->acc.vf.mula(Mask::x, c->vf_src(vf12).vf, c->vf_src(vf02).vf.w());
|
||||
// nop | mulaz.z ACC, vf12, vf03 7
|
||||
c->acc.vf.mula(Mask::z, c->vf_src(vf12).vf, c->vf_src(vf03).vf.z());
|
||||
// nop | msubz.xz vf26, vf12, vf02 8
|
||||
// ASSERT(false);
|
||||
c->acc.vf.msub(Mask::xz, c->vfs[vf26].vf, c->vf_src(vf12).vf, c->vf_src(vf02).vf.z());
|
||||
// nop | mulax.x ACC, vf12, vf04 9
|
||||
c->acc.vf.mula(Mask::x, c->vf_src(vf12).vf, c->vf_src(vf04).vf.x());
|
||||
// nop | mulaw.z ACC, vf12, vf03 10
|
||||
c->acc.vf.mula(Mask::z, c->vf_src(vf12).vf, c->vf_src(vf03).vf.w());
|
||||
// nop | msubw.xz vf27, vf12, vf02 11
|
||||
// ASSERT(false);
|
||||
c->acc.vf.msub(Mask::xz, c->vfs[vf27].vf, c->vf_src(vf12).vf, c->vf_src(vf02).vf.w());
|
||||
// nop | mul.xz vf28, vf24, vf24 12
|
||||
c->vfs[vf28].vf.mul(Mask::xz, c->vf_src(vf24).vf, c->vf_src(vf24).vf);
|
||||
// nop | mul.xz vf29, vf25, vf25 13
|
||||
c->vfs[vf29].vf.mul(Mask::xz, c->vf_src(vf25).vf, c->vf_src(vf25).vf);
|
||||
// nop | mul.xz vf30, vf26, vf26 14
|
||||
c->vfs[vf30].vf.mul(Mask::xz, c->vf_src(vf26).vf, c->vf_src(vf26).vf);
|
||||
// nop | mul.xz vf31, vf27, vf27 15
|
||||
c->vfs[vf31].vf.mul(Mask::xz, c->vf_src(vf27).vf, c->vf_src(vf27).vf);
|
||||
// nop | subx.y vf24, vf01, vf28 16
|
||||
c->vfs[vf24].vf.sub(Mask::y, c->vf_src(vf01).vf, c->vf_src(vf28).vf.x());
|
||||
// nop | subx.y vf25, vf01, vf29 17
|
||||
c->vfs[vf25].vf.sub(Mask::y, c->vf_src(vf01).vf, c->vf_src(vf29).vf.x());
|
||||
// nop | subx.y vf26, vf01, vf30 18
|
||||
c->vfs[vf26].vf.sub(Mask::y, c->vf_src(vf01).vf, c->vf_src(vf30).vf.x());
|
||||
// nop | subx.y vf27, vf01, vf31 19
|
||||
c->vfs[vf27].vf.sub(Mask::y, c->vf_src(vf01).vf, c->vf_src(vf31).vf.x());
|
||||
// nop | subz.y vf24, vf24, vf28 20
|
||||
c->vfs[vf24].vf.sub(Mask::y, c->vf_src(vf24).vf, c->vf_src(vf28).vf.z());
|
||||
// nop | subz.y vf25, vf25, vf29 21
|
||||
c->vfs[vf25].vf.sub(Mask::y, c->vf_src(vf25).vf, c->vf_src(vf29).vf.z());
|
||||
// nop | subz.y vf26, vf26, vf30 22
|
||||
c->vfs[vf26].vf.sub(Mask::y, c->vf_src(vf26).vf, c->vf_src(vf30).vf.z());
|
||||
// nop | subz.y vf27, vf27, vf31 23
|
||||
c->vfs[vf27].vf.sub(Mask::y, c->vf_src(vf27).vf, c->vf_src(vf31).vf.z());
|
||||
// nop | mulx.w vf24, vf01, vf02 24
|
||||
c->vfs[vf24].vf.mul(Mask::w, c->vf_src(vf01).vf, c->vf_src(vf02).vf.x());
|
||||
// nop | muly.w vf25, vf01, vf02 25
|
||||
c->vfs[vf25].vf.mul(Mask::w, c->vf_src(vf01).vf, c->vf_src(vf02).vf.y());
|
||||
// nop | mulz.w vf26, vf01, vf02 26
|
||||
c->vfs[vf26].vf.mul(Mask::w, c->vf_src(vf01).vf, c->vf_src(vf02).vf.z());
|
||||
// nop | mulw.w vf27, vf01, vf02 27
|
||||
c->vfs[vf27].vf.mul(Mask::w, c->vf_src(vf01).vf, c->vf_src(vf02).vf.w());
|
||||
// nop | mulax.xyzw ACC, vf05, vf24 28
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf05).vf, c->vf_src(vf24).vf.x());
|
||||
// nop | madday.xyzw ACC, vf06, vf24 29
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf06].vf, c->vfs[vf24].vf.y());
|
||||
// nop | maddz.xyz vf16, vf07, vf24 30
|
||||
c->acc.vf.madd(Mask::xyz, c->vfs[vf16].vf, c->vf_src(vf07).vf, c->vf_src(vf24).vf.z());
|
||||
// nop | mulax.xyzw ACC, vf05, vf25 31
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf05).vf, c->vf_src(vf25).vf.x());
|
||||
// nop | madday.xyzw ACC, vf06, vf25 32
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf06].vf, c->vfs[vf25].vf.y());
|
||||
// nop | maddz.xyz vf17, vf07, vf25 33
|
||||
c->acc.vf.madd(Mask::xyz, c->vfs[vf17].vf, c->vf_src(vf07).vf, c->vf_src(vf25).vf.z());
|
||||
// nop | mulax.xyzw ACC, vf05, vf26 34
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf05).vf, c->vf_src(vf26).vf.x());
|
||||
// nop | madday.xyzw ACC, vf06, vf26 35
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf06].vf, c->vfs[vf26].vf.y());
|
||||
// nop | maddz.xyz vf18, vf07, vf26 36
|
||||
c->acc.vf.madd(Mask::xyz, c->vfs[vf18].vf, c->vf_src(vf07).vf, c->vf_src(vf26).vf.z());
|
||||
// nop | mulax.xyzw ACC, vf05, vf27 37
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf05).vf, c->vf_src(vf27).vf.x());
|
||||
// nop | madday.xyzw ACC, vf06, vf27 38
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf06].vf, c->vfs[vf27].vf.y());
|
||||
// nop | maddz.xyz vf19, vf07, vf27 39
|
||||
c->acc.vf.madd(Mask::xyz, c->vfs[vf19].vf, c->vf_src(vf07).vf, c->vf_src(vf27).vf.z());
|
||||
// nop | maxx.xyz vf16, vf16, vf00 40
|
||||
c->vfs[vf16].vf.max(Mask::xyz, c->vf_src(vf16).vf, c->vf_src(vf00).vf.x());
|
||||
// nop | maxx.xyz vf17, vf17, vf00 41
|
||||
c->vfs[vf17].vf.max(Mask::xyz, c->vf_src(vf17).vf, c->vf_src(vf00).vf.x());
|
||||
// nop | maxx.xyz vf18, vf18, vf00 42
|
||||
c->vfs[vf18].vf.max(Mask::xyz, c->vf_src(vf18).vf, c->vf_src(vf00).vf.x());
|
||||
// nop | maxx.xyz vf19, vf19, vf00 43
|
||||
c->vfs[vf19].vf.max(Mask::xyz, c->vf_src(vf19).vf, c->vf_src(vf00).vf.x());
|
||||
// nop | mula.xyzw ACC, vf01, vf11 44
|
||||
// vu.acc.mula(Mask::xyzw, vu.vf01, vu.vf11);
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf01).vf, c->vf_src(vf11).vf);
|
||||
// nop | maddax.xyzw ACC, vf08, vf16 45
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf08].vf, c->vfs[vf16].vf.x());
|
||||
// nop | madday.xyzw ACC, vf09, vf16 46
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf09].vf, c->vfs[vf16].vf.y());
|
||||
// nop | maddz.xyzw vf20, vf10, vf16 47
|
||||
c->acc.vf.madd(Mask::xyzw, c->vfs[vf20].vf, c->vf_src(vf10).vf, c->vf_src(vf16).vf.z());
|
||||
// nop | mula.xyzw ACC, vf01, vf11 48
|
||||
// vu.acc.mula(Mask::xyzw, vu.vf01, vu.vf11);
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf01).vf, c->vf_src(vf11).vf);
|
||||
// nop | maddax.xyzw ACC, vf08, vf17 49
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf08].vf, c->vfs[vf17].vf.x());
|
||||
// nop | madday.xyzw ACC, vf09, vf17 50
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf09].vf, c->vfs[vf17].vf.y());
|
||||
// nop | maddz.xyzw vf21, vf10, vf17 51
|
||||
c->acc.vf.madd(Mask::xyzw, c->vfs[vf21].vf, c->vf_src(vf10).vf, c->vf_src(vf17).vf.z());
|
||||
// nop | mula.xyzw ACC, vf01, vf11 52
|
||||
// vu.acc.mula(Mask::xyzw, vu.vf01, vu.vf11);
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf01).vf, c->vf_src(vf11).vf);
|
||||
// nop | maddax.xyzw ACC, vf08, vf18 53
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf08].vf, c->vfs[vf18].vf.x());
|
||||
// nop | madday.xyzw ACC, vf09, vf18 54
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf09].vf, c->vfs[vf18].vf.y());
|
||||
// nop | maddz.xyzw vf22, vf10, vf18 55
|
||||
c->acc.vf.madd(Mask::xyzw, c->vfs[vf22].vf, c->vf_src(vf10).vf, c->vf_src(vf18).vf.z());
|
||||
// nop | mula.xyzw ACC, vf01, vf11 56
|
||||
// vu.acc.mula(Mask::xyzw, vu.vf01, vu.vf11);
|
||||
c->acc.vf.mula(Mask::xyzw, c->vf_src(vf01).vf, c->vf_src(vf11).vf);
|
||||
// nop | maddax.xyzw ACC, vf08, vf19 57
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf08].vf, c->vfs[vf19].vf.x());
|
||||
// nop | madday.xyzw ACC, vf09, vf19 58
|
||||
c->acc.vf.madda(Mask::xyzw, c->vfs[vf09].vf, c->vfs[vf19].vf.y());
|
||||
// nop | maddz.xyzw vf23, vf10, vf19 59
|
||||
c->acc.vf.madd(Mask::xyzw, c->vfs[vf23].vf, c->vf_src(vf10).vf, c->vf_src(vf19).vf.z());
|
||||
// nop | miniy.xyzw vf20, vf20, vf12 60
|
||||
c->vfs[vf20].vf.mini(Mask::xyzw, c->vf_src(vf20).vf, c->vf_src(vf12).vf.y());
|
||||
// nop | miniy.xyzw vf21, vf21, vf12 61
|
||||
c->vfs[vf21].vf.mini(Mask::xyzw, c->vf_src(vf21).vf, c->vf_src(vf12).vf.y());
|
||||
// nop | miniy.xyzw vf22, vf22, vf12 :e 62
|
||||
c->vfs[vf22].vf.mini(Mask::xyzw, c->vf_src(vf22).vf, c->vf_src(vf12).vf.y());
|
||||
// nop | miniy.xyzw vf23, vf23, vf12 63
|
||||
c->vfs[vf23].vf.mini(Mask::xyzw, c->vf_src(vf23).vf, c->vf_src(vf12).vf.y());
|
||||
}
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
u32 call_addr = 0;
|
||||
bool cop1_bc = false;
|
||||
c->daddiu(sp, sp, -80); // daddiu sp, sp, -80
|
||||
c->sd(ra, 0, sp); // sd ra, 0(sp)
|
||||
c->sd(fp, 8, sp); // sd fp, 8(sp)
|
||||
c->mov64(fp, t9); // or fp, t9, r0
|
||||
c->sq(s4, 32, sp); // sq s4, 32(sp)
|
||||
c->sq(s5, 48, sp); // sq s5, 48(sp)
|
||||
c->sq(gp, 64, sp); // sq gp, 64(sp)
|
||||
c->mov64(s4, a0); // or s4, a0, r0
|
||||
c->mov64(s5, a1); // or s5, a1, r0
|
||||
c->mov64(gp, a2); // or gp, a2, r0
|
||||
c->load_symbol2(t9, cache.upload_vu0_program); // lw t9, upload-vu0-program(s7)
|
||||
c->load_symbol2(a0, cache.ocean_vu0_block); // lw a0, ocean-vu0-block(s7)
|
||||
c->daddiu(a1, s4, 8296); // daddiu a1, s4, 8296
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->load_symbol2(a0, cache.level); // lw a0, *level*(s7)
|
||||
c->lwu(v1, -4, a0); // lwu v1, -4(a0)
|
||||
c->lwu(t9, 52, v1); // lwu t9, 52(v1)
|
||||
c->load_symbol_addr(a1, cache.sewerb); // daddiu a1, s7, sewerb
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mov64(v1, v0); // or v1, v0, r0
|
||||
bc = c->sgpr64(s7) == c->sgpr64(v1); // beq s7, v1, L2
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_2;} // branch non-likely
|
||||
|
||||
c->load_symbol2(t9, cache.vu_lights_light_group);// lw t9, vu-lights<-light-group!(s7)
|
||||
c->daddiu(a0, s4, 8144); // daddiu a0, s4, 8144
|
||||
c->daddiu(a1, v1, 796); // daddiu a1, v1, 796
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mov64(v1, v0); // or v1, v0, r0
|
||||
//beq r0, r0, L3 // beq r0, r0, L3
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_3; // branch always
|
||||
|
||||
|
||||
block_2:
|
||||
c->load_symbol2(t9, cache.vu_lights_light_group);// lw t9, vu-lights<-light-group!(s7)
|
||||
c->daddiu(a0, s4, 8144); // daddiu a0, s4, 8144
|
||||
c->load_symbol2(v1, cache.time_of_day_context); // lw v1, *time-of-day-context*(s7)
|
||||
c->daddiu(a1, v1, 156); // daddiu a1, v1, 156
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mov64(v1, v0); // or v1, v0, r0
|
||||
|
||||
block_3:
|
||||
c->daddiu(v1, sp, 16); // daddiu v1, sp, 16
|
||||
c->mov64(a2, v1); // or a2, v1, r0
|
||||
c->daddiu(a0, s4, 8192); // daddiu a0, s4, 8192
|
||||
c->daddiu(a1, s4, 8208); // daddiu a1, s4, 8208
|
||||
c->vmove(DEST::w, vf6, vf0); // vmove.w vf6, vf0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd(DEST::xyz, vf6, vf4, vf5); // vadd.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->mov64(a2, v1); // or a2, v1, r0
|
||||
c->mov64(a0, v1); // or a0, v1, r0
|
||||
c->daddiu(a1, s4, 8224); // daddiu a1, s4, 8224
|
||||
c->vmove(DEST::w, vf6, vf0); // vmove.w vf6, vf0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd(DEST::xyz, vf6, vf4, vf5); // vadd.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->mov64(a2, v1); // or a2, v1, r0
|
||||
c->mov64(a0, v1); // or a0, v1, r0
|
||||
c->daddiu(a1, s4, 8240); // daddiu a1, s4, 8240
|
||||
c->vmove(DEST::w, vf6, vf0); // vmove.w vf6, vf0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd(DEST::xyz, vf6, vf4, vf5); // vadd.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->lui(a0, 16288); // lui a0, 16288
|
||||
c->mtc1(f0, a0); // mtc1 f0, a0
|
||||
c->lwc1(f1, 0, v1); // lwc1 f1, 0(v1)
|
||||
cop1_bc = c->fprs[f0] < c->fprs[f1]; // c.lt.s f0, f1
|
||||
bc = cop1_bc; // bc1t L4
|
||||
c->daddiu(a0, s7, 4); // daddiu a0, s7, 4
|
||||
if (bc) {goto block_5;} // branch non-likely
|
||||
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
|
||||
block_5:
|
||||
if (((s64)c->sgpr64(s7)) != ((s64)c->sgpr64(a0))) {// bnel s7, a0, L6
|
||||
c->mov64(a0, a0); // or a0, a0, r0
|
||||
goto block_13;
|
||||
}
|
||||
|
||||
|
||||
c->lui(a0, 16288); // lui a0, 16288
|
||||
c->mtc1(f0, a0); // mtc1 f0, a0
|
||||
c->lwc1(f1, 4, v1); // lwc1 f1, 4(v1)
|
||||
cop1_bc = c->fprs[f0] < c->fprs[f1]; // c.lt.s f0, f1
|
||||
bc = cop1_bc; // bc1t L5
|
||||
c->daddiu(a0, s7, 4); // daddiu a0, s7, 4
|
||||
if (bc) {goto block_9;} // branch non-likely
|
||||
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
|
||||
block_9:
|
||||
if (((s64)c->sgpr64(s7)) != ((s64)c->sgpr64(a0))) {// bnel s7, a0, L6
|
||||
c->mov64(a0, a0); // or a0, a0, r0
|
||||
goto block_13;
|
||||
}
|
||||
|
||||
c->lui(a0, 16288); // lui a0, 16288
|
||||
c->mtc1(f0, a0); // mtc1 f0, a0
|
||||
c->lwc1(f1, 8, v1); // lwc1 f1, 8(v1)
|
||||
cop1_bc = c->fprs[f0] < c->fprs[f1]; // c.lt.s f0, f1
|
||||
bc = cop1_bc; // bc1t L6
|
||||
c->daddiu(a0, s7, 4); // daddiu a0, s7, 4
|
||||
if (bc) {goto block_13;} // branch non-likely
|
||||
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
|
||||
block_13:
|
||||
bc = c->sgpr64(s7) == c->sgpr64(a0); // beq s7, a0, L10
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
if (bc) {goto block_20;} // branch non-likely
|
||||
|
||||
c->mtc1(f0, r0); // mtc1 f0, r0
|
||||
c->mtc1(f0, r0); // mtc1 f0, r0
|
||||
c->lwc1(f0, 4, v1); // lwc1 f0, 4(v1)
|
||||
c->lwc1(f1, 0, v1); // lwc1 f1, 0(v1)
|
||||
cop1_bc = c->fprs[f0] < c->fprs[f1]; // c.lt.s f0, f1
|
||||
bc = !cop1_bc; // bc1f L7
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_16;} // branch non-likely
|
||||
|
||||
c->lwc1(f0, 0, v1); // lwc1 f0, 0(v1)
|
||||
c->lwc1(f1, 8240, s4); // lwc1 f1, 8240(s4)
|
||||
c->mfc1(a0, f1); // mfc1 a0, f1
|
||||
//beq r0, r0, L8 // beq r0, r0, L8
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_17; // branch always
|
||||
|
||||
|
||||
block_16:
|
||||
c->lwc1(f0, 4, v1); // lwc1 f0, 4(v1)
|
||||
c->lwc1(f1, 8244, s4); // lwc1 f1, 8244(s4)
|
||||
c->mfc1(a0, f1); // mfc1 a0, f1
|
||||
|
||||
block_17:
|
||||
c->lwc1(f2, 8, v1); // lwc1 f2, 8(v1)
|
||||
cop1_bc = c->fprs[f0] < c->fprs[f2]; // c.lt.s f0, f2
|
||||
bc = !cop1_bc; // bc1f L9
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
if (bc) {goto block_19;} // branch non-likely
|
||||
|
||||
c->lwc1(f0, 8, v1); // lwc1 f0, 8(v1)
|
||||
c->lwc1(f1, 8248, s4); // lwc1 f1, 8248(s4)
|
||||
c->mfc1(v1, f1); // mfc1 v1, f1
|
||||
|
||||
block_19:
|
||||
c->lui(v1, 16288); // lui v1, 16288
|
||||
c->mtc1(f2, v1); // mtc1 f2, v1
|
||||
c->subs(f2, f2, f1); // sub.s f2, f2, f1
|
||||
c->subs(f0, f0, f1); // sub.s f0, f0, f1
|
||||
c->divs(f0, f2, f0); // div.s f0, f2, f0
|
||||
c->daddiu(v1, s4, 8192); // daddiu v1, s4, 8192
|
||||
c->daddiu(a0, s4, 8192); // daddiu a0, s4, 8192
|
||||
c->movs(f1, f0); // mov.s f1, f0
|
||||
c->lqc2(vf1, 0, a0); // lqc2 vf1, 0(a0)
|
||||
c->mfc1(a0, f1); // mfc1 a0, f1
|
||||
c->mov128_vf_gpr(vf2, a0); // qmtc2.i vf2, a0
|
||||
c->vadd_bc(DEST::w, BC::x, vf1, vf0, vf0); // vaddx.w vf1, vf0, vf0
|
||||
c->vmul_bc(DEST::xyz, BC::x, vf1, vf1, vf2); // vmulx.xyz vf1, vf1, vf2
|
||||
c->sqc2(vf1, 0, v1); // sqc2 vf1, 0(v1)
|
||||
c->daddiu(v1, s4, 8208); // daddiu v1, s4, 8208
|
||||
c->daddiu(a0, s4, 8208); // daddiu a0, s4, 8208
|
||||
c->movs(f1, f0); // mov.s f1, f0
|
||||
c->lqc2(vf1, 0, a0); // lqc2 vf1, 0(a0)
|
||||
c->mfc1(a0, f1); // mfc1 a0, f1
|
||||
c->mov128_vf_gpr(vf2, a0); // qmtc2.i vf2, a0
|
||||
c->vadd_bc(DEST::w, BC::x, vf1, vf0, vf0); // vaddx.w vf1, vf0, vf0
|
||||
c->vmul_bc(DEST::xyz, BC::x, vf1, vf1, vf2); // vmulx.xyz vf1, vf1, vf2
|
||||
c->sqc2(vf1, 0, v1); // sqc2 vf1, 0(v1)
|
||||
c->daddiu(a0, s4, 8224); // daddiu a0, s4, 8224
|
||||
c->daddiu(v1, s4, 8224); // daddiu v1, s4, 8224
|
||||
c->lqc2(vf1, 0, v1); // lqc2 vf1, 0(v1)
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
c->mov128_vf_gpr(vf2, v1); // qmtc2.i vf2, v1
|
||||
c->vadd_bc(DEST::w, BC::x, vf1, vf0, vf0); // vaddx.w vf1, vf0, vf0
|
||||
c->vmul_bc(DEST::xyz, BC::x, vf1, vf1, vf2); // vmulx.xyz vf1, vf1, vf2
|
||||
c->sqc2(vf1, 0, a0); // sqc2 vf1, 0(a0)
|
||||
|
||||
block_20:
|
||||
// daddiu v1, fp, L18 // daddiu v1, fp, L18
|
||||
c->load_symbol2(v1, cache.ocean_generate_verts_vector); // HACK
|
||||
c->daddiu(a2, s4, 8192); // daddiu a2, s4, 8192
|
||||
c->daddiu(a0, s4, 8192); // daddiu a0, s4, 8192
|
||||
c->mov64(a1, v1); // or a1, v1, r0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd_bc(DEST::w, BC::x, vf6, vf0, vf0); // vaddx.w vf6, vf0, vf0
|
||||
c->vmul(DEST::xyz, vf6, vf4, vf5); // vmul.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->daddiu(a2, s4, 8208); // daddiu a2, s4, 8208
|
||||
c->daddiu(a0, s4, 8208); // daddiu a0, s4, 8208
|
||||
c->mov64(a1, v1); // or a1, v1, r0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd_bc(DEST::w, BC::x, vf6, vf0, vf0); // vaddx.w vf6, vf0, vf0
|
||||
c->vmul(DEST::xyz, vf6, vf4, vf5); // vmul.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->daddiu(a2, s4, 8224); // daddiu a2, s4, 8224
|
||||
c->daddiu(a0, s4, 8224); // daddiu a0, s4, 8224
|
||||
c->mov64(a1, v1); // or a1, v1, r0
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, a1); // lqc2 vf5, 0(a1)
|
||||
c->vadd_bc(DEST::w, BC::x, vf6, vf0, vf0); // vaddx.w vf6, vf0, vf0
|
||||
c->vmul(DEST::xyz, vf6, vf4, vf5); // vmul.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a2); // sqc2 vf6, 0(a2)
|
||||
c->daddiu(a1, s4, 8240); // daddiu a1, s4, 8240
|
||||
c->daddiu(a0, s4, 8240); // daddiu a0, s4, 8240
|
||||
c->lqc2(vf4, 0, a0); // lqc2 vf4, 0(a0)
|
||||
c->lqc2(vf5, 0, v1); // lqc2 vf5, 0(v1)
|
||||
c->vadd_bc(DEST::w, BC::x, vf6, vf0, vf0); // vaddx.w vf6, vf0, vf0
|
||||
c->vmul(DEST::xyz, vf6, vf4, vf5); // vmul.xyz vf6, vf4, vf5
|
||||
c->sqc2(vf6, 0, a1); // sqc2 vf6, 0(a1)
|
||||
c->lui(v1, 17152); // lui v1, 17152
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->swc1(f0, 8204, s4); // swc1 f0, 8204(s4)
|
||||
c->lui(v1, 17152); // lui v1, 17152
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->swc1(f0, 8220, s4); // swc1 f0, 8220(s4)
|
||||
c->lui(v1, 17152); // lui v1, 17152
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->swc1(f0, 8236, s4); // swc1 f0, 8236(s4)
|
||||
c->mtc1(f0, r0); // mtc1 f0, r0
|
||||
c->swc1(f0, 8252, s4); // swc1 f0, 8252(s4)
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
c->vmax_bc(DEST::xyzw, BC::w, vf1, vf0, vf0); // vmaxw.xyzw vf1, vf0, vf0
|
||||
c->lqc2(vf12, 8096, s4); // lqc2 vf12, 8096(s4)
|
||||
c->lqc2(vf5, 8144, s4); // lqc2 vf5, 8144(s4)
|
||||
c->lqc2(vf6, 8160, s4); // lqc2 vf6, 8160(s4)
|
||||
c->lqc2(vf7, 8176, s4); // lqc2 vf7, 8176(s4)
|
||||
c->lqc2(vf8, 8192, s4); // lqc2 vf8, 8192(s4)
|
||||
c->lqc2(vf9, 8208, s4); // lqc2 vf9, 8208(s4)
|
||||
c->lqc2(vf10, 8224, s4); // lqc2 vf10, 8224(s4)
|
||||
c->lqc2(vf11, 8240, s4); // lqc2 vf11, 8240(s4)
|
||||
c->addiu(v1, r0, 31); // addiu v1, r0, 31
|
||||
c->mov64(a0, gp); // or a0, gp, r0
|
||||
c->daddiu(a1, gp, 128); // daddiu a1, gp, 128
|
||||
// nop // sll r0, r0, 0
|
||||
|
||||
block_21:
|
||||
c->lqc2(vf2, 0, gp); // lqc2 vf2, 0(gp)
|
||||
c->addiu(t2, r0, 6); // addiu t2, r0, 6
|
||||
c->lqc2(vf3, 16, gp); // lqc2 vf3, 16(gp)
|
||||
c->daddiu(t5, gp, 16); // daddiu t5, gp, 16
|
||||
c->lqc2(vf4, 0, a1); // lqc2 vf4, 0(a1)
|
||||
c->daddiu(a1, a1, 16); // daddiu a1, a1, 16
|
||||
// Unknown instr: vcallms 0
|
||||
vcallms0(c);
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t1, vf20); // qmfc2.i t1, vf20
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t0, vf21); // qmfc2.i t0, vf21
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(a3, vf22); // qmfc2.i a3, vf22
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(a2, vf23); // qmfc2.i a2, vf23
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t6, vf24); // qmfc2.i t6, vf24
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t7, vf25); // qmfc2.i t7, vf25
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t3, vf26); // qmfc2.i t3, vf26
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t4, vf27); // qmfc2.i t4, vf27
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf2, 0, t5); // lqc2 vf2, 0(t5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->lqc2(vf3, 16, t5); // lqc2 vf3, 16(t5)
|
||||
c->daddiu(gp, t5, 16); // daddiu gp, t5, 16
|
||||
c->lqc2(vf4, 0, a1); // lqc2 vf4, 0(a1)
|
||||
c->daddiu(a1, a1, 16); // daddiu a1, a1, 16
|
||||
|
||||
block_22:
|
||||
// Unknown instr: vcallms 0
|
||||
vcallms0(c);
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextlw(t5, t7, t6); // pextlw t5, t7, t6
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t6, t7, t6); // pextuw t6, t7, t6
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextlw(t7, t4, t3); // pextlw t7, t4, t3
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t4, t4, t3); // pextuw t4, t4, t3
|
||||
// nop // sll r0, r0, 0
|
||||
c->pcpyld(t3, t7, t5); // pcpyld t3, t7, t5
|
||||
c->sq(t1, 0, s5); // sq t1, 0(s5)
|
||||
c->pcpyud(t1, t5, t7); // pcpyud t1, t5, t7
|
||||
c->sq(t0, 32, s5); // sq t0, 32(s5)
|
||||
c->pcpyld(t0, t4, t6); // pcpyld t0, t4, t6
|
||||
c->sq(a3, 64, s5); // sq a3, 64(s5)
|
||||
c->pcpyud(a3, t6, t4); // pcpyud a3, t6, t4
|
||||
c->sq(a2, 96, s5); // sq a2, 96(s5)
|
||||
c->sq(t3, 16, s5); // sq t3, 16(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t1, 48, s5); // sq t1, 48(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t0, 80, s5); // sq t0, 80(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(a3, 112, s5); // sq a3, 112(s5)
|
||||
c->daddiu(s5, s5, 128); // daddiu s5, s5, 128
|
||||
c->mov128_gpr_vf(t1, vf20); // qmfc2.i t1, vf20
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t0, vf21); // qmfc2.i t0, vf21
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(a3, vf22); // qmfc2.i a3, vf22
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(a2, vf23); // qmfc2.i a2, vf23
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t6, vf24); // qmfc2.i t6, vf24
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t7, vf25); // qmfc2.i t7, vf25
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t3, vf26); // qmfc2.i t3, vf26
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t4, vf27); // qmfc2.i t4, vf27
|
||||
c->daddiu(t2, t2, -1); // daddiu t2, t2, -1
|
||||
c->lqc2(vf2, 0, gp); // lqc2 vf2, 0(gp)
|
||||
c->daddiu(a1, a1, 16); // daddiu a1, a1, 16
|
||||
c->lqc2(vf3, 16, gp); // lqc2 vf3, 16(gp)
|
||||
c->daddiu(gp, gp, 16); // daddiu gp, gp, 16
|
||||
bc = ((s64)c->sgpr64(t2)) > 0; // bgtz t2, L12
|
||||
c->lqc2(vf4, -16, a1); // lqc2 vf4, -16(a1)
|
||||
if (bc) {goto block_22;} // branch non-likely
|
||||
|
||||
c->lqc2(vf3, -128, gp); // lqc2 vf3, -128(gp)
|
||||
// nop // sll r0, r0, 0
|
||||
// Unknown instr: vcallms 0
|
||||
vcallms0(c);
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextlw(t2, t7, t6); // pextlw t2, t7, t6
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t5, t7, t6); // pextuw t5, t7, t6
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextlw(t6, t4, t3); // pextlw t6, t4, t3
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t4, t4, t3); // pextuw t4, t4, t3
|
||||
// nop // sll r0, r0, 0
|
||||
c->pcpyld(t3, t6, t2); // pcpyld t3, t6, t2
|
||||
c->sq(t1, 0, s5); // sq t1, 0(s5)
|
||||
c->pcpyud(t1, t2, t6); // pcpyud t1, t2, t6
|
||||
c->sq(t0, 32, s5); // sq t0, 32(s5)
|
||||
c->pcpyld(t0, t4, t5); // pcpyld t0, t4, t5
|
||||
c->sq(a3, 64, s5); // sq a3, 64(s5)
|
||||
c->pcpyud(a3, t5, t4); // pcpyud a3, t5, t4
|
||||
c->sq(a2, 96, s5); // sq a2, 96(s5)
|
||||
c->sq(t3, 16, s5); // sq t3, 16(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t1, 48, s5); // sq t1, 48(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t0, 80, s5); // sq t0, 80(s5)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(a3, 112, s5); // sq a3, 112(s5)
|
||||
c->daddiu(a2, s5, 128); // daddiu a2, s5, 128
|
||||
c->mov128_gpr_vf(t2, vf20); // qmfc2.i t2, vf20
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t1, vf21); // qmfc2.i t1, vf21
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t0, vf22); // qmfc2.i t0, vf22
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(a3, vf23); // qmfc2.i a3, vf23
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t4, vf24); // qmfc2.i t4, vf24
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t7, vf25); // qmfc2.i t7, vf25
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t5, vf26); // qmfc2.i t5, vf26
|
||||
// nop // sll r0, r0, 0
|
||||
c->mov128_gpr_vf(t6, vf27); // qmfc2.i t6, vf27
|
||||
c->daddiu(v1, v1, -1); // daddiu v1, v1, -1
|
||||
c->pextlw(t3, t7, t4); // pextlw t3, t7, t4
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t4, t7, t4); // pextuw t4, t7, t4
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextlw(t7, t6, t5); // pextlw t7, t6, t5
|
||||
// nop // sll r0, r0, 0
|
||||
c->pextuw(t6, t6, t5); // pextuw t6, t6, t5
|
||||
// nop // sll r0, r0, 0
|
||||
c->pcpyld(t5, t7, t3); // pcpyld t5, t7, t3
|
||||
c->sq(t2, 0, a2); // sq t2, 0(a2)
|
||||
c->pcpyud(t2, t3, t7); // pcpyud t2, t3, t7
|
||||
c->sq(t1, 32, a2); // sq t1, 32(a2)
|
||||
c->pcpyld(t1, t6, t4); // pcpyld t1, t6, t4
|
||||
c->sq(t0, 64, a2); // sq t0, 64(a2)
|
||||
c->pcpyud(t0, t4, t6); // pcpyud t0, t4, t6
|
||||
c->sq(a3, 96, a2); // sq a3, 96(a2)
|
||||
c->sq(t5, 16, a2); // sq t5, 16(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t2, 48, a2); // sq t2, 48(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t1, 80, a2); // sq t1, 80(a2)
|
||||
// nop // sll r0, r0, 0
|
||||
c->sq(t0, 112, a2); // sq t0, 112(a2)
|
||||
c->daddiu(s5, a2, 128); // daddiu s5, a2, 128
|
||||
bc = ((s64)c->sgpr64(v1)) > 0; // bgtz v1, L11
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_21;} // branch non-likely
|
||||
|
||||
bc = c->sgpr64(v1) == 0; // beq v1, r0, L11
|
||||
c->mov64(a1, a0); // or a1, a0, r0
|
||||
if (bc) {goto block_21;} // branch non-likely
|
||||
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
c->ld(ra, 0, sp); // ld ra, 0(sp)
|
||||
c->ld(fp, 8, sp); // ld fp, 8(sp)
|
||||
c->lq(gp, 64, sp); // lq gp, 64(sp)
|
||||
c->lq(s5, 48, sp); // lq s5, 48(sp)
|
||||
c->lq(s4, 32, sp); // lq s4, 32(sp)
|
||||
//jr ra // jr ra
|
||||
c->daddiu(sp, sp, 80); // daddiu sp, sp, 80
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.level = intern_from_c(-1, 0, "*level*").c();
|
||||
cache.time_of_day_context = intern_from_c(-1, 0, "*time-of-day-context*").c();
|
||||
cache.ocean_vu0_block = intern_from_c(-1, 0, "ocean-vu0-block").c();
|
||||
cache.sewerb = intern_from_c(-1, 0, "sewerb").c();
|
||||
cache.upload_vu0_program = intern_from_c(-1, 0, "upload-vu0-program").c();
|
||||
cache.vu_lights_light_group = intern_from_c(-1, 0, "vu-lights<-light-group!").c();
|
||||
cache.ocean_generate_verts_vector = intern_from_c(-1, 0, "*ocean-generate-verts-vector*").c();
|
||||
gLinkedFunctionTable.reg("(method 16 ocean)", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace method_16_ocean
|
||||
} // namespace Mips2C
|
||||
@@ -0,0 +1,601 @@
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
|
||||
struct RippleVu0 {
|
||||
Vf data_mem[256];
|
||||
void sq(const Vf& reg, u16 addr) {
|
||||
ASSERT(addr < 256);
|
||||
data_mem[addr] = reg;
|
||||
}
|
||||
Vf lq(u16 addr) {
|
||||
ASSERT(addr < 256);
|
||||
return data_mem[addr];
|
||||
}
|
||||
} gRippleVu0;
|
||||
|
||||
namespace ripple_execute_init {
|
||||
struct Cache {
|
||||
void* cos_poly_vec; // *cos-poly-vec*
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
c->load_symbol2(v1, cache.cos_poly_vec); // lw v1, *cos-poly-vec*(s7)
|
||||
c->lqc2(vf7, 0, v1); // lqc2 vf7, 0(v1)
|
||||
c->lui(v1, 15561); // lui v1, 15561
|
||||
c->ori(v1, v1, 4058); // ori v1, v1, 4058
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
c->mov128_vf_gpr(vf6, v1); // qmtc2.i vf6, v1
|
||||
c->mov128_gpr_vf(v1, vf6); // qmfc2.i v1, vf6
|
||||
c->addiu(v1, r0, 128); // addiu v1, r0, 128
|
||||
u16 vi2 = c->gpr_src(v1).du16[0]; // ctc2.i vi2, v1
|
||||
c->gprs[v1].du64[0] = vi2; // cfc2.i v1, vi2
|
||||
c->lui(v1, 16256); // lui v1, 16256
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
c->mov128_vf_gpr(vf9, v1); // qmtc2.i vf9, v1
|
||||
c->mov128_gpr_vf(v1, vf9); // qmfc2.i v1, vf9
|
||||
u16 vi1 = 0; // viaddi vi1, vi0, 0
|
||||
c->addiu(v1, r0, 128); // addiu v1, r0, 128
|
||||
c->vmove(DEST::xyzw, vf5, vf6); // vmove.xyzw vf5, vf6
|
||||
|
||||
block_1:
|
||||
c->vmul(DEST::xyzw, vf1, vf5, vf5); // vmul.xyzw vf1, vf5, vf5
|
||||
c->vadda_bc(DEST::xyzw, BC::w, vf0, vf0); // vaddaw.xyzw acc, vf0, vf0
|
||||
c->vadd(DEST::x, vf5, vf5, vf6); // vadd.x vf5, vf5, vf6
|
||||
c->vsub_bc(DEST::y, BC::x, vf9, vf0, vf9); // vsubx.y vf9, vf0, vf9
|
||||
c->vmul(DEST::xyzw, vf2, vf1, vf1); // vmul.xyzw vf2, vf1, vf1
|
||||
c->vmadda_bc(DEST::xyzw, BC::x, vf1, vf7); // vmaddax.xyzw acc, vf1, vf7
|
||||
c->vmul(DEST::xyzw, vf3, vf2, vf1); // vmul.xyzw vf3, vf2, vf1
|
||||
c->vmadda_bc(DEST::xyzw, BC::y, vf2, vf7); // vmadday.xyzw acc, vf2, vf7
|
||||
c->vmul(DEST::xyzw, vf4, vf2, vf2); // vmul.xyzw vf4, vf2, vf2
|
||||
c->vmadda_bc(DEST::xyzw, BC::z, vf3, vf7); // vmaddaz.xyzw acc, vf3, vf7
|
||||
c->daddiu(v1, v1, -1); // daddiu v1, v1, -1
|
||||
c->vmadd_bc(DEST::xyzw, BC::w, vf8, vf4, vf7); // vmaddw.xyzw vf8, vf4, vf7
|
||||
c->vadd_bc(DEST::y, BC::x, vf9, vf9, vf8); // vaddx.y vf9, vf9, vf8
|
||||
c->vsub(DEST::xyzw, vf10, vf0, vf9); // vsub.xyzw vf10, vf0, vf9
|
||||
gRippleVu0.sq(c->vfs[vf9].vf, vi1++); // vsqi.xyzw vf9, vi1
|
||||
c->vmove(DEST::xyzw, vf9, vf8); // vmove.xyzw vf9, vf8
|
||||
bc = c->sgpr64(v1) != 0; // bne v1, r0, L40
|
||||
gRippleVu0.sq(c->vfs[vf10].vf, vi2++); // vsqi.xyzw vf10, vi2
|
||||
if (bc) {goto block_1;} // branch non-likely
|
||||
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.cos_poly_vec = intern_from_c(-1, 0, "*cos-poly-vec*").c();
|
||||
gLinkedFunctionTable.reg("ripple-execute-init", execute, 32);
|
||||
}
|
||||
|
||||
} // namespace ripple_execute_init
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace ripple_create_wave_table {
|
||||
struct Cache {
|
||||
void* display; // *display*
|
||||
void* fake_scratchpad_data; // *fake-scratchpad-data*
|
||||
void* setting_control; // *setting-control*
|
||||
void* atan; // atan
|
||||
void* cos; // cos
|
||||
void* ntsc; // ntsc
|
||||
void* pal; // pal
|
||||
void* ripple_update_waveform_offs; // ripple-update-waveform-offs
|
||||
void* sin; // sin
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
u16 vi1, vi2;
|
||||
u32 call_addr = 0;
|
||||
c->daddiu(sp, sp, -80); // daddiu sp, sp, -80
|
||||
c->sd(ra, 0, sp); // sd ra, 0(sp)
|
||||
c->sq(s4, 16, sp); // sq s4, 16(sp)
|
||||
c->sq(s5, 32, sp); // sq s5, 32(sp)
|
||||
c->sq(gp, 48, sp); // sq gp, 48(sp)
|
||||
c->swc1(f28, 64, sp); // swc1 f28, 64(sp)
|
||||
c->swc1(f30, 68, sp); // swc1 f30, 68(sp)
|
||||
c->mov64(gp, a0); // or gp, a0, r0
|
||||
c->lwu(v1, 4, gp); // lwu v1, 4(gp)
|
||||
bc = c->sgpr64(s7) != c->sgpr64(v1); // bne s7, v1, L31
|
||||
c->mov64(v1, s7); // or v1, s7, r0
|
||||
if (bc) {goto block_9;} // branch non-likely
|
||||
|
||||
c->addiu(s5, r0, 0); // addiu s5, r0, 0
|
||||
//beq r0, r0, L30 // beq r0, r0, L30
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_7; // branch always
|
||||
|
||||
|
||||
block_2:
|
||||
c->addiu(v1, r0, 28); // addiu v1, r0, 28
|
||||
c->mult3(v1, v1, s5); // mult3 v1, v1, s5
|
||||
c->daddiu(v1, v1, 12); // daddiu v1, v1, 12
|
||||
c->daddu(s4, v1, gp); // daddu s4, v1, gp
|
||||
c->load_symbol2(t9, cache.atan); // lw t9, atan(s7)
|
||||
c->lh(v1, 10, s4); // lh v1, 10(s4)
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->cvtsw(f0, f0); // cvt.s.w f0, f0
|
||||
c->mfc1(a0, f0); // mfc1 a0, f0
|
||||
c->lh(v1, 8, s4); // lh v1, 8(s4)
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->cvtsw(f0, f0); // cvt.s.w f0, f0
|
||||
c->mfc1(a1, f0); // mfc1 a1, f0
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mtc1(f28, v0); // mtc1 f28, v0
|
||||
c->lui(v1, 16768); // lui v1, 16768
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->lh(v1, 8, s4); // lh v1, 8(s4)
|
||||
c->lh(a0, 8, s4); // lh a0, 8(s4)
|
||||
c->mult3(v1, v1, a0); // mult3 v1, v1, a0
|
||||
c->lh(a0, 10, s4); // lh a0, 10(s4)
|
||||
c->lh(a1, 10, s4); // lh a1, 10(s4)
|
||||
c->mult3(a0, a0, a1); // mult3 a0, a0, a1
|
||||
c->daddu(v1, v1, a0); // daddu v1, v1, a0
|
||||
c->mtc1(f1, v1); // mtc1 f1, v1
|
||||
c->cvtsw(f1, f1); // cvt.s.w f1, f1
|
||||
c->sqrts(f1, f1); // sqrt.s f1, f1
|
||||
c->divs(f30, f0, f1); // div.s f30, f0, f1
|
||||
c->load_symbol2(t9, cache.cos); // lw t9, cos(s7)
|
||||
c->mfc1(a0, f28); // mfc1 a0, f28
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mtc1(f0, v0); // mtc1 f0, v0
|
||||
c->lui(v1, 18304); // lui v1, 18304
|
||||
c->mtc1(f1, v1); // mtc1 f1, v1
|
||||
c->divs(f1, f1, f30); // div.s f1, f1, f30
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 16, s4); // swc1 f0, 16(s4)
|
||||
c->load_symbol2(t9, cache.sin); // lw t9, sin(s7)
|
||||
c->mfc1(a0, f28); // mfc1 a0, f28
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
c->mtc1(f0, v0); // mtc1 f0, v0
|
||||
c->lui(v1, 18304); // lui v1, 18304
|
||||
c->mtc1(f1, v1); // mtc1 f1, v1
|
||||
c->divs(f1, f1, f30); // div.s f1, f1, f30
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 20, s4); // swc1 f0, 20(s4)
|
||||
c->load_symbol2(v1, cache.setting_control); // lw v1, *setting-control*(s7)
|
||||
c->lwu(v1, 64, v1); // lwu v1, 64(v1)
|
||||
c->load_symbol_addr(a0, cache.ntsc); // daddiu a0, s7, ntsc
|
||||
bc = c->sgpr64(v1) != c->sgpr64(a0); // bne v1, a0, L28
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
if (bc) {goto block_4;} // branch non-likely
|
||||
|
||||
c->lui(v1, 15496); // lui v1, 15496
|
||||
c->ori(v1, v1, 34953); // ori v1, v1, 34953
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->lui(v1, -14464); // lui v1, -14464
|
||||
c->mtc1(f1, v1); // mtc1 f1, v1
|
||||
c->divs(f1, f1, f30); // div.s f1, f1, f30
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->lwc1(f1, 12, s4); // lwc1 f1, 12(s4)
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 24, s4); // swc1 f0, 24(s4)
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
//beq r0, r0, L29 // beq r0, r0, L29
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_6; // branch always
|
||||
|
||||
|
||||
block_4:
|
||||
c->load_symbol_addr(a0, cache.pal); // daddiu a0, s7, pal
|
||||
bc = c->sgpr64(v1) != c->sgpr64(a0); // bne v1, a0, L29
|
||||
c->mov64(v1, s7); // or v1, s7, r0
|
||||
if (bc) {goto block_6;} // branch non-likely
|
||||
|
||||
c->lui(v1, 15523); // lui v1, 15523
|
||||
c->ori(v1, v1, 55050); // ori v1, v1, 55050
|
||||
c->mtc1(f0, v1); // mtc1 f0, v1
|
||||
c->lui(v1, -14464); // lui v1, -14464
|
||||
c->mtc1(f1, v1); // mtc1 f1, v1
|
||||
c->divs(f1, f1, f30); // div.s f1, f1, f30
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->lwc1(f1, 12, s4); // lwc1 f1, 12(s4)
|
||||
c->muls(f0, f0, f1); // mul.s f0, f0, f1
|
||||
c->swc1(f0, 24, s4); // swc1 f0, 24(s4)
|
||||
c->mfc1(v1, f0); // mfc1 v1, f0
|
||||
|
||||
block_6:
|
||||
c->daddiu(s5, s5, 1); // daddiu s5, s5, 1
|
||||
|
||||
block_7:
|
||||
c->lw(v1, 0, gp); // lw v1, 0(gp)
|
||||
c->slt(v1, s5, v1); // slt v1, s5, v1
|
||||
bc = c->sgpr64(v1) != 0; // bne v1, r0, L27
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_2;} // branch non-likely
|
||||
|
||||
c->mov64(v1, s7); // or v1, s7, r0
|
||||
c->mov64(v1, s7); // or v1, s7, r0
|
||||
c->daddiu(v1, s7, 4); // daddiu v1, s7, #t
|
||||
c->sw(v1, 4, gp); // sw v1, 4(gp)
|
||||
|
||||
block_9:
|
||||
c->load_symbol2(t9, cache.ripple_update_waveform_offs);// lw t9, ripple-update-waveform-offs(s7)
|
||||
c->mov64(a0, gp); // or a0, gp, r0
|
||||
c->load_symbol2(v1, cache.display); // lw v1, *display*(s7)
|
||||
c->lwu(a1, 72, v1); // lwu a1, 72(v1)
|
||||
call_addr = c->gprs[t9].du32[0]; // function call:
|
||||
c->sll(v0, ra, 0); // sll v0, ra, 0
|
||||
c->jalr(call_addr); // jalr ra, t9
|
||||
get_fake_spad_addr2(v1, cache.fake_scratchpad_data, 0, c);// lui v1, 28672
|
||||
c->addiu(a0, r0, 64); // addiu a0, r0, 64
|
||||
c->mov64(a1, v1); // or a1, v1, r0
|
||||
|
||||
block_10:
|
||||
c->daddiu(a0, a0, -1); // daddiu a0, a0, -1
|
||||
c->sq(r0, 0, a1); // sq r0, 0(a1)
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
bc = c->sgpr64(a0) != 0; // bne a0, r0, L32
|
||||
c->daddiu(a1, a1, 16); // daddiu a1, a1, 16
|
||||
if (bc) {goto block_10;} // branch non-likely
|
||||
|
||||
c->addiu(a0, r0, 0); // addiu a0, r0, 0
|
||||
//beq r0, r0, L36 // beq r0, r0, L36
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_17; // branch always
|
||||
|
||||
|
||||
block_12:
|
||||
c->addiu(a1, r0, 28); // addiu a1, r0, 28
|
||||
c->mult3(a1, a1, a0); // mult3 a1, a1, a0
|
||||
c->daddiu(a1, a1, 12); // daddiu a1, a1, 12
|
||||
c->daddu(a1, a1, gp); // daddu a1, a1, gp
|
||||
c->lui(a2, 18048); // lui a2, 18048
|
||||
c->mtc1(f0, a2); // mtc1 f0, a2
|
||||
c->lui(a2, 15232); // lui a2, 15232
|
||||
c->mtc1(f1, a2); // mtc1 f1, a2
|
||||
c->lwc1(f2, 4, a1); // lwc1 f2, 4(a1)
|
||||
c->muls(f1, f1, f2); // mul.s f1, f1, f2
|
||||
c->adds(f0, f0, f1); // add.s f0, f0, f1
|
||||
c->lui(a2, 15232); // lui a2, 15232
|
||||
c->mtc1(f1, a2); // mtc1 f1, a2
|
||||
c->lwc1(f2, 16, a1); // lwc1 f2, 16(a1)
|
||||
c->muls(f1, f1, f2); // mul.s f1, f1, f2
|
||||
c->lui(a2, 15232); // lui a2, 15232
|
||||
c->mtc1(f2, a2); // mtc1 f2, a2
|
||||
c->lwc1(f3, 20, a1); // lwc1 f3, 20(a1)
|
||||
c->muls(f2, f2, f3); // mul.s f2, f2, f3
|
||||
c->lwc1(f3, 0, a1); // lwc1 f3, 0(a1)
|
||||
c->addiu(a1, r0, 255); // addiu a1, r0, 255
|
||||
c->mfc1(a2, f0); // mfc1 a2, f0
|
||||
c->mov128_vf_gpr(vf1, a2); // qmtc2.i vf1, a2
|
||||
c->mfc1(a2, f1); // mfc1 a2, f1
|
||||
c->mov128_vf_gpr(vf2, a2); // qmtc2.i vf2, a2
|
||||
c->mfc1(a2, f2); // mfc1 a2, f2
|
||||
c->mov128_vf_gpr(vf3, a2); // qmtc2.i vf3, a2
|
||||
c->mfc1(a2, f3); // mfc1 a2, f3
|
||||
c->mov128_vf_gpr(vf4, a2); // qmtc2.i vf4, a2
|
||||
vi1 = c->gpr_src(a1).du16[0]; // ctc2.i vi1, a1
|
||||
c->mov64(a1, v1); // or a1, v1, r0
|
||||
c->addiu(a2, r0, 16); // addiu a2, r0, 16
|
||||
c->vmove(DEST::xyzw, vf6, vf0); // vmove.xyzw vf6, vf0
|
||||
|
||||
block_13:
|
||||
c->addiu(a3, r0, 16); // addiu a3, r0, 16
|
||||
c->vmove(DEST::xyzw, vf5, vf0); // vmove.xyzw vf5, vf0
|
||||
|
||||
block_14:
|
||||
c->lw(at, 0, a1); // lw at, 0(a1)
|
||||
c->vadda_bc(DEST::xyzw, BC::x, vf1, vf0); // vaddax.xyzw acc, vf1, vf0
|
||||
c->vmadda(DEST::xyzw, vf2, vf5); // vmadda.xyzw acc, vf2, vf5
|
||||
c->vmadd(DEST::xyzw, vf7, vf3, vf6); // vmadd.xyzw vf7, vf3, vf6
|
||||
c->mov128_vf_gpr(vf10, at); // qmtc2.i vf10, at
|
||||
c->vadd_bc(DEST::xyzw, BC::w, vf5, vf5, vf0); // vaddw.xyzw vf5, vf5, vf0
|
||||
c->vftoi0(DEST::xyzw, vf8, vf7); // vftoi0.xyzw vf8, vf7
|
||||
vi2 = c->vfs[vf8].vf.x_as_u16(); // vmtirx vi2, vf8
|
||||
c->vitof0(DEST::xyzw, vf8, vf8); // vitof0.xyzw vf8, vf8
|
||||
vi2 &= vi1; // viand vi2, vi2, vi1
|
||||
c->vfs[vf9].vf = gRippleVu0.lq(vi2++); // vlqi.xyzw vf9, vi2
|
||||
c->vsub(DEST::xyzw, vf7, vf7, vf8); // vsub.xyzw vf7, vf7, vf8
|
||||
c->vadda_bc(DEST::xyzw, BC::x, vf0, vf9); // vaddax.xyzw acc, vf0, vf9
|
||||
c->vmadd_bc(DEST::xyzw, BC::y, vf9, vf7, vf9); // vmaddy.xyzw vf9, vf7, vf9
|
||||
c->vadda_bc(DEST::xyzw, BC::x, vf10, vf0); // vaddax.xyzw acc, vf10, vf0
|
||||
c->vmadd(DEST::xyzw, vf10, vf9, vf4); // vmadd.xyzw vf10, vf9, vf4
|
||||
c->mov128_gpr_vf(at, vf10); // qmfc2.i at, vf10
|
||||
c->sw(at, 0, a1); // sw at, 0(a1)
|
||||
c->daddiu(a3, a3, -1); // daddiu a3, a3, -1
|
||||
bc = c->sgpr64(a3) != 0; // bne a3, r0, L35
|
||||
c->daddiu(a1, a1, 4); // daddiu a1, a1, 4
|
||||
if (bc) {goto block_14;} // branch non-likely
|
||||
|
||||
c->daddiu(a2, a2, -1); // daddiu a2, a2, -1
|
||||
bc = c->sgpr64(a2) != 0; // bne a2, r0, L34
|
||||
c->vadd_bc(DEST::xyzw, BC::w, vf6, vf6, vf0); // vaddw.xyzw vf6, vf6, vf0
|
||||
if (bc) {goto block_13;} // branch non-likely
|
||||
|
||||
c->mov128_gpr_vf(a1, vf6); // qmfc2.i a1, vf6
|
||||
c->daddiu(a0, a0, 1); // daddiu a0, a0, 1
|
||||
|
||||
block_17:
|
||||
c->lw(a1, 0, gp); // lw a1, 0(gp)
|
||||
c->slt(a1, a0, a1); // slt a1, a0, a1
|
||||
bc = c->sgpr64(a1) != 0; // bne a1, r0, L33
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_12;} // branch non-likely
|
||||
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
c->mov64(a0, s7); // or a0, s7, r0
|
||||
c->lui(a0, 17152); // lui a0, 17152
|
||||
c->mtc1(f0, a0); // mtc1 f0, a0
|
||||
c->lui(a0, 17279); // lui a0, 17279
|
||||
c->mtc1(f1, a0); // mtc1 f1, a0
|
||||
c->lwc1(f2, 8, gp); // lwc1 f2, 8(gp)
|
||||
c->mfc1(a0, f2); // mfc1 a0, f2
|
||||
c->mov128_vf_gpr(vf16, a0); // qmtc2.i vf16, a0
|
||||
c->mfc1(a0, f0); // mfc1 a0, f0
|
||||
c->mov128_vf_gpr(vf14, a0); // qmtc2.i vf14, a0
|
||||
c->mfc1(a0, f1); // mfc1 a0, f1
|
||||
c->mov128_vf_gpr(vf15, a0); // qmtc2.i vf15, a0
|
||||
c->vmax_bc(DEST::xyzw, BC::x, vf16, vf0, vf16); // vmaxx.xyzw vf16, vf0, vf16
|
||||
c->vmini_bc(DEST::w, BC::x, vf16, vf0, vf0); // vminix.w vf16, vf0, vf0
|
||||
c->mov64(v1, v1); // or v1, v1, r0
|
||||
c->addiu(v0, r0, 15); // addiu v0, r0, 15
|
||||
|
||||
block_19:
|
||||
c->addiu(a0, r0, 15); // addiu a0, r0, 15
|
||||
|
||||
block_20:
|
||||
c->addiu(a2, r0, 4); // addiu a2, r0, 4
|
||||
c->addiu(at, r0, -60); // addiu at, r0, -60
|
||||
c->movz(a2, at, a0); // movz a2, at, a0
|
||||
c->addiu(a1, r0, 64); // addiu a1, r0, 64
|
||||
c->addiu(at, r0, -960); // addiu at, r0, -960
|
||||
c->daddu(a2, a2, v1); // daddu a2, a2, v1
|
||||
c->movz(a1, at, v0); // movz a1, at, v0
|
||||
c->lw(at, 0, v1); // lw at, 0(v1)
|
||||
c->lw(a2, 0, a2); // lw a2, 0(a2)
|
||||
c->daddu(a1, a1, v1); // daddu a1, a1, v1
|
||||
c->lw(a1, 0, a1); // lw a1, 0(a1)
|
||||
c->mov128_vf_gpr(vf11, at); // qmtc2.i vf11, at
|
||||
c->mov128_vf_gpr(vf12, a2); // qmtc2.i vf12, a2
|
||||
c->mov128_vf_gpr(vf13, a1); // qmtc2.i vf13, a1
|
||||
c->vadd_bc(DEST::xyzw, BC::x, vf11, vf0, vf11); // vaddx.xyzw vf11, vf0, vf11
|
||||
c->vsub_bc(DEST::y, BC::x, vf11, vf11, vf12); // vsubx.y vf11, vf11, vf12
|
||||
c->vsub_bc(DEST::z, BC::x, vf11, vf11, vf13); // vsubx.z vf11, vf11, vf13
|
||||
c->vmul(DEST::yzw, vf11, vf11, vf16); // vmul.yzw vf11, vf11, vf16
|
||||
c->vadd_bc(DEST::xyzw, BC::x, vf11, vf11, vf14); // vaddx.xyzw vf11, vf11, vf14
|
||||
c->vmax_bc(DEST::xyzw, BC::x, vf11, vf11, vf0); // vmaxx.xyzw vf11, vf11, vf0
|
||||
c->vmini_bc(DEST::xyzw, BC::x, vf11, vf11, vf15); // vminix.xyzw vf11, vf11, vf15
|
||||
c->vftoi0(DEST::xyzw, vf11, vf11); // vftoi0.xyzw vf11, vf11
|
||||
c->mov128_gpr_vf(at, vf11); // qmfc2.i at, vf11
|
||||
c->ppach(at, at, at); // ppach at, at, at
|
||||
c->ppacb(at, at, at); // ppacb at, at, at
|
||||
c->sw(at, 1024, v1); // sw at, 1024(v1)
|
||||
c->daddiu(v1, v1, 4); // daddiu v1, v1, 4
|
||||
bc = c->sgpr64(a0) != 0; // bne a0, r0, L38
|
||||
c->daddiu(a0, a0, -1); // daddiu a0, a0, -1
|
||||
if (bc) {goto block_20;} // branch non-likely
|
||||
|
||||
bc = c->sgpr64(v0) != 0; // bne v0, r0, L37
|
||||
c->daddiu(v0, v0, -1); // daddiu v0, v0, -1
|
||||
if (bc) {goto block_19;} // branch non-likely
|
||||
|
||||
c->ld(ra, 0, sp); // ld ra, 0(sp)
|
||||
c->lwc1(f30, 68, sp); // lwc1 f30, 68(sp)
|
||||
c->lwc1(f28, 64, sp); // lwc1 f28, 64(sp)
|
||||
c->lq(gp, 48, sp); // lq gp, 48(sp)
|
||||
c->lq(s5, 32, sp); // lq s5, 32(sp)
|
||||
c->lq(s4, 16, sp); // lq s4, 16(sp)
|
||||
//jr ra // jr ra
|
||||
c->daddiu(sp, sp, 80); // daddiu sp, sp, 80
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.display = intern_from_c(-1, 0, "*display*").c();
|
||||
cache.fake_scratchpad_data = intern_from_c(-1, 0, "*fake-scratchpad-data*").c();
|
||||
cache.setting_control = intern_from_c(-1, 0, "*setting-control*").c();
|
||||
cache.atan = intern_from_c(-1, 0, "atan").c();
|
||||
cache.cos = intern_from_c(-1, 0, "cos").c();
|
||||
cache.ntsc = intern_from_c(-1, 0, "ntsc").c();
|
||||
cache.pal = intern_from_c(-1, 0, "pal").c();
|
||||
cache.ripple_update_waveform_offs = intern_from_c(-1, 0, "ripple-update-waveform-offs").c();
|
||||
cache.sin = intern_from_c(-1, 0, "sin").c();
|
||||
gLinkedFunctionTable.reg("ripple-create-wave-table", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace ripple_create_wave_table
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace ripple_apply_wave_table {
|
||||
struct Cache {
|
||||
void* fake_scratchpad_data; // *fake-scratchpad-data*
|
||||
} cache;
|
||||
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
get_fake_spad_addr2(v1, cache.fake_scratchpad_data, 0, c);// lui v1, 28672
|
||||
c->daddiu(v1, v1, 1024); // daddiu v1, v1, 1024
|
||||
c->lwu(a1, 4, a0); // lwu a1, 4(a0)
|
||||
c->lwu(t2, 0, a0); // lwu t2, 0(a0)
|
||||
c->lwu(a2, 8, a0); // lwu a2, 8(a0)
|
||||
c->lwu(a3, 12, a0); // lwu a3, 12(a0)
|
||||
c->lhu(a0, 18, a0); // lhu a0, 18(a0)
|
||||
c->addiu(t0, r0, 0); // addiu t0, r0, 0
|
||||
//beq r0, r0, L25 // beq r0, r0, L25
|
||||
// nop // sll r0, r0, 0
|
||||
goto block_4; // branch always
|
||||
|
||||
|
||||
block_1:
|
||||
c->lbu(t1, 0, a3); // lbu t1, 0(a3)
|
||||
c->lbu(t3, 0, a1); // lbu t3, 0(a1)
|
||||
c->daddiu(t3, t3, 3); // daddiu t3, t3, 3
|
||||
c->dsrl(t3, t3, 2); // dsrl t3, t3, 2
|
||||
c->dsll(t3, t3, 4); // dsll t3, t3, 4
|
||||
c->daddu(t2, t2, t3); // daddu t2, t2, t3
|
||||
c->mov64(t4, t2); // or t4, t2, r0
|
||||
c->mov64(t3, t1); // or t3, t1, r0
|
||||
c->mov64(t5, t4); // or t5, t4, r0
|
||||
c->mov64(t4, a2); // or t4, a2, r0
|
||||
|
||||
block_2:
|
||||
c->lb(t6, 0, t4); // lb t6, 0(t4)
|
||||
c->lb(t7, 1, t4); // lb t7, 1(t4)
|
||||
c->andi(t6, t6, 15); // andi t6, t6, 15
|
||||
c->andi(t7, t7, 15); // andi t7, t7, 15
|
||||
c->sll(t7, t7, 4); // sll t7, t7, 4
|
||||
c->daddu(t6, t6, t7); // daddu t6, t6, t7
|
||||
c->sll(t6, t6, 2); // sll t6, t6, 2
|
||||
c->daddu(t8, t6, v1); // daddu t8, t6, v1
|
||||
c->lb(t6, 0, t8); // lb t6, 0(t8)
|
||||
c->lb(t7, 1, t8); // lb t7, 1(t8)
|
||||
c->lb(t8, 2, t8); // lb t8, 2(t8)
|
||||
c->sb(t6, 7, t5); // sb t6, 7(t5)
|
||||
c->sb(t7, 2, t5); // sb t7, 2(t5)
|
||||
c->sb(t8, 10, t5); // sb t8, 10(t5)
|
||||
c->daddiu(t3, t3, -1); // daddiu t3, t3, -1
|
||||
c->daddiu(t4, t4, 2); // daddiu t4, t4, 2
|
||||
bc = c->sgpr64(t3) != 0; // bne t3, r0, L24
|
||||
c->daddiu(t5, t5, 12); // daddiu t5, t5, 12
|
||||
if (bc) {goto block_2;} // branch non-likely
|
||||
|
||||
c->lbu(t3, 2, a1); // lbu t3, 2(a1)
|
||||
c->lbu(t4, 1, a1); // lbu t4, 1(a1)
|
||||
c->daddiu(t4, t4, 3); // daddiu t4, t4, 3
|
||||
c->dsrl(t4, t4, 2); // dsrl t4, t4, 2
|
||||
c->daddu(t3, t3, t4); // daddu t3, t3, t4
|
||||
c->dsll(t3, t3, 4); // dsll t3, t3, 4
|
||||
c->daddu(t2, t2, t3); // daddu t2, t2, t3
|
||||
c->lbu(t3, 3, a1); // lbu t3, 3(a1)
|
||||
c->dsll(t3, t3, 1); // dsll t3, t3, 1
|
||||
c->daddiu(t3, t3, 4); // daddiu t3, t3, 4
|
||||
c->daddu(a1, a1, t3); // daddu a1, a1, t3
|
||||
c->dsll(t1, t1, 1); // dsll t1, t1, 1
|
||||
c->daddiu(t1, t1, 15); // daddiu t1, t1, 15
|
||||
c->andi(t1, t1, 65520); // andi t1, t1, 65520
|
||||
c->daddu(a2, a2, t1); // daddu a2, a2, t1
|
||||
c->daddiu(a3, a3, 2); // daddiu a3, a3, 2
|
||||
c->mov64(t1, a3); // or t1, a3, r0
|
||||
c->daddiu(t0, t0, 1); // daddiu t0, t0, 1
|
||||
|
||||
block_4:
|
||||
c->slt(t1, t0, a0); // slt t1, t0, a0
|
||||
bc = c->sgpr64(t1) != 0; // bne t1, r0, L23
|
||||
// nop // sll r0, r0, 0
|
||||
if (bc) {goto block_1;} // branch non-likely
|
||||
|
||||
c->mov64(v1, s7); // or v1, s7, r0
|
||||
c->mov64(v0, s7); // or v0, s7, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
cache.fake_scratchpad_data = intern_from_c(-1, 0, "*fake-scratchpad-data*").c();
|
||||
gLinkedFunctionTable.reg("ripple-apply-wave-table", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace ripple_apply_wave_table
|
||||
} // namespace Mips2C
|
||||
|
||||
//--------------------------MIPS2C---------------------
|
||||
// clang-format off
|
||||
#include "game/mips2c/mips2c_private.h"
|
||||
#include "game/kernel/jak3/kscheme.h"
|
||||
using ::jak3::intern_from_c;
|
||||
namespace Mips2C::jak3 {
|
||||
namespace ripple_matrix_scale {
|
||||
u64 execute(void* ctxt) {
|
||||
auto* c = (ExecutionContext*)ctxt;
|
||||
bool bc = false;
|
||||
c->lhu(v1, 2, a0); // lhu v1, 2(a0)
|
||||
c->lw(a1, 4, a0); // lw a1, 4(a0)
|
||||
c->lw(a2, 28, a0); // lw a2, 28(a0)
|
||||
c->lqc2(vf1, 16, a0); // lqc2 vf1, 16(a0)
|
||||
|
||||
block_1:
|
||||
c->lqc2(vf5, 16, a1); // lqc2 vf5, 16(a1)
|
||||
c->lqc2(vf6, 48, a1); // lqc2 vf6, 48(a1)
|
||||
c->lqc2(vf7, 64, a1); // lqc2 vf7, 64(a1)
|
||||
c->lqc2(vf8, 96, a1); // lqc2 vf8, 96(a1)
|
||||
c->vmul_bc(DEST::xyzw, BC::x, vf4, vf5, vf1); // vmulx.xyzw vf4, vf5, vf1
|
||||
c->vmul_bc(DEST::xyzw, BC::y, vf5, vf5, vf1); // vmuly.xyzw vf5, vf5, vf1
|
||||
c->lq(a3, 0, a1); // lq a3, 0(a1)
|
||||
c->vmul_bc(DEST::xyzw, BC::z, vf7, vf7, vf1); // vmulz.xyzw vf7, vf7, vf1
|
||||
c->lq(a0, 32, a1); // lq a0, 32(a1)
|
||||
c->vmul_bc(DEST::xyzw, BC::z, vf8, vf8, vf1); // vmulz.xyzw vf8, vf8, vf1
|
||||
c->sq(a3, 0, a2); // sq a3, 0(a2)
|
||||
c->lq(a3, 80, a1); // lq a3, 80(a1)
|
||||
c->vsub(DEST::xyzw, vf6, vf6, vf4); // vsub.xyzw vf6, vf6, vf4
|
||||
c->sq(a0, 32, a2); // sq a0, 32(a2)
|
||||
c->sqc2(vf5, 16, a2); // sqc2 vf5, 16(a2)
|
||||
c->sq(a3, 80, a2); // sq a3, 80(a2)
|
||||
c->daddiu(v1, v1, -1); // daddiu v1, v1, -1
|
||||
c->sqc2(vf7, 64, a2); // sqc2 vf7, 64(a2)
|
||||
c->addiu(a1, a1, 128); // addiu a1, a1, 128
|
||||
c->sqc2(vf6, 48, a2); // sqc2 vf6, 48(a2)
|
||||
c->addiu(a2, a2, 128); // addiu a2, a2, 128
|
||||
bc = c->sgpr64(v1) != 0; // bne v1, r0, L13
|
||||
c->sqc2(vf8, -32, a2); // sqc2 vf8, -32(a2)
|
||||
if (bc) {goto block_1;} // branch non-likely
|
||||
|
||||
c->gprs[v0].du64[0] = 0; // or v0, r0, r0
|
||||
//jr ra // jr ra
|
||||
c->daddu(sp, sp, r0); // daddu sp, sp, r0
|
||||
goto end_of_function; // return
|
||||
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
// nop // sll r0, r0, 0
|
||||
end_of_function:
|
||||
return c->gprs[v0].du64[0];
|
||||
}
|
||||
|
||||
void link() {
|
||||
gLinkedFunctionTable.reg("ripple-matrix-scale", execute, 128);
|
||||
}
|
||||
|
||||
} // namespace ripple_matrix_scale
|
||||
} // namespace Mips2C
|
||||
@@ -347,6 +347,16 @@ namespace blerc_execute { extern void link(); }
|
||||
namespace setup_blerc_chains_for_one_fragment { extern void link(); }
|
||||
namespace sparticle_motion_blur_dirt { extern void link(); }
|
||||
namespace foreground_draw_hud { extern void link(); }
|
||||
namespace ripple_matrix_scale { extern void link(); }
|
||||
namespace ripple_apply_wave_table { extern void link(); }
|
||||
namespace ripple_create_wave_table { extern void link(); }
|
||||
namespace ripple_execute_init { extern void link(); }
|
||||
namespace method_14_ocean { extern void link(); }
|
||||
namespace method_15_ocean { extern void link(); }
|
||||
namespace method_16_ocean { extern void link(); }
|
||||
namespace init_ocean_far_regs { extern void link(); }
|
||||
namespace draw_large_polygon_ocean { extern void link(); }
|
||||
namespace render_ocean_quad { extern void link(); }
|
||||
|
||||
}
|
||||
// clang-format on
|
||||
@@ -583,6 +593,14 @@ PerGameVersion<std::unordered_map<std::string, std::vector<void (*)()>>> gMips2C
|
||||
{"merc-blend-shape",
|
||||
{jak3::blerc_execute::link, jak3::setup_blerc_chains_for_one_fragment::link}},
|
||||
{"wvehicle-part", {jak3::sparticle_motion_blur_dirt::link}},
|
||||
{"ripple",
|
||||
{jak3::ripple_matrix_scale::link, jak3::ripple_apply_wave_table::link,
|
||||
jak3::ripple_create_wave_table::link, jak3::ripple_execute_init::link}},
|
||||
{"ocean-vu0",
|
||||
{jak3::method_14_ocean::link, jak3::method_15_ocean::link, jak3::method_16_ocean::link}},
|
||||
{"ocean",
|
||||
{jak3::init_ocean_far_regs::link, jak3::draw_large_polygon_ocean::link,
|
||||
jak3::render_ocean_quad::link}},
|
||||
}};
|
||||
|
||||
void LinkedFunctionTable::reg(const std::string& name, u64 (*exec)(void*), u32 stack_size) {
|
||||
|
||||
@@ -223,7 +223,7 @@
|
||||
(entity entity)
|
||||
(directed? symbol)
|
||||
(no-initial-move-to-ground? symbol)
|
||||
(art-level level)
|
||||
(art-level symbol)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -349,8 +349,8 @@
|
||||
(go-best-state (_type_) object)
|
||||
(go-die (_type_) object)
|
||||
(event-handler (_type_ process int symbol event-message-block) object :behavior enemy)
|
||||
(enemy-touch-handler (_type_ process event-message-block) none)
|
||||
(send-attack-on-jump-or-knocked (_type_ process event-message-block) none)
|
||||
(enemy-touch-handler (_type_ process event-message-block) object)
|
||||
(send-attack-on-jump-or-knocked (_type_ process event-message-block) object)
|
||||
(knocked-anim (_type_ enemy-knocked-info) symbol)
|
||||
(knocked-land-anim (_type_ enemy-knocked-info) symbol)
|
||||
(knocked-anim-handler (_type_ int enemy-knocked-info) symbol)
|
||||
@@ -361,7 +361,7 @@
|
||||
(init-jump-info! (_type_ enemy-jump-info) none)
|
||||
(setup-jump! (_type_ enemy-jump-info) none)
|
||||
(move-to-gspot! (_type_) float)
|
||||
(on-ground? (_type_) symbol)
|
||||
(on-ground? (_type_ enemy-jump-info) symbol)
|
||||
(jump-in-air-anim (_type_ enemy-jump-info) symbol)
|
||||
(jump-land-anim (_type_ enemy-jump-info) symbol)
|
||||
(jump-wind-up-anim (_type_ enemy-jump-info) symbol)
|
||||
@@ -415,7 +415,7 @@
|
||||
(play-damage-sound (_type_ int) sound-id)
|
||||
(check-victory (_type_) none)
|
||||
(go-gun-dark-2-stretch (_type_) object)
|
||||
(have-less-than-10-joints? (_type_) object)
|
||||
(have-more-than-10-joints? (_type_) object)
|
||||
(enemy-method-150 (_type_) symbol)
|
||||
(should-move-to-ground? (_type_) symbol)
|
||||
(enemy-method-152 (_type_) float)
|
||||
|
||||
@@ -460,7 +460,7 @@
|
||||
(go (method-of-object this hostile))
|
||||
)
|
||||
|
||||
(defmethod have-less-than-10-joints? ((this enemy))
|
||||
(defmethod have-more-than-10-joints? ((this enemy))
|
||||
(and (nonzero? (-> this node-list)) (-> this node-list) (< 10 (-> this node-list length)))
|
||||
)
|
||||
|
||||
@@ -1178,7 +1178,7 @@
|
||||
)
|
||||
)
|
||||
(when (-> arg1 art-level)
|
||||
(let ((v1-5 (level-get *level* (the-as symbol (-> arg1 art-level)))))
|
||||
(let ((v1-5 (level-get *level* (-> arg1 art-level))))
|
||||
(if v1-5
|
||||
(set! (-> self level) v1-5)
|
||||
)
|
||||
@@ -2135,7 +2135,6 @@
|
||||
(find-offending-process-focusable arg0 arg1)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch object vs none.
|
||||
(defmethod enemy-touch-handler ((this enemy) (arg0 process) (arg1 event-message-block))
|
||||
(let* ((s4-0 (-> arg1 param 0))
|
||||
(s2-0 arg0)
|
||||
@@ -2189,10 +2188,9 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch symbol vs none.
|
||||
;; WARN: Return type mismatch symbol vs object.
|
||||
(defmethod send-attack-on-jump-or-knocked ((this enemy) (arg0 process) (arg1 event-message-block))
|
||||
(let ((s4-0 (-> arg1 param 0)))
|
||||
(when s4-0
|
||||
@@ -2226,7 +2224,6 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
(defbehavior enemy-event-handler enemy ((arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
@@ -2337,11 +2334,11 @@
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod on-ground? ((this enemy))
|
||||
(defmethod on-ground? ((this enemy) (arg0 enemy-jump-info))
|
||||
(let ((gp-0 (-> this root)))
|
||||
(when (< (-> gp-0 transv y) 0.0)
|
||||
(let ((a1-0 (new 'stack-no-clear 'collide-query)))
|
||||
(find-ground (-> this root) a1-0 (-> this gnd-collide-with) 8192.0 81920.0 1024.0 (the-as process #f))
|
||||
(let ((a1-1 (new 'stack-no-clear 'collide-query)))
|
||||
(find-ground (-> this root) a1-1 (-> this gnd-collide-with) 8192.0 81920.0 1024.0 (the-as process #f))
|
||||
)
|
||||
(>= (+ 409.6 (-> gp-0 gspot-pos y)) (-> gp-0 trans y))
|
||||
)
|
||||
|
||||
@@ -37,16 +37,35 @@
|
||||
;; +++traffic-h:traffic-type
|
||||
(defenum traffic-type
|
||||
:type uint8
|
||||
(tt17 17)
|
||||
(tt18 18)
|
||||
(tt19 19)
|
||||
(tt20 20)
|
||||
(tt21 21)
|
||||
(tt22 22)
|
||||
(tt23 23)
|
||||
(tt25 25)
|
||||
(tt27 27)
|
||||
(tt28 28)
|
||||
(civilian-male 0)
|
||||
(civilian-female 1)
|
||||
(civilian-fat 2)
|
||||
(civilian-pilot 3)
|
||||
(guard-pilot 4)
|
||||
(citizen-task 5)
|
||||
(guard-a 6)
|
||||
(guard-b 7)
|
||||
(metalhead-grunt 8)
|
||||
(metalhead-flitter 9)
|
||||
(metalhead-predator 10)
|
||||
(wlander-male 11)
|
||||
(wlander-female 12)
|
||||
(formation 13)
|
||||
(roboguard 14)
|
||||
(spydroid 15)
|
||||
(flying-turret 16)
|
||||
(civilian-bike-a 17)
|
||||
(civilian-bike-b 18)
|
||||
(civilian-bike-c 19)
|
||||
(civilian-car-a 20)
|
||||
(civilian-car-b 21)
|
||||
(civilian-car-c 22)
|
||||
(vehicle-task 23)
|
||||
(guard-bike 24)
|
||||
(guard-car 25)
|
||||
(guard-transport 26)
|
||||
(kg-pickup 27)
|
||||
(bike-d 28)
|
||||
(invalid #xffffffff)
|
||||
)
|
||||
;; ---traffic-h:traffic-type
|
||||
@@ -84,6 +103,7 @@
|
||||
(v-marauder-b 23)
|
||||
(test-car 25)
|
||||
(wbike-test 26)
|
||||
(vt27 27)
|
||||
(evan-test-bike 29)
|
||||
)
|
||||
;; ---vehicle-type
|
||||
@@ -147,13 +167,13 @@
|
||||
|
||||
|
||||
(deftype traffic-info (structure)
|
||||
((ctywide-level basic)
|
||||
(vehicle-level basic)
|
||||
(race-vehicle-level basic)
|
||||
(traffic-object-levels level 29)
|
||||
((ctywide-level level)
|
||||
(vehicle-level level)
|
||||
(race-vehicle-level level)
|
||||
(traffic-object-levels symbol 29)
|
||||
(vehicle-levels symbol 44)
|
||||
(traffic-object-type-from-vehicle-type traffic-type 44)
|
||||
(restore-speech-callback basic)
|
||||
(restore-speech-callback (function none))
|
||||
)
|
||||
)
|
||||
|
||||
@@ -174,13 +194,13 @@
|
||||
(set! (-> v1-5 vehicle-levels a0-12) #f)
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type a0-12) (traffic-type invalid))
|
||||
)
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 0) (traffic-type tt17))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 1) (traffic-type tt18))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 2) (traffic-type tt19))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 3) (traffic-type tt20))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 4) (traffic-type tt21))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 5) (traffic-type tt22))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 6) (traffic-type tt28))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 7) (traffic-type tt25))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 11) (traffic-type tt27))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 0) (traffic-type civilian-bike-a))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 1) (traffic-type civilian-bike-b))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 2) (traffic-type civilian-bike-c))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 3) (traffic-type civilian-car-a))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 4) (traffic-type civilian-car-b))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 5) (traffic-type civilian-car-c))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 6) (traffic-type bike-d))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 7) (traffic-type guard-car))
|
||||
(set! (-> v1-5 traffic-object-type-from-vehicle-type 11) (traffic-type kg-pickup))
|
||||
)
|
||||
|
||||
@@ -1060,15 +1060,15 @@
|
||||
(set! (-> this pre-open-frame) 35.0)
|
||||
(set! (-> this lock-frame) 45.0)
|
||||
(set! (-> this open-frame) 45.0)
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 1))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 1))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 1))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-post-close) (static-sound-spec "airlock-slider" :group 1))
|
||||
(set! (-> this sound-post-close-stop) (static-sound-spec "airlock-slide-e" :group 1))
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 0))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 0))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 0))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(set! (-> this sound-post-close) (static-sound-spec "airlock-slider" :group 0))
|
||||
(set! (-> this sound-post-close-stop) (static-sound-spec "airlock-slide-e" :group 0))
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
|
||||
@@ -1128,16 +1128,16 @@
|
||||
)
|
||||
)
|
||||
(set! (-> this pre-open-speed) 0.9)
|
||||
(set! (-> this sound-gear) (static-sound-spec "airlock-gear" :group 1))
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 1))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 1))
|
||||
(set! (-> this sound-lock-loop) (static-sound-spec "airlock-turn" :group 1))
|
||||
(set! (-> this sound-lock-stop) (static-sound-spec "airlock-unlock" :group 1))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 1))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-gear) (static-sound-spec "airlock-gear" :group 0))
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 0))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 0))
|
||||
(set! (-> this sound-lock-loop) (static-sound-spec "airlock-turn" :group 0))
|
||||
(set! (-> this sound-lock-stop) (static-sound-spec "airlock-unlock" :group 0))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 0))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
|
||||
@@ -1189,8 +1189,8 @@
|
||||
(the-as pair 0)
|
||||
)
|
||||
(init-airlock! this)
|
||||
(set! (-> this sound-open) (static-sound-spec "hqdoor-open" :group 1))
|
||||
(set! (-> this sound-close) (static-sound-spec "hqdoor-close" :group 1))
|
||||
(set! (-> this sound-open) (static-sound-spec "hqdoor-open" :group 0))
|
||||
(set! (-> this sound-close) (static-sound-spec "hqdoor-close" :group 0))
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
|
||||
@@ -1242,8 +1242,8 @@
|
||||
(the-as pair 0)
|
||||
)
|
||||
(init-airlock! this)
|
||||
(set! (-> this sound-open) (static-sound-spec "vindoor-open" :group 1))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "vindoor-close" :group 1))
|
||||
(set! (-> this sound-open) (static-sound-spec "vindoor-open" :group 0))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "vindoor-close" :group 0))
|
||||
(set! (-> this door-radius) 8192.0)
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
@@ -1299,15 +1299,15 @@
|
||||
)
|
||||
(the-as pair 0)
|
||||
)
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 1))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 1))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 1))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 1))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 1))
|
||||
(set! (-> this sound-post-close) (static-sound-spec "airlock-slider" :group 1))
|
||||
(set! (-> this sound-post-close-stop) (static-sound-spec "airlock-slide-e" :group 1))
|
||||
(set! (-> this sound-pre-open) (static-sound-spec "airlock-slider" :group 0))
|
||||
(set! (-> this sound-pre-open-stop) (static-sound-spec "airlock-slide-e" :group 0))
|
||||
(set! (-> this sound-open) (static-sound-spec "airlock-seal" :group 0))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "airlock-open" :group 0))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "airlock-hit" :group 0))
|
||||
(set! (-> this sound-post-close) (static-sound-spec "airlock-slider" :group 0))
|
||||
(set! (-> this sound-post-close-stop) (static-sound-spec "airlock-slide-e" :group 0))
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
|
||||
@@ -1359,10 +1359,10 @@
|
||||
(the-as pair 0)
|
||||
)
|
||||
(init-airlock! this)
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "wood-door-open" :group 1))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "wood-open-hit" :group 1))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "wood-door-close" :group 1))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "wood-close-hit" :group 1))
|
||||
(set! (-> this sound-open-loop) (static-sound-spec "wood-door-open" :group 0))
|
||||
(set! (-> this sound-open-stop) (static-sound-spec "wood-open-hit" :group 0))
|
||||
(set! (-> this sound-close-loop) (static-sound-spec "wood-door-close" :group 0))
|
||||
(set! (-> this sound-close-stop) (static-sound-spec "wood-close-hit" :group 0))
|
||||
(set! (-> this door-radius) 8192.0)
|
||||
(go (method-of-object this close) #t)
|
||||
)
|
||||
|
||||
@@ -249,25 +249,25 @@
|
||||
(set! s5-0 (-> *part-group-id-table* 164))
|
||||
(set! (-> this collect-effect) (-> *part-group-id-table* 170))
|
||||
(set! (-> this collect-effect2) (-> *part-group-id-table* 165))
|
||||
(set! s4-0 (static-sound-spec "yel-eco-idle" :group 1 :fo-max 15))
|
||||
(set! s4-0 (static-sound-spec "yel-eco-idle" :group 0 :fo-max 15))
|
||||
)
|
||||
(((pickup-type eco-red))
|
||||
(set! s5-0 (-> *part-group-id-table* 158))
|
||||
(set! (-> this collect-effect) (-> *part-group-id-table* 171))
|
||||
(set! (-> this collect-effect2) (-> *part-group-id-table* 159))
|
||||
(set! s4-0 (static-sound-spec "red-eco-idle" :group 1 :fo-max 15))
|
||||
(set! s4-0 (static-sound-spec "red-eco-idle" :group 0 :fo-max 15))
|
||||
)
|
||||
(((pickup-type eco-blue))
|
||||
(set! s5-0 (-> *part-group-id-table* 154))
|
||||
(set! (-> this collect-effect) (-> *part-group-id-table* 169))
|
||||
(set! (-> this collect-effect2) (-> *part-group-id-table* 155))
|
||||
(set! s4-0 (static-sound-spec "blue-eco-idle" :group 1 :fo-max 15))
|
||||
(set! s4-0 (static-sound-spec "blue-eco-idle" :group 0 :fo-max 15))
|
||||
)
|
||||
(((pickup-type eco-green))
|
||||
(set! s5-0 (-> *part-group-id-table* 129))
|
||||
(set! (-> this collect-effect) (-> *part-group-id-table* 141))
|
||||
(set! (-> this collect-effect2) (-> *part-group-id-table* 124))
|
||||
(set! s4-0 (static-sound-spec "green-eco-idle" :group 1 :fo-max 15))
|
||||
(set! s4-0 (static-sound-spec "green-eco-idle" :group 0 :fo-max 15))
|
||||
)
|
||||
(((pickup-type health))
|
||||
(initialize-skeleton
|
||||
@@ -281,7 +281,7 @@
|
||||
)
|
||||
(set! (-> this collect-effect) (-> *part-group-id-table* 141))
|
||||
(set! (-> this collect-effect2) (-> *part-group-id-table* 124))
|
||||
(set! s4-0 (static-sound-spec "green-eco-idle" :group 1 :fo-max 15))
|
||||
(set! s4-0 (static-sound-spec "green-eco-idle" :group 0 :fo-max 15))
|
||||
)
|
||||
(((pickup-type eco-pill-green))
|
||||
(set! s5-0 (-> *part-group-id-table* 125))
|
||||
|
||||
@@ -448,7 +448,7 @@
|
||||
(logclear! (-> self root status) (collide-status on-surface on-ground touch-surface))
|
||||
(let ((s5-1 2))
|
||||
(logior! (-> self focus-status) (focus-status in-air))
|
||||
(until (on-ground? self)
|
||||
(until (on-ground? self gp-0)
|
||||
(+! (-> gp-0 hang-time) (- (current-time) (-> self clock old-frame-counter)))
|
||||
(jump-anim-handler self s5-1 gp-0)
|
||||
(in-jump-handler self s5-1 gp-0)
|
||||
|
||||
@@ -53,7 +53,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype manipy (process-drawable)
|
||||
((root collide-shape :override)
|
||||
((self manipy :override)
|
||||
(root collide-shape :override)
|
||||
(new-trans-hook (function none))
|
||||
(cur-trans-hook (function none))
|
||||
(cur-event-hook (function none))
|
||||
|
||||
@@ -164,12 +164,11 @@
|
||||
)
|
||||
(update-anim-data (-> self skel))
|
||||
(do-joint-math (-> self draw) (-> self node-list) (-> self skel))
|
||||
;; not-yet-implemented
|
||||
;; (let ((a0-22 (-> self skel effect)))
|
||||
;; (if a0-22
|
||||
;; (effect-control-method-9 a0-22)
|
||||
;; )
|
||||
;; )
|
||||
(let ((a0-22 (-> self skel effect)))
|
||||
(if a0-22
|
||||
(effect-control-method-9 a0-22)
|
||||
)
|
||||
)
|
||||
(if (logtest? (-> self skel status) (joint-control-status blend-shape blend-shape-valid))
|
||||
(merc-blend-shape self)
|
||||
)
|
||||
@@ -3656,11 +3655,7 @@
|
||||
(dotimes (s3-0 (-> this actor-group s4-0 length))
|
||||
(set! sv-32 "#f")
|
||||
(set! (-> this particle-launchers (-> this particle-launchers length))
|
||||
(entity-lookup-part-group
|
||||
(the-as entity-actor (-> this actor-group s4-0 data s3-0 actor))
|
||||
(& sv-32)
|
||||
'art-name
|
||||
)
|
||||
(entity-lookup-part-group (-> this actor-group s4-0 data s3-0 actor) (& sv-32) 'art-name)
|
||||
)
|
||||
(+! (-> this particle-launchers length) 1)
|
||||
)
|
||||
|
||||
@@ -7,3 +7,391 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype rigid-body-platform-constants (rigid-body-object-constants)
|
||||
((drag-factor float)
|
||||
(buoyancy-factor float)
|
||||
(max-buoyancy-depth meters)
|
||||
(player-weight meters)
|
||||
(player-bonk-factor float)
|
||||
(player-dive-factor float)
|
||||
(player-force-distance meters)
|
||||
(player-force-clamp meters)
|
||||
(player-force-timeout time-frame)
|
||||
(explosion-force meters)
|
||||
(control-point-count int32)
|
||||
(platform symbol)
|
||||
(sound-name string)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(deftype rigid-body-control-point (structure)
|
||||
((local-pos vector :inline)
|
||||
(world-pos vector :inline)
|
||||
(velocity vector :inline)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(deftype rigid-body-control-point-inline-array (inline-array-class)
|
||||
((data rigid-body-control-point :inline :dynamic)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(set! (-> rigid-body-control-point-inline-array heap-base) (the-as uint 48))
|
||||
|
||||
(deftype rigid-body-platform (rigid-body-object)
|
||||
((info rigid-body-platform-constants :override)
|
||||
(control-point-array rigid-body-control-point-inline-array)
|
||||
(float-height-offset float)
|
||||
(player-bonk-timeout time-frame)
|
||||
(water-anim entity-actor)
|
||||
)
|
||||
(:methods
|
||||
(get-lava-height (_type_ vector) float)
|
||||
(rigid-body-platform-method-57 (_type_ (inline-array vector)) none)
|
||||
(rigid-body-platform-method-58 (_type_) none)
|
||||
(rigid-body-platform-method-59 (_type_ vector) none)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(defmethod relocate ((this rigid-body-platform) (offset int))
|
||||
(if (nonzero? (-> this control-point-array))
|
||||
(&+! (-> this control-point-array) offset)
|
||||
)
|
||||
(call-parent-method this offset)
|
||||
)
|
||||
|
||||
(defmethod get-lava-height ((this rigid-body-platform) (arg0 vector))
|
||||
(let ((v1-0 (-> this water-anim)))
|
||||
0.0
|
||||
(cond
|
||||
(v1-0
|
||||
(let ((a0-1 v1-0))
|
||||
(if (if a0-1
|
||||
(-> a0-1 extra process)
|
||||
)
|
||||
(-> v1-0 extra trans y)
|
||||
(-> v1-0 extra trans y)
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
(get-height *ocean* arg0 #t)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod rigid-body-platform-method-57 ((this rigid-body-platform) (arg0 (inline-array vector)))
|
||||
(set! (-> arg0 1 w) (+ (get-lava-height this (-> arg0 1)) (-> this float-height-offset)))
|
||||
(let* ((s4-0 (new 'stack-no-clear 'vector))
|
||||
(f0-3 (- (-> arg0 1 w) (-> arg0 1 y)))
|
||||
(f30-0 (/ f0-3 (-> this info max-buoyancy-depth)))
|
||||
)
|
||||
(when (< 0.0 f0-3)
|
||||
(vector-float*!
|
||||
s4-0
|
||||
*y-vector*
|
||||
(* (-> this rbody info mass)
|
||||
(fmin 1.0 f30-0)
|
||||
(/ (-> this info extra gravity) (the float (-> this info control-point-count)))
|
||||
(-> this info buoyancy-factor)
|
||||
)
|
||||
)
|
||||
(apply-impact! (-> this rbody) (-> arg0 1) s4-0)
|
||||
(vector-float*! s4-0 (-> arg0 2) (* -1.0 (-> this info drag-factor) (fmin 1.0 f30-0)))
|
||||
(apply-impact! (-> this rbody) (-> arg0 1) s4-0)
|
||||
)
|
||||
)
|
||||
0
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod rigid-body-object-method-53 ((this rigid-body-platform) (arg0 float))
|
||||
(when (logtest? (-> this flags) (rigid-body-object-flag player-impulse-force player-contact-force))
|
||||
(if (logtest? (-> this flags) (rigid-body-object-flag player-impulse-force))
|
||||
(logclear! (-> this flags) (rigid-body-object-flag player-impulse-force))
|
||||
)
|
||||
(rigid-body-control-method-21
|
||||
(-> this rbody)
|
||||
(-> this player-force-position)
|
||||
(-> this player-force)
|
||||
(-> this info player-force-distance)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod rigid-body-platform-method-58 ((this rigid-body-platform))
|
||||
(let ((a1-0 (new 'stack-no-clear 'vector)))
|
||||
(vector-float*! a1-0 *y-vector* (* -1.0 (-> this info extra gravity) (-> this rbody info mass)))
|
||||
(add-force! (-> this rbody) a1-0)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod rigid-body-platform-method-59 ((this rigid-body-platform) (arg0 vector))
|
||||
(let ((v1-0 (new 'stack-no-clear 'vector)))
|
||||
(vector-! v1-0 arg0 (-> this rbody position))
|
||||
(set! (-> v1-0 y) 0.0)
|
||||
(let* ((f0-1 (vector-length v1-0))
|
||||
(f1-1 (* 10.0 (fmax 0.0 (fmin 4096.0 (+ -4096.0 f0-1)))))
|
||||
)
|
||||
(when (< 0.0 f1-1)
|
||||
(vector-float*! v1-0 v1-0 (/ f1-1 f0-1))
|
||||
(add-force! (-> this rbody) v1-0)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod apply-gravity! ((this rigid-body-platform) (arg0 float))
|
||||
(let ((s4-0 (-> this rbody matrix)))
|
||||
(dotimes (s3-0 (-> this info control-point-count))
|
||||
(let ((s2-0 (-> this control-point-array data s3-0)))
|
||||
(vector-matrix*! (-> s2-0 world-pos) (-> s2-0 local-pos) s4-0)
|
||||
(rigid-body-control-method-23 (-> this rbody) (-> s2-0 world-pos) (-> s2-0 velocity))
|
||||
(rigid-body-platform-method-57 this (the-as (inline-array vector) s2-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
(rigid-body-platform-method-58 this)
|
||||
(rigid-body-object-method-53 this arg0)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod rigid-body-object-method-32 ((this rigid-body-platform))
|
||||
(if (-> this info platform)
|
||||
(detect-riders! (-> this root))
|
||||
)
|
||||
(let ((t9-1 (method-of-type rigid-body-object rigid-body-object-method-32)))
|
||||
(t9-1 this)
|
||||
)
|
||||
(logclear! (-> this flags) (rigid-body-object-flag player-contact-force))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod attack-handler ((this rigid-body-platform)
|
||||
(arg0 process-drawable)
|
||||
(arg1 attack-info)
|
||||
(arg2 touching-shapes-entry)
|
||||
(arg3 penetrate)
|
||||
)
|
||||
((method-of-type rigid-body-object attack-handler) this arg0 arg1 arg2 arg3)
|
||||
#f
|
||||
)
|
||||
|
||||
(defmethod rbody-event-handler ((this rigid-body-platform) (arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(case arg2
|
||||
(('edge-grabbed)
|
||||
(let ((v1-1 (the-as object (-> arg3 param 0))))
|
||||
(when (not (logtest? (-> this flags) (rigid-body-object-flag player-impulse-force)))
|
||||
(logior! (-> this flags) (rigid-body-object-flag player-contact-force))
|
||||
(set! (-> this player-force-position quad) (-> (the-as rigid-body-control-point v1-1) velocity quad))
|
||||
(vector-reset! (-> this player-force))
|
||||
(set! (-> this player-force y) (* -1.0 (-> this info player-weight)))
|
||||
)
|
||||
)
|
||||
)
|
||||
(('ridden)
|
||||
(let ((v1-7 (the-as object (-> arg3 param 0))))
|
||||
(when (the-as uint v1-7)
|
||||
(let* ((s5-1 (handle->process (-> (the-as collide-rider v1-7) rider-handle)))
|
||||
(v1-11 (if (type? s5-1 process-focusable)
|
||||
s5-1
|
||||
)
|
||||
)
|
||||
)
|
||||
(when (and v1-11
|
||||
(logtest? (-> v1-11 mask) (process-mask target))
|
||||
(not (logtest? (-> (the-as process-focusable v1-11) focus-status) (focus-status on-water under-water)))
|
||||
)
|
||||
(when (not (logtest? (-> this flags) (rigid-body-object-flag player-impulse-force)))
|
||||
(logior! (-> this flags) (rigid-body-object-flag player-contact-force))
|
||||
(set! (-> this player-force-position quad) (-> (the-as process-focusable v1-11) root trans quad))
|
||||
(vector-reset! (-> this player-force))
|
||||
(let* ((a1-5 (-> this player-force-position))
|
||||
(f30-0 0.0)
|
||||
(f28-0 1.0)
|
||||
(f26-0 1.0)
|
||||
(f0-4 (+ (- -4096.0 (-> a1-5 y)) (get-lava-height this a1-5)))
|
||||
(f1-2 12288.0)
|
||||
(f0-8 (fmax f30-0 (fmin f28-0 (- f26-0 (* f0-4 (/ 1.0 f1-2))))))
|
||||
)
|
||||
(set! (-> this player-force y) (* -1.0 (-> this info player-weight) f0-8))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('bonk)
|
||||
(when (time-elapsed? (-> this player-bonk-timeout) (-> this info player-force-timeout))
|
||||
(set-time! (-> this player-bonk-timeout))
|
||||
(let* ((s4-0 arg0)
|
||||
(v1-31 (if (type? s4-0 process-drawable)
|
||||
s4-0
|
||||
)
|
||||
)
|
||||
)
|
||||
(when v1-31
|
||||
(logior! (-> this flags) (rigid-body-object-flag player-impulse-force))
|
||||
(set! (-> this player-force-position quad) (-> (the-as process-focusable v1-31) root trans quad))
|
||||
(let ((f0-14 (fmin
|
||||
(* 0.00012207031
|
||||
(the-as float (-> arg3 param 1))
|
||||
(-> this info player-bonk-factor)
|
||||
(-> this info player-weight)
|
||||
)
|
||||
(-> this info player-force-clamp)
|
||||
)
|
||||
)
|
||||
)
|
||||
(vector-reset! (-> this player-force))
|
||||
(set! (-> this player-force y) (- f0-14))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
((method-of-type rigid-body-object rbody-event-handler) this arg0 arg1 arg2 arg3)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod rbody-post ((this rigid-body-platform))
|
||||
(if (logtest? (-> this flags) (rigid-body-object-flag player-impulse-force))
|
||||
(sound-play-by-name (string->sound-name (-> this info sound-name)) (new-sound-id) 1024 0 0 (sound-group) #t)
|
||||
)
|
||||
(rigid-body-object-method-32 this)
|
||||
(quaternion-copy! (-> this root quat) (the-as quaternion (-> this rbody rot)))
|
||||
(rigid-body-control-method-25 (-> this rbody) (-> this root trans))
|
||||
(rider-post)
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod alloc-rbody-control! ((this rigid-body-platform) (arg0 rigid-body-object-constants))
|
||||
(set! (-> this info) (the-as rigid-body-platform-constants arg0))
|
||||
(set! (-> this rbody) (new 'process 'rigid-body-control this))
|
||||
(set! (-> this control-point-array)
|
||||
(new 'process 'rigid-body-control-point-inline-array (-> this info control-point-count))
|
||||
)
|
||||
(update-transforms (-> this root))
|
||||
(init!
|
||||
(-> this rbody)
|
||||
(-> this info info)
|
||||
(-> this root trans)
|
||||
(-> this root quat)
|
||||
(the-as (function rigid-body-object float) (method-of-object this apply-gravity!))
|
||||
)
|
||||
(set-time! (-> this player-bonk-timeout))
|
||||
(set! (-> this player-force quad) (-> *null-vector* quad))
|
||||
(set! (-> this root max-iteration-count) (the-as uint 4))
|
||||
(set! (-> this max-time-step) (-> arg0 extra max-time-step))
|
||||
(set! (-> this water-anim) (entity-actor-lookup (-> this entity) 'water-actor 0))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod init-collision! ((this rigid-body-platform))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving this (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
(set! (-> s5-0 no-reaction)
|
||||
(the-as (function collide-shape-moving collide-query vector vector object) nothing)
|
||||
)
|
||||
(let ((s4-0 (new 'process 'collide-shape-prim-mesh s5-0 (the-as uint 0) (the-as uint 0))))
|
||||
(set! (-> s4-0 prim-core collide-as) (collide-spec pusher))
|
||||
(set! (-> s4-0 prim-core collide-with) (collide-spec jak player-list))
|
||||
(set! (-> s4-0 prim-core action) (collide-action solid rideable))
|
||||
(set! (-> s4-0 transform-index) 0)
|
||||
(set-vector! (-> s4-0 local-sphere) 0.0 0.0 0.0 20480.0)
|
||||
(set! (-> s5-0 total-prims) (the-as uint 1))
|
||||
(set! (-> s5-0 root-prim) s4-0)
|
||||
)
|
||||
(pusher-init s5-0)
|
||||
(set! (-> s5-0 nav-radius) (* 0.75 (-> s5-0 root-prim local-sphere w)))
|
||||
(let ((v1-15 (-> s5-0 root-prim)))
|
||||
(set! (-> s5-0 backup-collide-as) (-> v1-15 prim-core collide-as))
|
||||
(set! (-> s5-0 backup-collide-with) (-> v1-15 prim-core collide-with))
|
||||
)
|
||||
(set! (-> this root) s5-0)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(define *rigid-body-platform-constants* (new 'static 'rigid-body-platform-constants
|
||||
:info (new 'static 'rigid-body-info
|
||||
:mass 2.0
|
||||
:inv-mass 0.5
|
||||
:linear-damping 1.0
|
||||
:angular-damping 1.0
|
||||
:bounce-factor 0.5
|
||||
:friction-factor 0.1
|
||||
:cm-offset-joint (new 'static 'vector :w 1.0)
|
||||
:inertial-tensor-box (new 'static 'array meters 3 (meters 4) (meters 4) (meters 4))
|
||||
)
|
||||
:extra (new 'static 'rigid-body-object-extra-info
|
||||
:max-time-step 0.033333335
|
||||
:gravity (meters 80)
|
||||
:idle-distance (meters 50)
|
||||
:attack-force-scale 1.0
|
||||
)
|
||||
:name '*rigid-body-platform-constants*
|
||||
:drag-factor 0.8
|
||||
:buoyancy-factor 1.5
|
||||
:max-buoyancy-depth (meters 1.5)
|
||||
:player-weight (meters 6.6)
|
||||
:player-bonk-factor 1.0
|
||||
:player-dive-factor 1.0
|
||||
:player-force-distance (meters 1000)
|
||||
:player-force-clamp (meters 1000000)
|
||||
:player-force-timeout (seconds 0.1)
|
||||
:explosion-force (meters 1000)
|
||||
:control-point-count 1
|
||||
:platform #t
|
||||
:sound-name #f
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod init-rbody-control! ((this rigid-body-platform))
|
||||
(set! (-> this float-height-offset) 0.0)
|
||||
(alloc-rbody-control! this *rigid-body-platform-constants*)
|
||||
(let ((s5-0 (-> this info control-point-count)))
|
||||
(dotimes (s4-0 s5-0)
|
||||
(let ((s3-0 (-> this control-point-array data s4-0)))
|
||||
(let ((f30-0 (* 65536.0 (/ (the float s4-0) (the float s5-0)))))
|
||||
(set! (-> s3-0 local-pos x) (* 12288.0 (sin f30-0)))
|
||||
(set! (-> s3-0 local-pos y) -10240.0)
|
||||
(set! (-> s3-0 local-pos z) (* 12288.0 (cos f30-0)))
|
||||
)
|
||||
(set! (-> s3-0 local-pos w) 1.0)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch int vs object.
|
||||
(defmethod init-from-entity! ((this rigid-body-platform) (arg0 entity-actor))
|
||||
(logior! (-> this mask) (process-mask platform))
|
||||
(init-collision! this)
|
||||
(process-drawable-from-entity! this arg0)
|
||||
(init-rbody-control! this)
|
||||
(go-idle this)
|
||||
0
|
||||
)
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
(pickup-handle handle)
|
||||
)
|
||||
(:methods
|
||||
(init! (_type_ entity-actor int) object)
|
||||
(init! (_type_ entity-actor pickup-type) object)
|
||||
)
|
||||
(:states
|
||||
vent-blocked
|
||||
@@ -28,7 +28,7 @@
|
||||
)
|
||||
|
||||
|
||||
(defmethod init! ((this vent) (arg0 entity-actor) (arg1 int))
|
||||
(defmethod init! ((this vent) (arg0 entity-actor) (arg1 pickup-type))
|
||||
(stack-size-set! (-> this main-thread) 128)
|
||||
(logior! (-> this mask) (process-mask actor-pause))
|
||||
(let ((s3-0 (new 'process 'collide-shape this (collide-list-enum hit-by-player))))
|
||||
@@ -49,7 +49,7 @@
|
||||
(set! (-> this root trans quad) (-> arg0 extra trans quad))
|
||||
(update-transforms (-> this root))
|
||||
(set! (-> this root pause-adjust-distance) 409600.0)
|
||||
(set! (-> this fact) (new 'process 'fact-info this (the-as pickup-type arg1) (-> *FACT-bank* eco-full-inc)))
|
||||
(set! (-> this fact) (new 'process 'fact-info this arg1 (-> *FACT-bank* eco-full-inc)))
|
||||
(set! (-> this block-func) (the-as (function vent symbol) true-func))
|
||||
(case (-> this fact pickup-type)
|
||||
(((pickup-type eco-blue))
|
||||
@@ -265,7 +265,7 @@
|
||||
|
||||
|
||||
(defmethod init-from-entity! ((this ecovent) (arg0 entity-actor))
|
||||
(init! this arg0 5)
|
||||
(init! this arg0 (pickup-type eco-green))
|
||||
)
|
||||
|
||||
(deftype light-eco-vent (process-drawable)
|
||||
|
||||
@@ -745,7 +745,7 @@
|
||||
(set! (-> this center quad) (-> this root trans quad))
|
||||
(+! (-> this center y) 13516.8)
|
||||
(set! (-> this sound)
|
||||
(new 'process 'ambient-sound (static-sound-spec "warpgate" :group 1 :fo-max 30) (-> this root trans) 0.0)
|
||||
(new 'process 'ambient-sound (static-sound-spec "warpgate" :group 0 :fo-max 30) (-> this root trans) 0.0)
|
||||
)
|
||||
(set! (-> this distance) (res-lump-float (-> this entity) 'distance :default 20480.0))
|
||||
(none)
|
||||
|
||||
@@ -936,14 +936,24 @@
|
||||
(defun collision-edit ((arg0 process))
|
||||
(stop-collision-edit)
|
||||
(when (not arg0)
|
||||
(let ((v1-2 (process-spawn collision-editor-edited-proc :name "collision-editor-edited-proc")))
|
||||
(set! arg0 (if v1-2
|
||||
(the-as process (-> v1-2 0 self))
|
||||
)
|
||||
(let ((gp-1 (get-process *default-dead-pool* collision-editor-edited-proc #x4000 1)))
|
||||
(set! arg0 (ppointer->process (when gp-1
|
||||
(let ((t9-2 (method-of-type collision-editor-edited-proc activate)))
|
||||
(t9-2
|
||||
(the-as collision-editor-edited-proc gp-1)
|
||||
*default-pool*
|
||||
"collision-editor-edited-proc"
|
||||
(the-as pointer #x70004000)
|
||||
)
|
||||
)
|
||||
(run-now-in-process gp-1 collision-editor-edited-proc-init-by-other)
|
||||
(-> gp-1 ppointer)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((gp-2 (process->handle (the-as process-tree arg0))))
|
||||
(let ((gp-2 (process->handle arg0)))
|
||||
(process-spawn collision-editor gp-2 :name "collision-editor")
|
||||
)
|
||||
)
|
||||
|
||||
@@ -1524,19 +1524,19 @@
|
||||
|
||||
|
||||
; ;; draw ocean
|
||||
; (let ((gp-5 (-> pp clock)))
|
||||
; (if (= (-> *time-of-day-context* mode) (time-of-day-palette-id unk3))
|
||||
; (set! (-> pp clock) (-> *display* bg-clock))
|
||||
; (set! (-> pp clock) (-> *display* real-clock))
|
||||
; )
|
||||
; (with-profiler 'ocean *profile-ocean-color*
|
||||
; (draw! *ocean*)
|
||||
; (if *ocean-map*
|
||||
; (update-map *ocean*)
|
||||
; )
|
||||
; )
|
||||
; (set! (-> pp clock) gp-5)
|
||||
; )
|
||||
(let ((gp-5 (-> pp clock)))
|
||||
(if (= (-> *time-of-day-context* mode) (time-of-day-palette-id unk3))
|
||||
(set! (-> pp clock) (-> *display* bg-clock))
|
||||
(set! (-> pp clock) (-> *display* real-clock))
|
||||
)
|
||||
(with-profiler 'ocean *profile-ocean-color*
|
||||
(draw! *ocean*)
|
||||
(if *ocean-map*
|
||||
(update-map *ocean*)
|
||||
)
|
||||
)
|
||||
(set! (-> pp clock) gp-5)
|
||||
)
|
||||
|
||||
;; draw foreground
|
||||
(foreground-engine-execute *foreground-draw-engine*)
|
||||
|
||||
@@ -176,7 +176,7 @@ that gets accessed by the accompanying process."
|
||||
)
|
||||
|
||||
(deftype actor-reference (structure)
|
||||
((actor entity)
|
||||
((actor entity-actor)
|
||||
(id uint32)
|
||||
)
|
||||
:pack-me
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref bubbles-path :method-count 0)
|
||||
:ptype (type-ref bubbles-path :method-count 22)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x8000
|
||||
)
|
||||
@@ -50,7 +50,7 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref tpl-bouncer :method-count 0)
|
||||
:ptype (type-ref tpl-bouncer :method-count 28)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
@@ -70,7 +70,7 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref kleever-catch-lizards :method-count 0)
|
||||
:ptype (type-ref kleever-catch-lizards :method-count 21)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
@@ -85,12 +85,12 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref nav-graph :method-count 0)
|
||||
:ptype (type-ref nav-graph :method-count 45)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref tizard :method-count 0)
|
||||
:ptype (type-ref tizard :method-count 36)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
@@ -110,22 +110,22 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref curve-bubbles-Shape :method-count 0)
|
||||
:ptype (type-ref curve-bubbles-Shape :method-count 15)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-tower-door :method-count 0)
|
||||
:ptype (type-ref mhcity-tower-door :method-count 21)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-grunt-egg-d :method-count 0)
|
||||
:ptype (type-ref mhcity-grunt-egg-d :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-grunt-egg-c :method-count 0)
|
||||
:ptype (type-ref mhcity-grunt-egg-c :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
@@ -135,67 +135,67 @@
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-grunt-egg-b :method-count 0)
|
||||
:ptype (type-ref mhcity-grunt-egg-b :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-grund-egg-a :method-count 0)
|
||||
:ptype (type-ref mhcity-grund-egg-a :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-de-tower-undervines :method-count 0)
|
||||
:ptype (type-ref mhcity-de-tower-undervines :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-vine-wriggler-big :method-count 0)
|
||||
:ptype (type-ref mhcity-vine-wriggler-big :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-vine-wriggler :method-count 0)
|
||||
:ptype (type-ref mhcity-vine-wriggler :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-twitch-blade :method-count 0)
|
||||
:ptype (type-ref mhcity-twitch-blade :method-count 21)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-claw-finger-small :method-count 0)
|
||||
:ptype (type-ref mhcity-claw-finger-small :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-vein-writhing-small :method-count 0)
|
||||
:ptype (type-ref mhcity-vein-writhing-small :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-vein-writhing-large :method-count 0)
|
||||
:ptype (type-ref mhcity-vein-writhing-large :method-count 32)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-dark-eco-nodule :method-count 0)
|
||||
:ptype (type-ref mhcity-dark-eco-nodule :method-count 22)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-dark-eco-door :method-count 0)
|
||||
:ptype (type-ref mhcity-dark-eco-door :method-count 33)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-puffer-large :method-count 0)
|
||||
:ptype (type-ref mhcity-puffer-large :method-count 35)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
(new 'static 'entity-info
|
||||
:ptype (type-ref mhcity-puffer :method-count 0)
|
||||
:ptype (type-ref mhcity-puffer :method-count 35)
|
||||
:pool '*16k-dead-pool*
|
||||
:heap-size #x4000
|
||||
)
|
||||
|
||||
@@ -492,6 +492,25 @@
|
||||
(-> arg0 level task-mask)
|
||||
)
|
||||
|
||||
(defmethod inspect ((this entity))
|
||||
(call-parent-method this)
|
||||
(format #t "~Ttrans: ~`vector`P~%" (-> this trans))
|
||||
(format #t "~Taid: ~A~%" (-> this aid))
|
||||
this
|
||||
)
|
||||
|
||||
(defmethod inspect ((this entity-actor))
|
||||
(call-parent-method this)
|
||||
(format #t "~Tetype: ~A~%" (-> this etype))
|
||||
(format #t "~Ttask: ~d~%" (-> this task))
|
||||
(format #t "~Tkill-mask: #x~X : (" (-> this kill-mask))
|
||||
(bit-enum->string task-mask (-> this kill-mask) #t)
|
||||
(format #t ")~%")
|
||||
(format #t "~Tvis-id: ~d~%" (-> this vis-id))
|
||||
(format #t "~Tquat: ~`vector`P~%" (-> this quat))
|
||||
this
|
||||
)
|
||||
|
||||
(defmethod print ((this process))
|
||||
(cond
|
||||
((and (-> this top-thread) (!= (-> this status) 'dead))
|
||||
@@ -1714,7 +1733,7 @@
|
||||
(set! sv-16 0)
|
||||
(while (< sv-16 (-> s0-0 length))
|
||||
(if (not (-> s0-0 data sv-16 actor))
|
||||
(set! (-> s0-0 data sv-16 actor) (entity-by-aid (-> s0-0 data sv-16 id)))
|
||||
(set! (-> s0-0 data sv-16 actor) (the-as entity-actor (entity-by-aid (-> s0-0 data sv-16 id))))
|
||||
)
|
||||
(set! sv-16 (+ sv-16 1))
|
||||
)
|
||||
|
||||
@@ -190,6 +190,30 @@ This is updated from the entity system used in Crash 2, which had most of these
|
||||
(the-as int (+ (-> this type psize) (* (-> this allocated-length) 16) (-> this data-size)))
|
||||
)
|
||||
|
||||
(defmethod inspect ((this res-lump))
|
||||
(format #t "[~8x] ~A~%" this (-> this type))
|
||||
(format #t "~Textra: ~A~%" (-> this extra))
|
||||
(format #t "~Tallocated-length: ~D~%" (-> this allocated-length))
|
||||
(format #t "~Tlength: ~D~%" (-> this length))
|
||||
(format #t "~Tdata-base: #x~X~%" (-> this data-base))
|
||||
(format #t "~Tdata-top: #x~X~%" (-> this data-top))
|
||||
(format #t "~Tdata-size: #x~X~%" (-> this data-size))
|
||||
(format #t "~Ttag[~D]: @ #x~X~%" (-> this allocated-length) (-> this tag))
|
||||
(dotimes (i (-> this length))
|
||||
(format #t "~T [~D] " i)
|
||||
(print (-> (-> this tag) i))
|
||||
(format #t " @ #x~X" (get-tag-index-data this i))
|
||||
(cond
|
||||
((res-ref? (-> this tag i))
|
||||
(format #t " = ~A~%" (deref basic (get-tag-index-data this i)))
|
||||
)
|
||||
(else
|
||||
(format #t "~%")
|
||||
)
|
||||
)
|
||||
)
|
||||
this
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch int vs res-tag-pair.
|
||||
(defmethod lookup-tag-idx ((this res-lump) (arg0 symbol) (arg1 symbol) (arg2 float))
|
||||
|
||||
@@ -255,25 +255,28 @@
|
||||
)
|
||||
|
||||
(defmethod play-effects-from-res-lump ((this effect-control) (arg0 float) (arg1 float) (arg2 float))
|
||||
(let ((s2-0 (-> this name)))
|
||||
(while (= (-> s2-0 0 name) 'effect-name)
|
||||
(let ((f0-0 (-> s2-0 0 key-frame)))
|
||||
(when (or (and (< f0-0 arg1) (< arg0 f0-0)) (= f0-0 arg2))
|
||||
(let* ((a0-1 this)
|
||||
(t9-0 (method-of-object a0-1 do-effect))
|
||||
(v1-7 (-> this res))
|
||||
(a1-1 (-> s2-0 0))
|
||||
)
|
||||
(t9-0
|
||||
a0-1
|
||||
(the-as string (-> (the-as (pointer int32) (&+ (-> v1-7 data-base) (-> a1-1 data-offset)))))
|
||||
f0-0
|
||||
-1
|
||||
;; og:preserve-this added check
|
||||
(when (-> this name)
|
||||
(let ((s2-0 (-> this name)))
|
||||
(while (= (-> s2-0 0 name) 'effect-name)
|
||||
(let ((f0-0 (-> s2-0 0 key-frame)))
|
||||
(when (or (and (< f0-0 arg1) (< arg0 f0-0)) (= f0-0 arg2))
|
||||
(let* ((a0-1 this)
|
||||
(t9-0 (method-of-object a0-1 do-effect))
|
||||
(v1-7 (-> this res))
|
||||
(a1-1 (-> s2-0 0))
|
||||
)
|
||||
(t9-0
|
||||
a0-1
|
||||
(the-as string (-> (the-as (pointer int32) (&+ (-> v1-7 data-base) (-> a1-1 data-offset)))))
|
||||
f0-0
|
||||
-1
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! s2-0 (&-> s2-0 1))
|
||||
)
|
||||
(set! s2-0 (&-> s2-0 1))
|
||||
)
|
||||
)
|
||||
0
|
||||
@@ -302,18 +305,19 @@
|
||||
(return #f)
|
||||
)
|
||||
((string= s3-0 "script")
|
||||
(let ((gp-1 (get-property-struct
|
||||
(-> this res)
|
||||
'effect-script
|
||||
'exact
|
||||
arg1
|
||||
(the-as structure #f)
|
||||
(the-as (pointer res-tag) #f)
|
||||
*res-static-buf*
|
||||
)
|
||||
(let ((gp-1 (the-as pair (get-property-struct
|
||||
(-> this res)
|
||||
'effect-script
|
||||
'exact
|
||||
arg1
|
||||
(the-as structure #f)
|
||||
(the-as (pointer res-tag) #f)
|
||||
*res-static-buf*
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(script-eval (the-as pair gp-1))
|
||||
(script-eval gp-1)
|
||||
)
|
||||
(return #f)
|
||||
)
|
||||
|
||||
@@ -112,7 +112,8 @@
|
||||
This handles drawing, collision, animation, navigation, particles, sounds, physics, etc.
|
||||
The actual child classes will add most of the functionality, and this just serves as a common
|
||||
container for references to the `-control` objects for this object."
|
||||
((root trsqv)
|
||||
((self process-drawable :override)
|
||||
(root trsqv)
|
||||
(node-list cspace-array)
|
||||
(draw draw-control)
|
||||
(skel joint-control)
|
||||
|
||||
@@ -118,17 +118,17 @@
|
||||
;; +++main-h:race-marks-controls
|
||||
(defenum race-marks-controls
|
||||
:type int64
|
||||
; (all-off 0)
|
||||
; (path0-red 1)
|
||||
; (path1-green 2)
|
||||
; (path2-blue 4)
|
||||
; (path3-yellow 8)
|
||||
; (path4-cyan 16)
|
||||
; (path5-violet 32)
|
||||
; (path6-orange 64)
|
||||
; (path7-black 128)
|
||||
; (all-paths-on 255)
|
||||
; (rmc2040 2040)
|
||||
(all-off 0)
|
||||
(path0-red 1)
|
||||
(path1-green 2)
|
||||
(path2-blue 4)
|
||||
(path3-yellow 8)
|
||||
(path4-cyan 16)
|
||||
(path5-violet 32)
|
||||
(path6-orange 64)
|
||||
(path7-black 128)
|
||||
(all-paths-on 255)
|
||||
(rmc2040 2040)
|
||||
)
|
||||
;; ---main-h:race-marks-controls
|
||||
|
||||
|
||||
@@ -73,6 +73,7 @@
|
||||
|
||||
(declare-type task-manager process)
|
||||
(declare-type game-task-node-info basic)
|
||||
(declare-type traffic-engine basic)
|
||||
(define-extern task-manager-init-by-other (function game-task-node-info symbol object :behavior task-manager))
|
||||
|
||||
;; DECOMP BEGINS
|
||||
@@ -1538,4 +1539,4 @@
|
||||
)
|
||||
|
||||
|
||||
(define *traffic-engine* #f)
|
||||
(define *traffic-engine* (the-as traffic-engine #f))
|
||||
|
||||
@@ -147,21 +147,18 @@
|
||||
(set! (-> *game-info* dark-crystal) 0.0)
|
||||
)
|
||||
)
|
||||
;; og:preserve-this not-yet-implemented check
|
||||
(if (nonzero? *minimap*)
|
||||
(let ((s5-0 (-> *minimap* engine alive-list)))
|
||||
(while s5-0
|
||||
(let ((s4-0 s5-0))
|
||||
(if (and (logtest? (-> s4-0 flags) (minimap-flag task-graph))
|
||||
(or (not (game-task-node-info-method-12 (-> *game-info* sub-task-list (-> s4-0 node))))
|
||||
(not (minimap-class-node-method-9 (-> s4-0 class)))
|
||||
)
|
||||
)
|
||||
(logior! (-> s4-0 flags) (minimap-flag fade-out))
|
||||
)
|
||||
)
|
||||
(set! s5-0 (-> s5-0 next))
|
||||
(let ((s5-0 (-> *minimap* engine alive-list)))
|
||||
(while s5-0
|
||||
(let ((s4-0 s5-0))
|
||||
(if (and (logtest? (-> s4-0 flags) (minimap-flag task-graph))
|
||||
(or (not (game-task-node-info-method-12 (-> *game-info* sub-task-list (-> s4-0 node))))
|
||||
(not (minimap-class-node-method-9 (-> s4-0 class)))
|
||||
)
|
||||
)
|
||||
(logior! (-> s4-0 flags) (minimap-flag fade-out))
|
||||
)
|
||||
)
|
||||
(set! s5-0 (-> s5-0 next))
|
||||
)
|
||||
)
|
||||
(let ((v1-43 (-> *game-info* task-node-exclusive)))
|
||||
@@ -271,34 +268,31 @@
|
||||
(set! sv-176 (-> s1-0 when-open s0-0))
|
||||
(case (-> sv-176 actor)
|
||||
(((game-task-actor minimap))
|
||||
;; og:preserve-this not-yet-implemented check
|
||||
(when (and (nonzero? *minimap*) (nonzero? *minimap-class-list*))
|
||||
(if (not (minimap-class-node-method-9 (-> *minimap-class-list* (-> sv-176 icon))))
|
||||
(goto cfg-75)
|
||||
)
|
||||
(let ((v1-89 (add-icon! *minimap* *dproc* (-> sv-176 icon) (the-as int (-> sv-176 icon)) (the-as vector #f) s2-0)))
|
||||
(when v1-89
|
||||
(logior! (-> v1-89 flags) (minimap-flag task-graph))
|
||||
(cond
|
||||
((and (logtest? (minimap-flag ctywide) (-> v1-89 class flags))
|
||||
(logtest? (minimap-flag transport) (-> v1-89 class flags))
|
||||
)
|
||||
(let ((v1-91 (add-icon! *minimap* *dproc* (the-as uint 21) 21 (the-as vector #f) s2-0)))
|
||||
(if v1-91
|
||||
(logior! (-> v1-91 flags) (minimap-flag task-graph))
|
||||
)
|
||||
(if (not (minimap-class-node-method-9 (-> *minimap-class-list* (-> sv-176 icon))))
|
||||
(goto cfg-75)
|
||||
)
|
||||
(let ((v1-89 (add-icon! *minimap* *dproc* (-> sv-176 icon) (the-as int (-> sv-176 icon)) (the-as vector #f) s2-0)))
|
||||
(when v1-89
|
||||
(logior! (-> v1-89 flags) (minimap-flag task-graph))
|
||||
(cond
|
||||
((and (logtest? (minimap-flag ctywide) (-> v1-89 class flags))
|
||||
(logtest? (minimap-flag transport) (-> v1-89 class flags))
|
||||
)
|
||||
)
|
||||
((and (logtest? (minimap-flag wasall waswide desert) (-> v1-89 class flags))
|
||||
(logtest? (minimap-flag transport) (-> v1-89 class flags))
|
||||
)
|
||||
(let ((v1-96 (add-icon! *minimap* *dproc* (the-as uint 18) 18 (the-as vector #f) s2-0)))
|
||||
(if v1-96
|
||||
(logior! (-> v1-96 flags) (minimap-flag task-graph))
|
||||
)
|
||||
(let ((v1-91 (add-icon! *minimap* *dproc* (the-as uint 21) 21 (the-as vector #f) s2-0)))
|
||||
(if v1-91
|
||||
(logior! (-> v1-91 flags) (minimap-flag task-graph))
|
||||
)
|
||||
)
|
||||
)
|
||||
((and (logtest? (minimap-flag wasall waswide desert) (-> v1-89 class flags))
|
||||
(logtest? (minimap-flag transport) (-> v1-89 class flags))
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-96 (add-icon! *minimap* *dproc* (the-as uint 18) 18 (the-as vector #f) s2-0)))
|
||||
(if v1-96
|
||||
(logior! (-> v1-96 flags) (minimap-flag task-graph))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -2864,7 +2858,7 @@
|
||||
)
|
||||
|
||||
(defbehavior task-manager-init-by-other task-manager ((arg0 game-task-node-info) (arg1 symbol))
|
||||
(stack-size-set! (-> self main-thread) 1024)
|
||||
(stack-size-set! (-> self main-thread) 2048)
|
||||
(add-connection *task-manager-engine* self nothing self arg0 #f)
|
||||
(set! (-> self node-info) arg0)
|
||||
(set! (-> self lev-name) arg1)
|
||||
|
||||
@@ -11,3 +11,187 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype ripple-request (structure)
|
||||
((waveform ripple-wave)
|
||||
(effect merc-effect)
|
||||
)
|
||||
:pack-me
|
||||
)
|
||||
|
||||
|
||||
(deftype ripple-globals (structure)
|
||||
((count int32)
|
||||
(requests ripple-request 16 :inline)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(define *ripple-globals* (new 'global 'ripple-globals))
|
||||
|
||||
(defun ripple-make-request ((arg0 ripple-wave) (arg1 merc-effect))
|
||||
(let ((v1-1 (-> *ripple-globals* count))
|
||||
(a2-1 (-> *ripple-globals* requests))
|
||||
(a3-0 0)
|
||||
)
|
||||
(when (< v1-1 16)
|
||||
(dotimes (t0-1 v1-1)
|
||||
(if (= arg1 (-> a2-1 t0-1 effect))
|
||||
(set! a3-0 1)
|
||||
)
|
||||
)
|
||||
(when (zero? a3-0)
|
||||
(set! (-> a2-1 v1-1 effect) arg1)
|
||||
(set! (-> a2-1 v1-1 waveform) arg0)
|
||||
(+! (-> *ripple-globals* count) 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defun ripple-update-waveform-offs ((arg0 ripple-wave-set) (arg1 clock))
|
||||
(let ((f0-1 (the float (- (-> arg1 integral-frame-counter) (the-as int (-> arg0 frame-save))))))
|
||||
(when (!= f0-1 0.0)
|
||||
(dotimes (v1-3 (-> arg0 count))
|
||||
(let ((a2-4 (-> arg0 wave v1-3)))
|
||||
(+! (-> a2-4 offs) (* f0-1 (-> a2-4 delta)))
|
||||
(set! (-> a2-4 offs) (the float (logand (the int (-> a2-4 offs)) #xffff)))
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 frame-save) (the-as uint (-> arg1 integral-frame-counter)))
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(def-mips2c ripple-execute-init (function none))
|
||||
|
||||
(def-mips2c ripple-create-wave-table (function ripple-wave-set int))
|
||||
|
||||
(def-mips2c ripple-apply-wave-table (function merc-effect symbol))
|
||||
|
||||
(defun ripple-execute ()
|
||||
(when (-> *ripple-globals* count)
|
||||
(ripple-execute-init)
|
||||
(let ((gp-0 0)
|
||||
(s5-0 (-> *ripple-globals* count))
|
||||
(s4-0 (-> *ripple-globals* requests))
|
||||
)
|
||||
(while (!= gp-0 s5-0)
|
||||
(when (-> s4-0 gp-0 waveform)
|
||||
(let ((s3-0 gp-0)
|
||||
(s2-0 (-> s4-0 gp-0 waveform))
|
||||
)
|
||||
(ripple-create-wave-table (the-as ripple-wave-set s2-0))
|
||||
(while (!= s3-0 s5-0)
|
||||
(when (= s2-0 (-> s4-0 s3-0 waveform))
|
||||
(ripple-apply-wave-table (-> s4-0 s3-0 effect))
|
||||
(set! (-> s4-0 s3-0 waveform) #f)
|
||||
)
|
||||
(+! s3-0 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! gp-0 1)
|
||||
)
|
||||
)
|
||||
(set! (-> *ripple-globals* count) 0)
|
||||
0
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(def-mips2c ripple-matrix-scale (function merc-effect none))
|
||||
|
||||
;; WARN: Return type mismatch symbol vs none.
|
||||
(defun-debug ripple-add-debug-sphere ((arg0 process-drawable) (arg1 vector) (arg2 float) (arg3 float))
|
||||
(let ((f30-0 (- (quaternion-y-angle (-> arg0 root quat))))
|
||||
(s5-0 (new-stack-vector0))
|
||||
)
|
||||
(let ((f28-0 (+ (-> arg1 x) (* arg2 (-> arg1 z))))
|
||||
(f26-0 (+ (-> arg1 y) (* arg3 (-> arg1 z))))
|
||||
)
|
||||
(set! (-> s5-0 x) (- (* f28-0 (cos f30-0)) (* f26-0 (sin f30-0))))
|
||||
(set! (-> s5-0 y) 0.0)
|
||||
(set! (-> s5-0 z) (+ (* f26-0 (cos f30-0)) (* f28-0 (sin f30-0))))
|
||||
)
|
||||
(set! (-> s5-0 w) 0.0)
|
||||
(vector+! s5-0 s5-0 (-> arg0 root trans))
|
||||
(add-debug-sphere #t (bucket-id debug) s5-0 (meters 0.5) (new 'static 'rgba :r #xff :g #xff :a #x80))
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
(defun ripple-slow-add-sine-waves ((arg0 ripple-wave-set) (arg1 float) (arg2 float))
|
||||
(let ((f30-0 0.0))
|
||||
(dotimes (s3-0 (-> arg0 count))
|
||||
(let* ((v1-3 (-> arg0 wave s3-0))
|
||||
(f0-2 (+ (-> v1-3 offs) (* arg1 (-> v1-3 xmul)) (* arg2 (-> v1-3 zmul))))
|
||||
)
|
||||
(+! f30-0 (* (-> v1-3 scale) (cos f0-2)))
|
||||
)
|
||||
)
|
||||
(fmax -127.0 (fmin 127.0 f30-0))
|
||||
)
|
||||
)
|
||||
|
||||
(defun ripple-find-height ((arg0 process-drawable) (arg1 int) (arg2 vector))
|
||||
(local-vars (sv-16 draw-control) (sv-32 float) (sv-48 float))
|
||||
(let ((f30-0 (-> arg0 root trans y)))
|
||||
(set! sv-16 (-> arg0 draw))
|
||||
(if (or (zero? sv-16) (not (-> sv-16 ripple)))
|
||||
(return f30-0)
|
||||
)
|
||||
(let ((v1-11 (-> sv-16 lod-set lod (-> sv-16 cur-lod) geo effect)))
|
||||
(if (not (logtest? (-> v1-11 0 effect-bits) (effect-bits ripple)))
|
||||
(return f30-0)
|
||||
)
|
||||
(let* ((v1-12 (-> v1-11 0 extra-info))
|
||||
(s4-0 (the-as mei-ripple (+ (the-as uint v1-12) (* (-> v1-12 ripple-offset) 16))))
|
||||
(gp-0 (-> sv-16 ripple))
|
||||
(s5-0 (-> gp-0 waveform))
|
||||
)
|
||||
(if (not (-> gp-0 waveform))
|
||||
(return f30-0)
|
||||
)
|
||||
(if (not (-> s5-0 converted))
|
||||
(return f30-0)
|
||||
)
|
||||
(let* ((f28-0 (- (-> arg2 x) (-> arg0 root trans x)))
|
||||
(f26-0 (- (-> arg2 z) (-> arg0 root trans z)))
|
||||
(f22-0 (+ (quaternion-y-angle (-> arg0 root quat)) (-> s4-0 angle)))
|
||||
(f24-0 (cos f22-0))
|
||||
(f1-3 (sin f22-0))
|
||||
(f0-4 (- (* f28-0 f24-0) (* f26-0 f1-3)))
|
||||
(f1-5 (+ (* f26-0 f24-0) (* f28-0 f1-3)))
|
||||
(f2-3 (/ 1.0 (-> s4-0 grid-size)))
|
||||
(f28-1 (* f2-3 (- f0-4 (-> s4-0 x-base))))
|
||||
(f26-1 (* f2-3 (- f1-5 (-> s4-0 z-base))))
|
||||
)
|
||||
(ripple-update-waveform-offs s5-0 (-> *display* bg-clock))
|
||||
(let* ((f22-1 (the float (the int f28-1)))
|
||||
(f24-1 (the float (the int f26-1)))
|
||||
(f20-0 (ripple-slow-add-sine-waves s5-0 f22-1 f24-1))
|
||||
)
|
||||
(set! sv-32 (ripple-slow-add-sine-waves s5-0 (+ 1.0 f22-1) f24-1))
|
||||
(set! sv-48 (ripple-slow-add-sine-waves s5-0 f22-1 (+ 1.0 f24-1)))
|
||||
(let* ((f1-6 (ripple-slow-add-sine-waves s5-0 (+ 1.0 f22-1) (+ 1.0 f24-1)))
|
||||
(f0-22 (+ f20-0 (* (- f28-1 f22-1) (- sv-32 f20-0))))
|
||||
(f1-9 (+ sv-48 (* (- f28-1 f22-1) (- f1-6 sv-48))))
|
||||
(f1-12 (+ f0-22 (* (- f26-1 f24-1) (- f1-9 f0-22))))
|
||||
(f0-23 (-> gp-0 faded-scale))
|
||||
)
|
||||
(if (< f0-23 0.0)
|
||||
(set! f0-23 (-> gp-0 global-scale))
|
||||
)
|
||||
(+ f30-0 (* 0.0078125 f1-12 f0-23))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -34,6 +34,10 @@
|
||||
(('pal)
|
||||
(set! (-> this time-factor) 6.0)
|
||||
)
|
||||
;; og:preserve-this custom mode for high fps
|
||||
(('custom)
|
||||
(set! (-> this time-factor) (/ 300.0 (-> *pc-settings* target-fps)))
|
||||
)
|
||||
(else
|
||||
(set! (-> this time-factor) 5.0)
|
||||
)
|
||||
|
||||
@@ -164,6 +164,7 @@
|
||||
(target-brightness float)
|
||||
(speed float)
|
||||
)
|
||||
:pack-me
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -1237,42 +1237,42 @@
|
||||
((zero? (-> this lightning-index))
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-b" :group 1)
|
||||
(static-sound-spec "thunder-b" :group 0)
|
||||
(new 'static 'vector :x 37109760.0 :y 16261120.0 :z 5857280.0)
|
||||
)
|
||||
)
|
||||
((= (-> this lightning-index) 1)
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-b" :group 1)
|
||||
(static-sound-spec "thunder-b" :group 0)
|
||||
(new 'static 'vector :x 20480000.0 :y 33341440.0 :z 12124160.0)
|
||||
)
|
||||
)
|
||||
((= (-> this lightning-index) 2)
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-b" :group 1)
|
||||
(static-sound-spec "thunder-b" :group 0)
|
||||
(new 'static 'vector :x -20480000.0 :y 33341440.0 :z 12124160.0)
|
||||
)
|
||||
)
|
||||
((= (-> this lightning-index) 3)
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-b" :group 1)
|
||||
(static-sound-spec "thunder-b" :group 0)
|
||||
(new 'static 'vector :x -37109760.0 :y 16261120.0 :z 5857280.0)
|
||||
)
|
||||
)
|
||||
((= (-> this lightning-index) 4)
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-c" :group 1)
|
||||
(static-sound-spec "thunder-c" :group 0)
|
||||
(new 'static 'vector :y 40960000.0)
|
||||
)
|
||||
)
|
||||
((= (-> this lightning-index) 5)
|
||||
(play-or-stop-lightning-sfx!
|
||||
this
|
||||
(static-sound-spec "thunder-a" :group 1)
|
||||
(static-sound-spec "thunder-a" :group 0)
|
||||
(new 'static 'vector :y 40960000.0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -317,7 +317,7 @@
|
||||
(near-off symbol)
|
||||
(mid-off symbol)
|
||||
(far-on symbol)
|
||||
(all-on basic)
|
||||
(all-on symbol)
|
||||
(ocean-facing uint32)
|
||||
(heights ocean-height-array)
|
||||
(heights2 ocean-height-array)
|
||||
@@ -413,84 +413,84 @@
|
||||
(get-height (_type_ vector symbol) float)
|
||||
(draw! (_type_) none)
|
||||
(update-map (_type_) none)
|
||||
(ocean-method-14 () none)
|
||||
(ocean-method-15 () none)
|
||||
(ocean-method-16 () none)
|
||||
(ocean-method-17 () none)
|
||||
(ocean-method-18 () none)
|
||||
(ocean-method-19 () none)
|
||||
(ocean-method-20 () none)
|
||||
(ocean-method-21 () none)
|
||||
(ocean-method-22 () none)
|
||||
(ocean-method-23 () none)
|
||||
(ocean-method-24 () none)
|
||||
(ocean-method-25 () none)
|
||||
(ocean-method-26 () none)
|
||||
(ocean-method-27 () none)
|
||||
(ocean-method-28 () none)
|
||||
(ocean-method-29 () none)
|
||||
(ocean-method-30 () none)
|
||||
(ocean-method-31 () none)
|
||||
(ocean-method-32 () none)
|
||||
(ocean-method-33 () none)
|
||||
(ocean-method-34 () none)
|
||||
(ocean-method-35 () none)
|
||||
(ocean-method-36 () none)
|
||||
(ocean-method-37 () none)
|
||||
(ocean-method-38 () none)
|
||||
(ocean-method-39 () none)
|
||||
(ocean-method-40 () none)
|
||||
(ocean-method-41 () none)
|
||||
(ocean-method-42 () none)
|
||||
(ocean-method-43 () none)
|
||||
(ocean-method-44 () none)
|
||||
(ocean-method-45 () none)
|
||||
(ocean-method-46 () none)
|
||||
(ocean-method-47 () none)
|
||||
(ocean-method-48 () none)
|
||||
(ocean-method-49 () none)
|
||||
(ocean-method-50 () none)
|
||||
(ocean-method-51 () none)
|
||||
(ocean-method-52 () none)
|
||||
(ocean-method-53 () none)
|
||||
(ocean-method-54 () none)
|
||||
(ocean-method-55 () none)
|
||||
(ocean-method-56 () none)
|
||||
(ocean-method-57 () none)
|
||||
(ocean-method-58 () none)
|
||||
(ocean-method-59 () none)
|
||||
(ocean-method-60 () none)
|
||||
(ocean-method-61 () none)
|
||||
(ocean-method-62 () none)
|
||||
(ocean-method-63 () none)
|
||||
(ocean-method-64 () none)
|
||||
(ocean-method-65 () none)
|
||||
(ocean-method-66 () none)
|
||||
(ocean-method-67 () none)
|
||||
(ocean-method-68 () none)
|
||||
(ocean-method-69 () none)
|
||||
(ocean-method-70 () none)
|
||||
(ocean-method-71 () none)
|
||||
(ocean-method-72 () none)
|
||||
(ocean-method-73 () none)
|
||||
(ocean-method-74 () none)
|
||||
(ocean-method-75 () none)
|
||||
(ocean-method-76 () none)
|
||||
(ocean-method-77 () none)
|
||||
(ocean-method-78 () none)
|
||||
(ocean-method-79 () none)
|
||||
(ocean-method-80 () none)
|
||||
(ocean-method-81 () none)
|
||||
(ocean-method-82 () none)
|
||||
(ocean-method-83 () none)
|
||||
(ocean-method-84 () none)
|
||||
(ocean-method-85 () none)
|
||||
(ocean-method-86 () none)
|
||||
(ocean-method-87 () none)
|
||||
(ocean-method-88 () none)
|
||||
(ocean-method-89 () none)
|
||||
(ocean-method-90 () none)
|
||||
(ocean-method-91 () none)
|
||||
(interp-wave (_type_ ocean-wave-info uint float) none)
|
||||
(ocean-method-15 (_type_ matrix matrix) none)
|
||||
(generate-verts (_type_ ocean-vert-array ocean-height-array) none)
|
||||
(add-colors! (_type_ vector ocean-vertex) none)
|
||||
(ocean-method-18 (_type_ (pointer ocean-colors) (pointer ocean-colors)) none)
|
||||
(init-buffer! (_type_ dma-buffer) none)
|
||||
(end-buffer! (_type_ dma-buffer) none)
|
||||
(set-corners! (_type_ float float) float)
|
||||
(ocean-near-add-call (_type_ dma-buffer int) none)
|
||||
(ocean-near-add-call-flush (_type_ dma-buffer int) none)
|
||||
(ocean-near-setup-constants (_type_ ocean-near-constants) none)
|
||||
(ocean-near-add-constants (_type_ dma-buffer) none)
|
||||
(ocean-near-add-heights (_type_ dma-buffer) none)
|
||||
(ocean-near-add-matrices (_type_ dma-buffer vector) none)
|
||||
(ocean-near-add-upload (_type_ dma-buffer uint uint) none)
|
||||
(draw-ocean-near (_type_ dma-buffer) none)
|
||||
(ocean-trans-camera-masks-bit? (_type_ uint uint) symbol)
|
||||
(ocean-trans-mask-ptrs-bit? (_type_ int int) symbol)
|
||||
(ocean-trans-mask-ptrs-set! (_type_ uint uint) symbol)
|
||||
(ocean-trans-add-upload-table (_type_ dma-buffer uint uint int int symbol) none)
|
||||
(ocean-trans-add-upload-strip (_type_ dma-buffer uint uint int int int) none)
|
||||
(ocean-transition-check (_type_ ocean-trans-mask int int vector) none)
|
||||
(ocean-make-trans-camera-masks (_type_ uint uint uint uint) none)
|
||||
(ocean-trans-add-upload (_type_ dma-buffer uint uint) none)
|
||||
(draw-ocean-transition-seams (_type_ dma-buffer) none)
|
||||
(ocean-trans-add-constants (_type_ dma-buffer) none)
|
||||
(draw-ocean-transition (_type_ dma-buffer) none)
|
||||
(ocean-mid-add-call (_type_ dma-buffer int) none)
|
||||
(ocean-mid-add-call-flush (_type_ dma-buffer uint) none)
|
||||
(ocean-matrix*! (_type_ matrix matrix matrix) matrix)
|
||||
(ocean-vector-matrix*! (_type_ vector vector matrix) vector)
|
||||
(ocean-mid-add-matrices (_type_ dma-buffer vector) none)
|
||||
(ocean-mid-check (_type_ pointer int int vector) symbol)
|
||||
(ocean-mid-setup-constants (_type_ ocean-mid-constants) none)
|
||||
(ocean-mid-add-constants (_type_ dma-buffer) none)
|
||||
(ocean-mid-camera-masks-bit? (_type_ uint uint) symbol)
|
||||
(ocean-mid-mask-ptrs-bit? (_type_ uint uint) symbol)
|
||||
(ocean-mid-camera-masks-set! (_type_ uint uint) symbol)
|
||||
(ocean-mid-add-upload (_type_ dma-buffer int int int int float) none)
|
||||
(ocean-mid-add-upload-table (_type_ dma-buffer uint uint (pointer float) int symbol) none)
|
||||
(ocean-mid-add-upload-top (_type_ dma-buffer uint uint) none)
|
||||
(ocean-mid-add-upload-middle (_type_ dma-buffer uint uint) none)
|
||||
(ocean-mid-add-upload-bottom (_type_ dma-buffer uint uint) none)
|
||||
(ocean-seams-add-constants (_type_ dma-buffer) none)
|
||||
(draw-ocean-mid-seams (_type_ dma-buffer) none)
|
||||
(draw-ocean-mid (_type_ dma-buffer) none)
|
||||
(ocean-method-60 (_type_ dma-buffer) none)
|
||||
(ocean-method-61 (_type_ dma-buffer) none)
|
||||
(ocean-method-62 (_type_ dma-buffer) none)
|
||||
(ocean-method-63 (_type_ dma-buffer) none)
|
||||
(ocean-method-64 (_type_ dma-buffer) none)
|
||||
(ocean-method-65 (_type_ dma-buffer) none)
|
||||
(ocean-method-66 (_type_ dma-buffer) none)
|
||||
(ocean-method-67 (_type_ dma-buffer) none)
|
||||
(render-ocean-far (_type_ dma-buffer int) none)
|
||||
(draw-ocean-far (_type_ dma-buffer) none)
|
||||
(ocean-texture-setup-constants (_type_ ocean-texture-constants) none)
|
||||
(ocean-texture-add-constants (_type_ dma-buffer) none)
|
||||
(ocean-texture-add-envmap (_type_ dma-buffer) none)
|
||||
(ocean-texture-add-verts (_type_ dma-buffer int) none)
|
||||
(ocean-texture-add-verts-last (_type_ dma-buffer int int) none)
|
||||
(ocean-texture-add-call-start (_type_ dma-buffer) none)
|
||||
(ocean-texture-add-call-rest (_type_ dma-buffer) none)
|
||||
(ocean-texture-add-call-done (_type_ dma-buffer) none)
|
||||
(draw-ocean-texture (_type_ dma-buffer int) none)
|
||||
(ocean-method-79 (_type_ (pointer rgba)) none)
|
||||
(ocean-method-80 (_type_ dma-buffer) none)
|
||||
(draw-envmap-debug (_type_ dma-buffer) none)
|
||||
(ocean-method-82 (_type_ dma-buffer float) int)
|
||||
(ocean-method-83 (_type_ dma-buffer sky-upload-data vector4w float) none)
|
||||
(ocean-method-84 (_type_ dma-buffer) none)
|
||||
(ocean-method-85 (_type_ vector vector vector vector) none)
|
||||
(ocean-method-86 (_type_ vector vector vector) none)
|
||||
(ocean-method-87 (_type_ dma-buffer) none)
|
||||
(ocean-method-88 (_type_ dma-buffer) none)
|
||||
(ocean-method-89 (_type_ dma-buffer) none)
|
||||
(rgba-to-vector! (_type_ vector (pointer int32)) none)
|
||||
(do-tex-scroll! (_type_) none)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -7,3 +7,700 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(define ocean-near-block (new 'static 'vu-function #|:length #x3dd :qlength #x1ef|#))
|
||||
|
||||
(defmethod ocean-near-add-call ((this ocean) (arg0 dma-buffer) (arg1 int))
|
||||
(let* ((v1-0 arg0)
|
||||
(a0-1 (the-as object (-> v1-0 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-1) dma) (new 'static 'dma-tag :id (dma-tag-id cnt)))
|
||||
(set! (-> (the-as dma-packet a0-1) vif0) (new 'static 'vif-tag :cmd (vif-cmd mscalf) :msk #x1 :imm arg1))
|
||||
(set! (-> (the-as dma-packet a0-1) vif1) (new 'static 'vif-tag :cmd (vif-cmd stmod)))
|
||||
(set! (-> v1-0 base) (&+ (the-as pointer a0-1) 16))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-near-add-call-flush ((this ocean) (arg0 dma-buffer) (arg1 int))
|
||||
(let* ((v1-0 arg0)
|
||||
(a0-1 (the-as object (-> v1-0 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-1) dma) (new 'static 'dma-tag :id (dma-tag-id cnt)))
|
||||
(set! (-> (the-as dma-packet a0-1) vif0) (new 'static 'vif-tag :cmd (vif-cmd mscalf) :msk #x1 :imm arg1))
|
||||
(set! (-> (the-as dma-packet a0-1) vif1) (new 'static 'vif-tag :cmd (vif-cmd flusha) :msk #x1))
|
||||
(set! (-> v1-0 base) (&+ (the-as pointer a0-1) 16))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-near-setup-constants ((this ocean) (arg0 ocean-near-constants))
|
||||
(let ((v1-0 *math-camera*))
|
||||
(set! (-> arg0 hmge-scale quad) (-> v1-0 hmge-scale quad))
|
||||
(set! (-> arg0 inv-hmge-scale quad) (-> v1-0 inv-hmge-scale quad))
|
||||
(set! (-> arg0 hvdf-offset quad) (-> v1-0 hvdf-off quad))
|
||||
(set-vector! (-> arg0 fog) (-> v1-0 pfog0) (-> v1-0 fog-min) (-> v1-0 fog-max) 3072.0)
|
||||
)
|
||||
(set-vector! (-> arg0 constants) -0.25 -0.5 0.0 0.000010172526)
|
||||
(let* ((s4-0 (-> (matrix-local->world #f #f) fvec))
|
||||
(f0-12 (- 1.5 (* 0.000015258789 (atan (-> s4-0 x) (-> s4-0 z)))))
|
||||
(f1-1 (+ 0.5 (* -0.5 (-> s4-0 y))))
|
||||
)
|
||||
(set-vector! (-> arg0 constants2) f0-12 f1-1 1.0 128.0)
|
||||
)
|
||||
(set-vector! (-> arg0 constants3) 12288.0 0.125 2.0 0.03125)
|
||||
(set-vector! (-> arg0 constants4) 2.0 255.0 3.0 0.0078125)
|
||||
(set-vector! (-> arg0 constants5) 0.5 0.0 0.0 0.000010172526)
|
||||
(case *subdivide-ocean-draw-mode*
|
||||
(((subdivide-setting textured))
|
||||
(set! (-> arg0 drw-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
)
|
||||
(((subdivide-setting outline))
|
||||
(set! (-> arg0 drw-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
)
|
||||
(((subdivide-setting gouraud))
|
||||
(set! (-> arg0 drw-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-strip) :iip #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
)
|
||||
(((subdivide-setting hack))
|
||||
(set! (-> arg0 drw-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-fan tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x4
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type tri-fan) :iip #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :fge #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-strip tag)
|
||||
(new 'static 'gif-tag64
|
||||
:nloop #x12
|
||||
:eop #x1
|
||||
:pre #x1
|
||||
:prim (new 'static 'gs-prim :prim (gs-prim-type line-strip) :iip #x1 :tme #x1 :abe #x1)
|
||||
:nreg #x3
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw-fan regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 drw2-fan regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 env-fan regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 drw-strip regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 env-strip regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 drw2-strip regs)
|
||||
(new 'static 'gif-tag-regs :regs0 (gif-reg-id st) :regs1 (gif-reg-id rgbaq) :regs2 (gif-reg-id xyzf2))
|
||||
)
|
||||
(set! (-> arg0 drw-adgif tag) (new 'static 'gif-tag64 :nloop #x5 :nreg #x1))
|
||||
(set! (-> arg0 drw-adgif regs) (new 'static 'gif-tag-regs :regs0 (gif-reg-id a+d)))
|
||||
(set! (-> arg0 drw-texture tex0) (new 'static 'gs-tex0 :tbp0 #x2a0 :tbw #x2 :th (log2 128) :tw (log2 128)))
|
||||
(set! (-> arg0 drw-texture prims 1) (gs-reg64 tex0-1))
|
||||
(set! (-> arg0 drw-texture tex1) (-> this tex1-near))
|
||||
(set! (-> arg0 drw-texture prims 3) (gs-reg64 tex1-1))
|
||||
(set! (-> arg0 drw-texture miptbp1) (new 'static 'gs-miptbp :tbp1 #x6a0 :tbw1 #x1 :tbp2 #x7a0 :tbp3 #x7e0))
|
||||
(set! (-> arg0 drw-texture prims 5) (gs-reg64 miptbp1-1))
|
||||
(set! (-> arg0 drw-texture clamp) (new 'static 'gs-clamp))
|
||||
(set! (-> arg0 drw-texture clamp-reg) (gs-reg64 clamp-1))
|
||||
(set! (-> arg0 drw-texture alpha) (new 'static 'gs-miptbp :tbp1 #x44))
|
||||
(set! (-> arg0 drw-texture prims 9) (gs-reg64 alpha-1))
|
||||
(set! (-> arg0 env-adgif tag) (new 'static 'gif-tag64 :nloop #x5 :nreg #x1))
|
||||
(set! (-> arg0 env-adgif regs) (new 'static 'gif-tag-regs :regs0 (gif-reg-id a+d)))
|
||||
(cond
|
||||
((-> *time-of-day-context* sky)
|
||||
(set! (-> arg0 env-texture tex0)
|
||||
(new 'static 'gs-tex0
|
||||
:tbw #x1
|
||||
:tcc #x1
|
||||
:th (log2 64)
|
||||
:tw (log2 64)
|
||||
:tbp0 (-> *ocean-envmap-texture-base* vram-block)
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 env-texture prims 1) (gs-reg64 tex0-1))
|
||||
(set! (-> arg0 env-texture tex1) (new 'static 'gs-tex1 :mmag #x1 :mmin #x5 :l #x1 :k #xeed))
|
||||
(set! (-> arg0 env-texture prims 3) (gs-reg64 tex1-1))
|
||||
(set! (-> arg0 env-texture miptbp1) (new 'static 'gs-miptbp))
|
||||
(set! (-> arg0 env-texture prims 5) (gs-reg64 miptbp1-1))
|
||||
(set! (-> arg0 env-texture clamp) (new 'static 'gs-clamp))
|
||||
(set! (-> arg0 env-texture clamp-reg) (gs-reg64 clamp-1))
|
||||
(set! (-> arg0 env-texture alpha) (new 'static 'gs-miptbp :tbp1 #x58))
|
||||
(set! (-> arg0 env-texture prims 9) (gs-reg64 alpha-1))
|
||||
)
|
||||
(else
|
||||
(let ((s4-2 (-> arg0 env-texture)))
|
||||
(adgif-shader<-texture-simple! s4-2 (get-texture environment-ocean environment-generic))
|
||||
)
|
||||
(set! (-> arg0 env-texture clamp) (new 'static 'gs-clamp))
|
||||
(set! (-> arg0 env-texture alpha) (new 'static 'gs-miptbp :tbp1 #x58))
|
||||
)
|
||||
)
|
||||
(let ((f0-28 (* 128.0 (-> *time-of-day-context* ocean-alpha))))
|
||||
(if (-> *time-of-day-context* sky)
|
||||
(set-vector! (-> arg0 env-color) f0-28 f0-28 f0-28 f0-28)
|
||||
(set-vector! (-> arg0 env-color) f0-28 f0-28 (* 0.5 f0-28) f0-28)
|
||||
)
|
||||
)
|
||||
(set! (-> arg0 drw2-adgif tag) (new 'static 'gif-tag64 :nloop #x2 :eop #x1 :nreg #x1))
|
||||
(set! (-> arg0 drw2-adgif regs) (new 'static 'gif-tag-regs :regs0 (gif-reg-id a+d)))
|
||||
(set! (-> arg0 drw2-tex0 dword 0)
|
||||
(logior (logior (the-as uint #x4000082a0) (shr (shl (log2 128) 60) 34)) (shr (shl (log2 128) 60) 30))
|
||||
)
|
||||
(set! (-> arg0 drw2-tex0 dword 1) (the-as uint 6))
|
||||
(set! (-> arg0 drw2-frame dword 0) (the-as uint #xffffff00080198))
|
||||
(set! (-> arg0 drw2-frame dword 1) (the-as uint 76))
|
||||
(set! (-> arg0 drw3-adgif tag) (new 'static 'gif-tag64 :nloop #x1 :eop #x1 :nreg #x1))
|
||||
(set! (-> arg0 drw3-adgif regs) (new 'static 'gif-tag-regs :regs0 (gif-reg-id a+d)))
|
||||
(set! (-> arg0 drw3-frame data) (the-as uint #x80198))
|
||||
(set! (-> arg0 drw3-frame cmds) (gs-reg64 frame-1))
|
||||
(set-vector! (-> arg0 index-table 0) 81 189 0 0)
|
||||
(set-vector! (-> arg0 index-table 1) 54 162 0 0)
|
||||
(set-vector! (-> arg0 index-table 2) 27 135 0 0)
|
||||
(set-vector! (-> arg0 index-table 3) 0 108 0 0)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch pointer vs none.
|
||||
(defmethod ocean-near-add-constants ((this ocean) (arg0 dma-buffer))
|
||||
(let* ((a2-0 37)
|
||||
(v1-0 arg0)
|
||||
(a1-1 (the-as object (-> v1-0 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a1-1) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a2-0))
|
||||
(set! (-> (the-as dma-packet a1-1) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a1-1) vif1)
|
||||
(new 'static 'vif-tag :imm #x3b7 :cmd (vif-cmd unpack-v4-32) :num a2-0)
|
||||
)
|
||||
(set! (-> v1-0 base) (&+ (the-as pointer a1-1) 16))
|
||||
)
|
||||
(ocean-near-setup-constants this (the-as ocean-near-constants (-> arg0 base)))
|
||||
(&+! (-> arg0 base) 592)
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-near-add-heights ((this ocean) (arg0 dma-buffer))
|
||||
(let ((v1-0 128)
|
||||
(a0-1 (-> this heights))
|
||||
)
|
||||
(let* ((a2-0 arg0)
|
||||
(a3-0 (the-as object (-> a2-0 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a3-0) dma)
|
||||
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int a0-1) :qwc v1-0)
|
||||
)
|
||||
(set! (-> (the-as dma-packet a3-0) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a3-0) vif1)
|
||||
(new 'static 'vif-tag :imm #x20 :cmd (vif-cmd unpack-v4-32) :num v1-0)
|
||||
)
|
||||
(set! (-> a2-0 base) (&+ (the-as pointer a3-0) 16))
|
||||
)
|
||||
(let ((a2-1 (the-as object (-> arg0 base))))
|
||||
(set! (-> (the-as dma-packet a2-1) dma)
|
||||
(new 'static 'dma-tag :id (dma-tag-id ref) :addr (the-as int (&-> a0-1 data 512)) :qwc v1-0)
|
||||
)
|
||||
(set! (-> (the-as dma-packet a2-1) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a2-1) vif1)
|
||||
(new 'static 'vif-tag :imm #xa0 :cmd (vif-cmd unpack-v4-32) :num v1-0)
|
||||
)
|
||||
(set! (-> arg0 base) (&+ (the-as pointer a2-1) 16))
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-near-add-matrices ((this ocean) (arg0 dma-buffer) (arg1 vector))
|
||||
(let ((s4-0 (new-stack-vector0)))
|
||||
(if (-> *time-of-day-context* use-camera-other)
|
||||
(-> *math-camera* camera-rot-other)
|
||||
(-> *math-camera* camera-rot)
|
||||
)
|
||||
(let* ((a1-1 8)
|
||||
(v1-6 arg0)
|
||||
(a0-1 (the-as object (-> v1-6 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-1) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a1-1))
|
||||
(set! (-> (the-as dma-packet a0-1) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-1) vif1)
|
||||
(new 'static 'vif-tag :imm #x8000 :cmd (vif-cmd unpack-v4-32) :num a1-1)
|
||||
)
|
||||
(set! (-> v1-6 base) (&+ (the-as pointer a0-1) 16))
|
||||
)
|
||||
(let ((s3-0 (the-as object (-> arg0 base))))
|
||||
(let* ((v1-7 (the-as matrix s3-0))
|
||||
(t0-2 (-> *math-camera* camera-rot))
|
||||
(a0-4 (-> t0-2 rvec quad))
|
||||
(a1-5 (-> t0-2 uvec quad))
|
||||
(a3-4 (-> t0-2 fvec quad))
|
||||
(t0-3 (-> t0-2 trans quad))
|
||||
)
|
||||
(set! (-> v1-7 rvec quad) a0-4)
|
||||
(set! (-> v1-7 uvec quad) a1-5)
|
||||
(set! (-> v1-7 fvec quad) a3-4)
|
||||
(set! (-> v1-7 trans quad) t0-3)
|
||||
)
|
||||
(let ((s2-0 (the-as object (&+ (the-as pointer s3-0) 48))))
|
||||
(vector-matrix*! s4-0 arg1 (-> *math-camera* camera-rot))
|
||||
(set! (-> (the-as vector s2-0) x) (-> s4-0 x))
|
||||
(set! (-> (the-as vector s2-0) y) (-> s4-0 y))
|
||||
(set! (-> (the-as vector s2-0) z) (-> s4-0 z))
|
||||
)
|
||||
(let ((a1-7 (&+ (-> arg0 base) 64)))
|
||||
(ocean-matrix*! this (the-as matrix a1-7) (the-as matrix s3-0) (-> *math-camera* perspective))
|
||||
)
|
||||
)
|
||||
)
|
||||
(&+! (-> arg0 base) 128)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-near-add-upload ((this ocean) (arg0 dma-buffer) (arg1 uint) (arg2 uint))
|
||||
(local-vars
|
||||
(v1-17 uint128)
|
||||
(v1-18 uint128)
|
||||
(v1-19 float)
|
||||
(a0-18 uint128)
|
||||
(a0-19 uint128)
|
||||
(a0-20 uint128)
|
||||
(a2-23 float)
|
||||
(a2-30 uint128)
|
||||
(a2-31 uint128)
|
||||
(a3-25 uint128)
|
||||
)
|
||||
(rlet ((acc :class vf)
|
||||
(vf1 :class vf)
|
||||
(vf10 :class vf)
|
||||
(vf11 :class vf)
|
||||
(vf12 :class vf)
|
||||
(vf2 :class vf)
|
||||
(vf3 :class vf)
|
||||
(vf4 :class vf)
|
||||
(vf5 :class vf)
|
||||
(vf6 :class vf)
|
||||
(vf7 :class vf)
|
||||
(vf8 :class vf)
|
||||
(vf9 :class vf)
|
||||
)
|
||||
(let ((s1-0 (-> this mid-minx))
|
||||
(s2-0 (-> this mid-minz))
|
||||
)
|
||||
(let ((a2-1 (new-stack-vector0)))
|
||||
(let ((v1-0 (-> this start-corner)))
|
||||
(set! (-> a2-1 x) (+ (-> v1-0 x) (* 98304.0 (the float arg2))))
|
||||
(set! (-> a2-1 y) (-> v1-0 y))
|
||||
(set! (-> a2-1 z) (+ (-> v1-0 z) (* 98304.0 (the float arg1))))
|
||||
)
|
||||
(set! (-> a2-1 w) 1.0)
|
||||
(ocean-near-add-matrices this arg0 a2-1)
|
||||
)
|
||||
(let* ((a1-2 8)
|
||||
(v1-5 arg0)
|
||||
(a0-3 (the-as object (-> v1-5 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-3) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a1-2))
|
||||
(set! (-> (the-as dma-packet a0-3) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-3) vif1)
|
||||
(new 'static 'vif-tag :imm #x8008 :cmd (vif-cmd unpack-v4-32) :num a1-2)
|
||||
)
|
||||
(set! (-> v1-5 base) (&+ (the-as pointer a0-3) 16))
|
||||
)
|
||||
(let* ((v1-6 (-> arg0 base))
|
||||
(a0-6 (- arg2 (* s1-0 4)))
|
||||
(a1-7 (- arg1 (* s2-0 4)))
|
||||
(a2-6 (shr a0-6 2))
|
||||
(a3-3 (shr a1-7 2))
|
||||
(a0-7 (logand a0-6 3))
|
||||
(a1-8 (logand a1-7 3))
|
||||
(a2-10 (-> (the-as (pointer int16) (+ (* (+ (* a3-3 4) a2-6) 2) (the-as uint this))) 4002))
|
||||
(a3-7 (-> this ocean-near-indices data a2-10))
|
||||
(a0-13
|
||||
(-> this ocean-mid-masks data (-> (the-as (pointer int16) (+ (* (+ (* a1-8 4) a0-7) 2) (the-as uint a3-7)))))
|
||||
)
|
||||
)
|
||||
(set-vector!
|
||||
(the-as vector4w (&+ v1-6 0))
|
||||
(the-as int (-> a0-13 mask 0))
|
||||
(the-as int (-> a0-13 mask 1))
|
||||
(the-as int (-> a0-13 mask 2))
|
||||
(the-as int (-> a0-13 mask 3))
|
||||
)
|
||||
(set-vector!
|
||||
(the-as vector4w (&+ v1-6 16))
|
||||
(the-as int (-> a0-13 mask 4))
|
||||
(the-as int (-> a0-13 mask 5))
|
||||
(the-as int (-> a0-13 mask 6))
|
||||
(the-as int (-> a0-13 mask 7))
|
||||
)
|
||||
)
|
||||
)
|
||||
(&+! (-> arg0 base) 32)
|
||||
(let ((a0-15 (/ (the-as int arg2) 4))
|
||||
(v1-10 (/ (the-as int arg1) 4))
|
||||
(a2-18 (logand arg2 3))
|
||||
(a3-8 (logand arg1 3))
|
||||
)
|
||||
(let ((t0-0 (-> arg0 base))
|
||||
(a1-15 (logand (+ arg2 1) 3))
|
||||
(t1-1 (logand (+ arg1 1) 3))
|
||||
)
|
||||
(set-vector!
|
||||
(the-as vector4w (&+ t0-0 0))
|
||||
(the-as int (+ (* a3-8 64) (* a2-18 2)))
|
||||
(the-as int (+ (* a3-8 64) (* a1-15 2)))
|
||||
(the-as int (+ (* t1-1 64) (* a2-18 2)))
|
||||
(the-as int (+ (* t1-1 64) (* a1-15 2)))
|
||||
)
|
||||
)
|
||||
(&+! (-> arg0 base) 16)
|
||||
(let ((a1-21 (the-as (inline-array vector4w) (-> (the-as (inline-array vector4w) (-> arg0 base)) 0))))
|
||||
(set! (-> a1-21 0 x) (the-as int (* 0.25 (the float a2-18))))
|
||||
(set! (-> a1-21 0 y) (the-as int (* 0.25 (the float a3-8))))
|
||||
(set! (-> a1-21 0 z) (the-as int 1.0))
|
||||
(set! (-> a1-21 0 w) (the-as int 0.0))
|
||||
)
|
||||
(set! (-> arg0 base)
|
||||
(the-as pointer (the-as (inline-array vector4w) (-> (the-as (inline-array vector4w) (-> arg0 base)) 1)))
|
||||
)
|
||||
(let ((a1-24 (the-as (inline-array vector4w) (-> arg0 base))))
|
||||
(let ((a2-19 (+ (* 5 (the-as int a3-8)) a2-18)))
|
||||
(.lvf vf5 (&-> (-> *ocean-trans-corner-table* 0 vector a2-19) quad))
|
||||
(.lvf vf6 (&-> (-> *ocean-trans-corner-table* 0 vector (+ a2-19 1)) quad))
|
||||
(.lvf vf7 (&-> (-> *ocean-trans-corner-table* 0 vector (+ a2-19 5)) quad))
|
||||
(.lvf vf8 (&-> (-> *ocean-trans-corner-table* 0 vector (+ a2-19 6)) quad))
|
||||
)
|
||||
(.mov a2-23 vf8)
|
||||
(let ((a2-29 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int v1-10)) a0-15))))
|
||||
(a3-24 (the-as uint128 (-> this ocean-colors colors (+ a0-15 1 (* 52 (the-as int v1-10))))))
|
||||
(t0-17 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int (+ v1-10 1))) a0-15))))
|
||||
(v1-16 (the-as uint128 (-> this ocean-colors colors (+ a0-15 1 (* 52 (the-as int (+ v1-10 1)))))))
|
||||
)
|
||||
(.pextlb a0-18 0 a2-29)
|
||||
(nop!)
|
||||
(.pextlb a2-30 0 a3-24)
|
||||
(nop!)
|
||||
(.pextlb a3-25 0 t0-17)
|
||||
(nop!)
|
||||
(.pextlb v1-17 0 v1-16)
|
||||
)
|
||||
(nop!)
|
||||
(.pextlh a0-19 0 a0-18)
|
||||
(nop!)
|
||||
(.pextlh a2-31 0 a2-30)
|
||||
(.mov vf1 a0-19)
|
||||
(.pextlh a0-20 0 a3-25)
|
||||
(.mov vf2 a2-31)
|
||||
(.pextlh v1-18 0 v1-17)
|
||||
(.mov vf3 a0-20)
|
||||
(nop!)
|
||||
(.mov vf4 v1-18)
|
||||
(.itof.vf vf1 vf1)
|
||||
(nop!)
|
||||
(.itof.vf vf2 vf2)
|
||||
(nop!)
|
||||
(.itof.vf vf3 vf3)
|
||||
(nop!)
|
||||
(.itof.vf vf4 vf4)
|
||||
(nop!)
|
||||
(.mul.x.vf acc vf1 vf5)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf9 vf4 vf5 acc)
|
||||
(nop!)
|
||||
(.mul.x.vf acc vf1 vf6)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf10 vf4 vf6 acc)
|
||||
(.svf (&-> a1-24 0 quad) vf9)
|
||||
(.mul.x.vf acc vf1 vf7)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf11 vf4 vf7 acc)
|
||||
(.svf (&-> a1-24 1 quad) vf10)
|
||||
(.mul.x.vf acc vf1 vf8)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf12 vf4 vf8 acc)
|
||||
(.svf (&-> a1-24 2 quad) vf11)
|
||||
(nop!)
|
||||
(.svf (&-> a1-24 3 quad) vf12)
|
||||
)
|
||||
)
|
||||
(.mov v1-19 vf12)
|
||||
(&+! (-> arg0 base) 64)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod draw-ocean-near ((this ocean) (arg0 dma-buffer))
|
||||
(local-vars (sv-16 uint))
|
||||
(dma-buffer-add-gs-set arg0
|
||||
(test-1 (new 'static 'gs-test :ate #x1 :afail #x1 :zte #x1 :ztst (gs-ztest greater-equal)))
|
||||
)
|
||||
(dma-buffer-add-vu-function arg0 ocean-near-block 1)
|
||||
(let* ((v1-3 arg0)
|
||||
(a0-8 (the-as object (-> v1-3 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-8) dma) (new 'static 'dma-tag :id (dma-tag-id cnt)))
|
||||
(set! (-> (the-as dma-packet a0-8) vif0) (new 'static 'vif-tag :cmd (vif-cmd base)))
|
||||
(set! (-> (the-as dma-packet a0-8) vif1) (new 'static 'vif-tag :imm #x10 :cmd (vif-cmd offset)))
|
||||
(set! (-> v1-3 base) (&+ (the-as pointer a0-8) 16))
|
||||
)
|
||||
(ocean-near-add-constants this arg0)
|
||||
(ocean-near-add-heights this arg0)
|
||||
(ocean-near-add-call this arg0 0)
|
||||
(let ((s4-0 (-> this near-minx))
|
||||
(s3-0 (-> this near-maxx))
|
||||
(s2-0 (-> this near-minz))
|
||||
(s1-0 (-> this near-maxz))
|
||||
)
|
||||
(when (and (< s4-0 s3-0) (< s2-0 s1-0))
|
||||
(while (>= s1-0 s2-0)
|
||||
(let ((s0-0 s4-0))
|
||||
(set! sv-16 s3-0)
|
||||
(while (>= sv-16 s0-0)
|
||||
(when (ocean-trans-camera-masks-bit? this s2-0 s0-0)
|
||||
(let* ((a1-16 (- (shr s0-0 2) (-> this mid-minx)))
|
||||
(a2-3 (- (shr s2-0 2) (-> this mid-minz)))
|
||||
(v1-13 (logand s0-0 3))
|
||||
(a0-17 (logand s2-0 3))
|
||||
(a1-20 (-> (the-as (pointer int16) (+ (* (+ (* a2-3 4) a1-16) 2) (the-as uint this))) 4002))
|
||||
)
|
||||
(when (>= a1-20 0)
|
||||
(let ((a1-22 (-> this ocean-near-indices data a1-20)))
|
||||
(when (>= (-> (the-as (pointer int16) (+ (* (+ (* a0-17 4) v1-13) 2) (the-as uint a1-22)))) 0)
|
||||
(ocean-near-add-upload this arg0 s2-0 s0-0)
|
||||
(ocean-near-add-call this arg0 39)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! s0-0 1)
|
||||
)
|
||||
)
|
||||
(+! s2-0 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -7,3 +7,846 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(defmethod ocean-trans-camera-masks-bit? ((this ocean) (arg0 uint) (arg1 uint))
|
||||
(let ((v1-2 (- arg0 (* (-> this mid-minz) 4)))
|
||||
(a1-3 (- arg1 (* (-> this mid-minx) 4)))
|
||||
)
|
||||
(cond
|
||||
((or (< v1-2 0) (>= v1-2 (the-as uint 16)) (< a1-3 0) (>= a1-3 (the-as uint 16)))
|
||||
#f
|
||||
)
|
||||
(else
|
||||
(let* ((t0-0 (shr v1-2 2))
|
||||
(a3-3 (shr a1-3 2))
|
||||
(a2-2 (logand v1-2 3))
|
||||
(v1-3 (the-as int (logand a1-3 3)))
|
||||
(a1-5 (+ (* t0-0 4) a3-3))
|
||||
)
|
||||
(logtest? (-> (the-as (pointer uint8) (+ (+ a2-2 (* a1-5 4)) (the-as uint this))) 2928) (ash 1 v1-3))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-mask-ptrs-bit? ((this ocean) (arg0 int) (arg1 int))
|
||||
(let ((v1-2 (- arg0 (the-as int (* (-> this mid-minz) 4))))
|
||||
(a1-3 (- arg1 (the-as int (* (-> this mid-minx) 4))))
|
||||
)
|
||||
(cond
|
||||
((or (< (the-as uint v1-2) 0)
|
||||
(>= (the-as uint v1-2) (the-as uint 16))
|
||||
(< (the-as uint a1-3) 0)
|
||||
(>= (the-as uint a1-3) (the-as uint 16))
|
||||
)
|
||||
#f
|
||||
)
|
||||
(else
|
||||
(let* ((t0-0 (shr v1-2 2))
|
||||
(a3-3 (shr a1-3 2))
|
||||
(a2-2 (logand v1-2 3))
|
||||
(v1-3 (logand a1-3 3))
|
||||
(a0-2 (-> this trans-mask-ptrs (+ (* (+ (* t0-0 4) a3-3) 4) a2-2)))
|
||||
)
|
||||
(if a0-2
|
||||
(logtest? (-> (the-as (pointer int32) a0-2) 1) (ash 1 v1-3))
|
||||
#f
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-mask-ptrs-set! ((this ocean) (arg0 uint) (arg1 uint))
|
||||
(let ((v1-2 (- arg0 (* (-> this mid-minz) 4)))
|
||||
(a1-3 (- arg1 (* (-> this mid-minx) 4)))
|
||||
)
|
||||
(cond
|
||||
((or (< v1-2 0) (>= v1-2 (the-as uint 16)) (< a1-3 0) (>= a1-3 (the-as uint 16)))
|
||||
#f
|
||||
)
|
||||
(else
|
||||
(let* ((a3-3 (shr v1-2 2))
|
||||
(a2-2 (shr a1-3 2))
|
||||
(v1-3 (logand v1-2 3))
|
||||
(a1-4 (the-as int (logand a1-3 3)))
|
||||
(t0-6 (-> this trans-mask-ptrs (+ (* (+ (* a3-3 4) a2-2) 4) v1-3)))
|
||||
)
|
||||
(cond
|
||||
(t0-6
|
||||
(cond
|
||||
((logtest? (-> (the-as (pointer int32) t0-6) 1) (ash 1 a1-4))
|
||||
#f
|
||||
)
|
||||
(else
|
||||
(let ((a0-1 (&-> this trans-temp-masks (+ (* a3-3 4) a2-2))))
|
||||
(set! (-> (the-as (pointer int8) (+ v1-3 (the-as uint a0-1))) 0)
|
||||
(the-as int (logior (-> (the-as (pointer uint8) (+ v1-3 (the-as uint a0-1))) 0) (ash 1 a1-4)))
|
||||
)
|
||||
)
|
||||
#t
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
#f
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-add-upload-table ((this ocean) (arg0 dma-buffer) (arg1 uint) (arg2 uint) (arg3 int) (arg4 int) (arg5 symbol))
|
||||
(local-vars
|
||||
(v1-16 (inline-array vector4w))
|
||||
(v1-18 float)
|
||||
(a0-24 uint128)
|
||||
(a0-25 uint128)
|
||||
(a1-14 uint128)
|
||||
(a1-15 uint128)
|
||||
(a1-16 uint128)
|
||||
(a2-17 uint128)
|
||||
(a2-18 uint128)
|
||||
(a3-9 uint128)
|
||||
)
|
||||
(rlet ((acc :class vf)
|
||||
(vf1 :class vf)
|
||||
(vf10 :class vf)
|
||||
(vf11 :class vf)
|
||||
(vf12 :class vf)
|
||||
(vf2 :class vf)
|
||||
(vf3 :class vf)
|
||||
(vf4 :class vf)
|
||||
(vf5 :class vf)
|
||||
(vf6 :class vf)
|
||||
(vf7 :class vf)
|
||||
(vf8 :class vf)
|
||||
(vf9 :class vf)
|
||||
)
|
||||
(when (ocean-trans-mask-ptrs-set! this arg1 arg2)
|
||||
(let ((a2-2 (new-stack-vector0)))
|
||||
(let ((v1-2 (-> this start-corner)))
|
||||
(set! (-> a2-2 x) (+ (-> v1-2 x) (* 98304.0 (the float arg2))))
|
||||
(set! (-> a2-2 y) (-> v1-2 y))
|
||||
(set! (-> a2-2 z) (+ (-> v1-2 z) (* 98304.0 (the float arg1))))
|
||||
)
|
||||
(set! (-> a2-2 w) 1.0)
|
||||
(ocean-mid-add-matrices this arg0 a2-2)
|
||||
)
|
||||
(let* ((a1-3 9)
|
||||
(v1-7 arg0)
|
||||
(a0-4 (the-as object (-> v1-7 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-4) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a1-3))
|
||||
(set! (-> (the-as dma-packet a0-4) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-4) vif1)
|
||||
(new 'static 'vif-tag :imm #x8008 :cmd (vif-cmd unpack-v4-32) :num a1-3)
|
||||
)
|
||||
(set! (-> v1-7 base) (&+ (the-as pointer a0-4) 16))
|
||||
)
|
||||
(set-vector! (the-as vector4w (-> arg0 base)) arg4 0 0 0)
|
||||
(&+! (-> arg0 base) 16)
|
||||
(let* ((a0-6 (logand arg1 3))
|
||||
(v1-11 (logand arg2 3))
|
||||
(v1-12 (+ (* 5 (the-as int a0-6)) v1-11))
|
||||
)
|
||||
(.lvf vf5 (&-> (-> *ocean-trans-corner-table* 0 vector v1-12) quad))
|
||||
(.lvf vf6 (&-> (-> *ocean-trans-corner-table* 0 vector (+ v1-12 1)) quad))
|
||||
(.lvf vf7 (&-> (-> *ocean-trans-corner-table* 0 vector (+ v1-12 5)) quad))
|
||||
(.lvf vf8 (&-> (the-as (inline-array vector4w) (-> *ocean-trans-corner-table* 0 vector (+ v1-12 6))) 0 quad))
|
||||
)
|
||||
(.mov v1-16 vf8)
|
||||
(let ((v1-17 (the-as (inline-array vector4w) (-> arg0 base))))
|
||||
(let ((a0-17 (/ (the-as int arg1) 4))
|
||||
(a1-11 (/ (the-as int arg2) 4))
|
||||
)
|
||||
(.lvf vf1 (&-> *ocean-trans-st-table* 0 quad))
|
||||
(.lvf vf2 (&-> *ocean-trans-st-table* 1 quad))
|
||||
(.lvf vf3 (&-> *ocean-trans-st-table* 2 quad))
|
||||
(.lvf vf4 (&-> *ocean-trans-st-table* 3 quad))
|
||||
(.mul.x.vf acc vf1 vf5)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf9 vf4 vf5 acc)
|
||||
(nop!)
|
||||
(.mul.x.vf acc vf1 vf6)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf10 vf4 vf6 acc)
|
||||
(.svf (&-> v1-17 0 quad) vf9)
|
||||
(.mul.x.vf acc vf1 vf7)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf11 vf4 vf7 acc)
|
||||
(.svf (&-> v1-17 1 quad) vf10)
|
||||
(.mul.x.vf acc vf1 vf8)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf12 vf4 vf8 acc)
|
||||
(.svf (&-> v1-17 2 quad) vf11)
|
||||
(nop!)
|
||||
(.svf (&-> v1-17 3 quad) vf12)
|
||||
(let ((a2-16 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int a0-17)) a1-11))))
|
||||
(a3-8 (the-as uint128 (-> this ocean-colors colors (+ a1-11 1 (* 52 (the-as int a0-17))))))
|
||||
(t0-9 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int (+ a0-17 1))) a1-11))))
|
||||
(a0-23 (the-as uint128 (-> this ocean-colors colors (+ a1-11 1 (* 52 (the-as int (+ a0-17 1)))))))
|
||||
)
|
||||
(.pextlb a1-14 0 a2-16)
|
||||
(nop!)
|
||||
(.pextlb a2-17 0 a3-8)
|
||||
(nop!)
|
||||
(.pextlb a3-9 0 t0-9)
|
||||
(nop!)
|
||||
(.pextlb a0-24 0 a0-23)
|
||||
)
|
||||
)
|
||||
(nop!)
|
||||
(.pextlh a1-15 0 a1-14)
|
||||
(nop!)
|
||||
(.pextlh a2-18 0 a2-17)
|
||||
(.mov vf1 a1-15)
|
||||
(.pextlh a1-16 0 a3-9)
|
||||
(.mov vf2 a2-18)
|
||||
(.pextlh a0-25 0 a0-24)
|
||||
(.mov vf3 a1-16)
|
||||
(nop!)
|
||||
(.mov vf4 a0-25)
|
||||
(.itof.vf vf1 vf1)
|
||||
(nop!)
|
||||
(.itof.vf vf2 vf2)
|
||||
(nop!)
|
||||
(.itof.vf vf3 vf3)
|
||||
(nop!)
|
||||
(.itof.vf vf4 vf4)
|
||||
(nop!)
|
||||
(.mul.x.vf acc vf1 vf5)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf5 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf9 vf4 vf5 acc)
|
||||
(nop!)
|
||||
(.mul.x.vf acc vf1 vf6)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf6 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf10 vf4 vf6 acc)
|
||||
(.svf (&-> v1-17 4 quad) vf9)
|
||||
(.mul.x.vf acc vf1 vf7)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf7 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf11 vf4 vf7 acc)
|
||||
(.svf (&-> v1-17 5 quad) vf10)
|
||||
(.mul.x.vf acc vf1 vf8)
|
||||
(nop!)
|
||||
(.add.mul.y.vf acc vf2 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.z.vf acc vf3 vf8 acc)
|
||||
(nop!)
|
||||
(.add.mul.w.vf vf12 vf4 vf8 acc)
|
||||
(.svf (&-> v1-17 6 quad) vf11)
|
||||
(nop!)
|
||||
(.svf (&-> v1-17 7 quad) vf12)
|
||||
)
|
||||
(.mov v1-18 vf12)
|
||||
(&+! (-> arg0 base) 128)
|
||||
(let* ((v1-21 arg0)
|
||||
(a0-26 (the-as object (-> v1-21 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-26) dma) (new 'static 'dma-tag :id (dma-tag-id ref) :addr arg3 :qwc arg4))
|
||||
(set! (-> (the-as dma-packet a0-26) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-26) vif1)
|
||||
(new 'static 'vif-tag :imm #x8011 :cmd (vif-cmd unpack-v4-32) :num arg4)
|
||||
)
|
||||
(set! (-> v1-21 base) (&+ (the-as pointer a0-26) 16))
|
||||
)
|
||||
(if arg5
|
||||
(ocean-mid-add-call this arg0 275)
|
||||
(ocean-mid-add-call this arg0 107)
|
||||
)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-add-upload-strip ((this ocean) (arg0 dma-buffer) (arg1 uint) (arg2 uint) (arg3 int) (arg4 int) (arg5 int))
|
||||
(local-vars
|
||||
(v1-10 float)
|
||||
(a0-24 uint128)
|
||||
(a0-25 uint128)
|
||||
(a0-26 uint128)
|
||||
(a1-12 uint128)
|
||||
(a1-13 uint128)
|
||||
(a1-14 uint128)
|
||||
(a2-15 uint128)
|
||||
(a3-10 uint128)
|
||||
)
|
||||
(rlet ((vf1 :class vf)
|
||||
(vf2 :class vf)
|
||||
(vf3 :class vf)
|
||||
(vf4 :class vf)
|
||||
)
|
||||
(let ((a2-1 (new-stack-vector0)))
|
||||
(let ((v1-0 (-> this start-corner)))
|
||||
(set! (-> a2-1 x) (+ (-> v1-0 x) (* 393216.0 (the float arg2))))
|
||||
(set! (-> a2-1 y) (-> v1-0 y))
|
||||
(set! (-> a2-1 z) (+ (-> v1-0 z) (* 393216.0 (the float arg1))))
|
||||
)
|
||||
(set! (-> a2-1 w) 1.0)
|
||||
(ocean-mid-add-matrices this arg0 a2-1)
|
||||
)
|
||||
(let* ((a1-2 9)
|
||||
(v1-5 arg0)
|
||||
(a0-3 (the-as object (-> v1-5 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-3) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a1-2))
|
||||
(set! (-> (the-as dma-packet a0-3) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-3) vif1)
|
||||
(new 'static 'vif-tag :imm #x8008 :cmd (vif-cmd unpack-v4-32) :num a1-2)
|
||||
)
|
||||
(set! (-> v1-5 base) (&+ (the-as pointer a0-3) 16))
|
||||
)
|
||||
(let ((v1-6 (the-as object (-> arg0 base))))
|
||||
(set! (-> this trans-mask-ptrs (+ (* arg4 4) arg5)) (the-as pointer v1-6))
|
||||
(set! (-> (the-as vector4w v1-6) x) 10)
|
||||
(set! (-> (the-as vector4w v1-6) y) arg3)
|
||||
(set! (-> (the-as vector4w v1-6) z) 0)
|
||||
(set! (-> (the-as vector4w v1-6) w) 0)
|
||||
)
|
||||
(&+! (-> arg0 base) 16)
|
||||
(let ((v1-9 (the-as (inline-array vector4w) (-> arg0 base))))
|
||||
(set! (-> v1-9 0 quad) (-> *ocean-trans-st-table* 0 quad))
|
||||
(set! (-> v1-9 1 quad) (-> *ocean-trans-st-table* 1 quad))
|
||||
(set! (-> v1-9 2 quad) (-> *ocean-trans-st-table* 2 quad))
|
||||
(set! (-> v1-9 3 quad) (-> *ocean-trans-st-table* 3 quad))
|
||||
(let ((a0-23 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int arg1)) arg2))))
|
||||
(a1-11 (the-as uint128 (-> this ocean-colors colors (+ arg2 1 (* 52 (the-as int arg1))))))
|
||||
(a2-14 (the-as uint128 (-> this ocean-colors colors (+ (* 52 (the-as int (+ arg1 1))) arg2))))
|
||||
(a3-9 (the-as uint128 (-> this ocean-colors colors (+ arg2 1 (* 52 (the-as int (+ arg1 1)))))))
|
||||
)
|
||||
(.pextlb a0-24 0 a0-23)
|
||||
(nop!)
|
||||
(.pextlb a1-12 0 a1-11)
|
||||
(nop!)
|
||||
(.pextlb a2-15 0 a2-14)
|
||||
(nop!)
|
||||
(.pextlb a3-10 0 a3-9)
|
||||
)
|
||||
(nop!)
|
||||
(.pextlh a0-25 0 a0-24)
|
||||
(nop!)
|
||||
(.pextlh a1-13 0 a1-12)
|
||||
(.mov vf1 a0-25)
|
||||
(.pextlh a0-26 0 a2-15)
|
||||
(.mov vf2 a1-13)
|
||||
(.pextlh a1-14 0 a3-10)
|
||||
(.mov vf3 a0-26)
|
||||
(nop!)
|
||||
(.mov vf4 a1-14)
|
||||
(.itof.vf vf1 vf1)
|
||||
(nop!)
|
||||
(.itof.vf vf2 vf2)
|
||||
(nop!)
|
||||
(.itof.vf vf3 vf3)
|
||||
(nop!)
|
||||
(.itof.vf vf4 vf4)
|
||||
(nop!)
|
||||
(nop!)
|
||||
(.svf (&-> v1-9 4 quad) vf1)
|
||||
(nop!)
|
||||
(.svf (&-> v1-9 5 quad) vf2)
|
||||
(nop!)
|
||||
(.svf (&-> v1-9 6 quad) vf3)
|
||||
(nop!)
|
||||
(.svf (&-> v1-9 7 quad) vf4)
|
||||
)
|
||||
(.mov v1-10 vf4)
|
||||
(&+! (-> arg0 base) 128)
|
||||
(let* ((a1-15 10)
|
||||
(v1-13 arg0)
|
||||
(a0-27 (the-as object (-> v1-13 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-27) dma)
|
||||
(new 'static 'dma-tag
|
||||
:id (dma-tag-id ref)
|
||||
:addr (the-as int (+ (+ (* 160 arg5) 0) (the-as int *ocean-trans-strip-array*)))
|
||||
:qwc a1-15
|
||||
)
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-27) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-27) vif1)
|
||||
(new 'static 'vif-tag :imm #x8011 :cmd (vif-cmd unpack-v4-32) :num a1-15)
|
||||
)
|
||||
(set! (-> v1-13 base) (&+ (the-as pointer a0-27) 16))
|
||||
)
|
||||
(ocean-mid-add-call this arg0 107)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-transition-check ((this ocean) (arg0 ocean-trans-mask) (arg1 int) (arg2 int) (arg3 vector))
|
||||
(local-vars (v1-13 float) (t0-3 float) (t0-8 float) (t0-13 float))
|
||||
(rlet ((vf1 :class vf)
|
||||
(vf2 :class vf)
|
||||
(vf3 :class vf)
|
||||
)
|
||||
(let ((v1-0 (new-stack-vector0))
|
||||
(a0-2 (-> *math-camera* trans))
|
||||
)
|
||||
1.0
|
||||
(set! (-> v1-0 x) (+ (-> arg3 x) (* 98304.0 (the float arg1))))
|
||||
(set! (-> v1-0 y) (-> arg3 y))
|
||||
(set! (-> v1-0 z) (+ (-> arg3 z) (* 98304.0 (the float arg2))))
|
||||
(let ((t0-2 v1-0)
|
||||
(t1-2 a0-2)
|
||||
)
|
||||
(.lvf vf2 (&-> t0-2 quad))
|
||||
(.lvf vf3 (&-> t1-2 quad))
|
||||
)
|
||||
(.sub.vf vf1 vf3 vf2)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.add.y.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.add.z.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.mov t0-3 vf1)
|
||||
(when (< t0-3 19327350000.0)
|
||||
(logior! (-> arg0 mask arg2) (ash 1 arg1))
|
||||
(goto cfg-24)
|
||||
)
|
||||
(+! (-> v1-0 x) 98304.0)
|
||||
(let ((t0-7 v1-0)
|
||||
(t1-3 a0-2)
|
||||
)
|
||||
(.lvf vf2 (&-> t0-7 quad))
|
||||
(.lvf vf3 (&-> t1-3 quad))
|
||||
)
|
||||
(.sub.vf vf1 vf3 vf2)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.add.y.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.add.z.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.mov t0-8 vf1)
|
||||
(when (< t0-8 19327350000.0)
|
||||
(logior! (-> arg0 mask arg2) (ash 1 arg1))
|
||||
(goto cfg-24)
|
||||
)
|
||||
(+! (-> v1-0 z) 98304.0)
|
||||
(let ((t0-12 v1-0)
|
||||
(t1-4 a0-2)
|
||||
)
|
||||
(.lvf vf2 (&-> t0-12 quad))
|
||||
(.lvf vf3 (&-> t1-4 quad))
|
||||
)
|
||||
(.sub.vf vf1 vf3 vf2)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.add.y.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.add.z.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.mov t0-13 vf1)
|
||||
(when (< t0-13 19327350000.0)
|
||||
(logior! (-> arg0 mask arg2) (ash 1 arg1))
|
||||
(goto cfg-24)
|
||||
)
|
||||
(+! (-> v1-0 x) -98304.0)
|
||||
(.lvf vf2 (&-> v1-0 quad))
|
||||
(.lvf vf3 (&-> a0-2 quad))
|
||||
)
|
||||
(.sub.vf vf1 vf3 vf2)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.add.y.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.add.z.vf vf1 vf1 vf1 :mask #b1)
|
||||
(.mov v1-13 vf1)
|
||||
(when (< v1-13 19327350000.0)
|
||||
(logior! (-> arg0 mask arg2) (ash 1 arg1))
|
||||
(goto cfg-24)
|
||||
)
|
||||
(label cfg-24)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod ocean-make-trans-camera-masks ((this ocean) (arg0 uint) (arg1 uint) (arg2 uint) (arg3 uint))
|
||||
(local-vars (sv-48 ocean-trans-mask) (sv-52 vector) (sv-56 vector) (sv-60 vector))
|
||||
(set! sv-48 (the-as ocean-trans-mask (&-> this trans-camera-masks (+ (* arg2 4) arg3))))
|
||||
(set! sv-52 (-> *math-camera* trans))
|
||||
(set! sv-56 (new-stack-vector0))
|
||||
(set! sv-60 (new-stack-vector0))
|
||||
(set! (-> sv-56 x) (+ (-> this start-corner x) (* 393216.0 (the float arg1))))
|
||||
(set! (-> sv-56 y) (-> this start-corner y))
|
||||
(set! (-> sv-56 z) (+ (-> this start-corner z) (* 393216.0 (the float arg0))))
|
||||
(set! (-> sv-56 w) 1.0)
|
||||
(dotimes (s5-0 4)
|
||||
(dotimes (s4-0 4)
|
||||
(set! (-> sv-60 x) (- (+ (-> sv-56 x) (* 98304.0 (the float s4-0))) (-> sv-52 x)))
|
||||
(set! (-> sv-60 y) (- (-> sv-56 y) (-> sv-52 y)))
|
||||
(set! (-> sv-60 z) (- (+ (-> sv-56 z) (* 98304.0 (the float s5-0))) (-> sv-52 z)))
|
||||
(ocean-transition-check this sv-48 s4-0 s5-0 sv-56)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-add-upload ((this ocean) (arg0 dma-buffer) (arg1 uint) (arg2 uint))
|
||||
(when (not (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int arg2)))
|
||||
(let ((s0-0 (ocean-trans-camera-masks-bit? this (+ arg1 -1) arg2))
|
||||
(s1-0 (ocean-trans-camera-masks-bit? this (+ arg1 1) arg2))
|
||||
(s2-0 (ocean-trans-camera-masks-bit? this arg1 (+ arg2 -1)))
|
||||
(a0-6 (ocean-trans-camera-masks-bit? this arg1 (+ arg2 1)))
|
||||
(v1-7 0)
|
||||
)
|
||||
(if s0-0
|
||||
(+! v1-7 1)
|
||||
)
|
||||
(if s1-0
|
||||
(+! v1-7 2)
|
||||
)
|
||||
(if s2-0
|
||||
(+! v1-7 4)
|
||||
)
|
||||
(if a0-6
|
||||
(+! v1-7 8)
|
||||
)
|
||||
(cond
|
||||
((= v1-7 1)
|
||||
(if (not (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 -1)) (the-as int arg2)))
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-up-table*) 11 #t)
|
||||
)
|
||||
)
|
||||
((= v1-7 2)
|
||||
(if (not (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 1)) (the-as int arg2)))
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-down-table*) 11 #t)
|
||||
)
|
||||
)
|
||||
((= v1-7 4)
|
||||
(if (not (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 -1))))
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-left-table*) 11 #t)
|
||||
)
|
||||
)
|
||||
((= v1-7 5)
|
||||
(let ((s2-1 (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 -1)) (the-as int arg2)))
|
||||
(v1-25 (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 -1))))
|
||||
)
|
||||
(cond
|
||||
((and s2-1 v1-25)
|
||||
)
|
||||
(s2-1
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-left-table*) 11 #t)
|
||||
)
|
||||
(v1-25
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-up-table*) 11 #t)
|
||||
)
|
||||
(else
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-up-left-table*) 18 #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
((= v1-7 6)
|
||||
(let ((s2-2 (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 1)) (the-as int arg2)))
|
||||
(v1-35 (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 -1))))
|
||||
)
|
||||
(cond
|
||||
((and s2-2 v1-35)
|
||||
)
|
||||
(s2-2
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-left-table*) 11 #t)
|
||||
)
|
||||
(v1-35
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-down-table*) 11 #t)
|
||||
)
|
||||
(else
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-down-left-table*) 18 #t)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
((= v1-7 8)
|
||||
(if (not (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 1))))
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-right-table*) 11 #t)
|
||||
)
|
||||
)
|
||||
((= v1-7 9)
|
||||
(let ((s2-3 (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 -1)) (the-as int arg2)))
|
||||
(v1-50 (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 1))))
|
||||
)
|
||||
(cond
|
||||
((and s2-3 v1-50)
|
||||
)
|
||||
(s2-3
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-right-table*) 11 #t)
|
||||
)
|
||||
(v1-50
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-up-table*) 11 #t)
|
||||
)
|
||||
(else
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-up-right-table*) 18 #t)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
((= v1-7 10)
|
||||
(let ((s2-4 (ocean-trans-mask-ptrs-bit? this (the-as int (+ arg1 1)) (the-as int arg2)))
|
||||
(v1-61 (ocean-trans-mask-ptrs-bit? this (the-as int arg1) (the-as int (+ arg2 1))))
|
||||
)
|
||||
(cond
|
||||
((and s2-4 v1-61)
|
||||
)
|
||||
(s2-4
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-right-table*) 11 #t)
|
||||
)
|
||||
(v1-61
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-down-table*) 11 #t)
|
||||
)
|
||||
(else
|
||||
(ocean-trans-add-upload-table this arg0 arg1 arg2 (the-as int *ocean-trans-down-right-table*) 18 #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod draw-ocean-transition-seams ((this ocean) (arg0 dma-buffer))
|
||||
(local-vars (sv-32 uint) (sv-33 uint) (sv-34 uint) (sv-35 uint) (sv-36 sphere))
|
||||
(set! sv-32 (-> this near-minx))
|
||||
(set! sv-33 (-> this near-maxx))
|
||||
(set! sv-34 (-> this near-minz))
|
||||
(set! sv-35 (-> this near-maxz))
|
||||
(set! sv-36 (new 'stack 'sphere))
|
||||
(set! (-> sv-36 y) (-> this start-corner y))
|
||||
(set! (-> sv-36 r) 69511.42)
|
||||
(when (and (< sv-32 sv-33) (< sv-34 sv-35))
|
||||
(let ((s4-0 sv-34)
|
||||
(s3-0 sv-35)
|
||||
)
|
||||
(while (>= s3-0 s4-0)
|
||||
(let ((s2-0 sv-32)
|
||||
(s1-0 sv-33)
|
||||
)
|
||||
(while (>= s1-0 s2-0)
|
||||
(set! (-> sv-36 x) (+ 49152.0 (* 98304.0 (the float s2-0)) (-> this start-corner x)))
|
||||
(set! (-> sv-36 z) (+ 49152.0 (* 98304.0 (the float s4-0)) (-> this start-corner z)))
|
||||
(when (sphere-cull sv-36)
|
||||
(if (not (ocean-trans-camera-masks-bit? this s4-0 s2-0))
|
||||
(ocean-trans-add-upload this arg0 s4-0 s2-0)
|
||||
)
|
||||
)
|
||||
(+! s2-0 1)
|
||||
)
|
||||
)
|
||||
(+! s4-0 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
(dotimes (v1-28 16)
|
||||
(when (nonzero? (-> this trans-camera-masks v1-28))
|
||||
(dotimes (a0-12 4)
|
||||
(let ((a1-8 (-> this trans-mask-ptrs (+ (* v1-28 4) a0-12))))
|
||||
(if a1-8
|
||||
(logior!
|
||||
(-> (the-as (pointer int32) a1-8) 1)
|
||||
(-> (the-as (pointer uint8) (+ (+ a0-12 (* v1-28 4)) (the-as int this))) 2992)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ocean-trans-add-constants ((this ocean) (arg0 dma-buffer))
|
||||
(let* ((a2-0 4)
|
||||
(v1-0 arg0)
|
||||
(a0-1 (the-as object (-> v1-0 base)))
|
||||
)
|
||||
(set! (-> (the-as dma-packet a0-1) dma) (new 'static 'dma-tag :id (dma-tag-id cnt) :qwc a2-0))
|
||||
(set! (-> (the-as dma-packet a0-1) vif0) (new 'static 'vif-tag :imm #x404 :cmd (vif-cmd stcycl)))
|
||||
(set! (-> (the-as dma-packet a0-1) vif1)
|
||||
(new 'static 'vif-tag :imm #x2fd :cmd (vif-cmd unpack-v4-32) :num a2-0)
|
||||
)
|
||||
(set! (-> v1-0 base) (&+ (the-as pointer a0-1) 16))
|
||||
)
|
||||
(let ((v1-1 (the-as matrix (-> arg0 base))))
|
||||
(set-vector! (-> v1-1 rvec) 0.0 0.0 0.0 1.0)
|
||||
(set-vector! (-> v1-1 uvec) 98304.0 0.0 0.0 1.0)
|
||||
(set-vector! (-> v1-1 fvec) 0.0 0.0 98304.0 1.0)
|
||||
(set-vector! (-> v1-1 trans) 98304.0 0.0 98304.0 1.0)
|
||||
)
|
||||
(&+! (-> arg0 base) 64)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod draw-ocean-transition ((this ocean) (arg0 dma-buffer))
|
||||
(local-vars
|
||||
(sv-32 uint)
|
||||
(sv-33 uint)
|
||||
(sv-34 uint)
|
||||
(sv-35 uint)
|
||||
(sv-36 sphere)
|
||||
(sv-40 ocean-trans-mask)
|
||||
(sv-44 uint)
|
||||
(sv-48 int)
|
||||
)
|
||||
(dotimes (v1-0 16)
|
||||
(set! (-> this trans-camera-masks v1-0) (the-as ocean-trans-mask 0))
|
||||
(set! (-> this near-mask-indices v1-0) (the-as uint -1))
|
||||
)
|
||||
(dotimes (v1-3 64)
|
||||
(set! (-> this trans-mask-ptrs v1-3) (the-as pointer #f))
|
||||
)
|
||||
(set! sv-32 (-> this mid-minx))
|
||||
(set! sv-33 (-> this mid-maxx))
|
||||
(set! sv-34 (-> this mid-minz))
|
||||
(set! sv-35 (-> this mid-maxz))
|
||||
(set! sv-36 (new 'stack 'sphere))
|
||||
(set! (-> sv-36 y) (-> this start-corner y))
|
||||
(set! (-> sv-36 r) 278045.7)
|
||||
(let ((s4-0 sv-34)
|
||||
(s3-0 sv-35)
|
||||
)
|
||||
(while (>= s3-0 s4-0)
|
||||
(let ((s2-0 sv-32)
|
||||
(s1-0 sv-33)
|
||||
)
|
||||
(while (>= s1-0 s2-0)
|
||||
(when (not (ocean-mid-mask-ptrs-bit? this s4-0 s2-0))
|
||||
(when (ocean-mid-camera-masks-bit? this s4-0 s2-0)
|
||||
(set! (-> sv-36 x) (+ 196608.0 (* 393216.0 (the float s2-0)) (-> this start-corner x)))
|
||||
(set! (-> sv-36 z) (+ 196608.0 (* 393216.0 (the float s4-0)) (-> this start-corner z)))
|
||||
(if (sphere-cull sv-36)
|
||||
(ocean-make-trans-camera-masks this s4-0 s2-0 (- s4-0 sv-34) (- s2-0 sv-32))
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! s2-0 1)
|
||||
)
|
||||
)
|
||||
(+! s4-0 1)
|
||||
)
|
||||
)
|
||||
(let ((a2-3 192)
|
||||
(a1-7 0)
|
||||
(a0-11 192)
|
||||
(v1-33 0)
|
||||
)
|
||||
(let ((a3-1 sv-34)
|
||||
(t0-1 sv-35)
|
||||
)
|
||||
(while (>= t0-1 a3-1)
|
||||
(let ((t1-0 sv-32)
|
||||
(t2-0 sv-33)
|
||||
)
|
||||
(while (>= t2-0 t1-0)
|
||||
(set! sv-40 (the-as ocean-trans-mask (&-> this trans-camera-masks (+ (* (- a3-1 sv-34) 4) (- t1-0 sv-32)))))
|
||||
(when (nonzero? (-> sv-40 word))
|
||||
(dotimes (t3-10 4)
|
||||
(let ((t4-4 (-> sv-40 mask t3-10)))
|
||||
(when (nonzero? t4-4)
|
||||
(let ((t5-2 (+ (* a3-1 4) t3-10)))
|
||||
(if (< t5-2 (the-as uint a0-11))
|
||||
(set! a0-11 (the-as int t5-2))
|
||||
)
|
||||
(if (< (the-as uint v1-33) t5-2)
|
||||
(set! v1-33 (the-as int t5-2))
|
||||
)
|
||||
)
|
||||
(dotimes (t5-3 4)
|
||||
(when (logtest? t4-4 (ash 1 t5-3))
|
||||
(let ((t6-9 (+ (* t1-0 4) t5-3)))
|
||||
(if (< t6-9 (the-as uint a2-3))
|
||||
(set! a2-3 (the-as int t6-9))
|
||||
)
|
||||
(if (< (the-as uint a1-7) t6-9)
|
||||
(set! a1-7 (the-as int t6-9))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! t1-0 1)
|
||||
)
|
||||
)
|
||||
(+! a3-1 1)
|
||||
)
|
||||
)
|
||||
(set! (-> this near-minx) (the-as uint (+ a2-3 -1)))
|
||||
(set! (-> this near-maxx) (the-as uint (+ a1-7 1)))
|
||||
(set! (-> this near-minz) (the-as uint (+ a0-11 -1)))
|
||||
(set! (-> this near-maxz) (the-as uint (+ v1-33 1)))
|
||||
)
|
||||
(dotimes (v1-35 16)
|
||||
(set! (-> this trans-temp-masks v1-35) (the-as uint (-> this trans-camera-masks v1-35)))
|
||||
)
|
||||
(let ((s4-1 sv-34)
|
||||
(s3-1 sv-35)
|
||||
)
|
||||
(while (>= s3-1 s4-1)
|
||||
(let ((s2-1 sv-32)
|
||||
(s1-1 sv-33)
|
||||
)
|
||||
(while (>= s1-1 s2-1)
|
||||
(when (not (ocean-mid-mask-ptrs-bit? this s4-1 s2-1))
|
||||
(when (ocean-mid-camera-masks-bit? this s4-1 s2-1)
|
||||
(let ((v1-46 (-> this ocean-trans-indices data (+ (* (the-as uint 48) s4-1) s2-1))))
|
||||
(when (>= (-> v1-46 parent) 0)
|
||||
(set! sv-44 (+ (* (- s4-1 sv-34) 4) (- s2-1 sv-32)))
|
||||
(set! (-> this near-mask-indices sv-44) (the-as uint (-> v1-46 child)))
|
||||
(let ((s0-0 (-> this ocean-mid-masks data (-> v1-46 parent))))
|
||||
(set! sv-48 0)
|
||||
(while (< sv-48 4)
|
||||
(let ((t0-2 (-> s0-0 mask sv-48)))
|
||||
(if (!= t0-2 255)
|
||||
(ocean-trans-add-upload-strip this arg0 s4-1 s2-1 (the-as int t0-2) (the-as int sv-44) sv-48)
|
||||
)
|
||||
)
|
||||
(set! sv-48 (+ sv-48 1))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(+! s2-1 1)
|
||||
)
|
||||
)
|
||||
(+! s4-1 1)
|
||||
)
|
||||
)
|
||||
(ocean-mid-add-call-flush this arg0 (the-as uint 41))
|
||||
(ocean-trans-add-constants this arg0)
|
||||
(draw-ocean-transition-seams this arg0)
|
||||
(ocean-mid-add-call-flush this arg0 (the-as uint 41))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
@@ -7,3 +7,10 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(defmethod-mips2c "(method 14 ocean)" 14 ocean)
|
||||
|
||||
(defmethod-mips2c "(method 15 ocean)" 15 ocean)
|
||||
|
||||
(define ocean-vu0-block (new 'static 'vu-function #|:length 64 :qlength 32|#))
|
||||
|
||||
(defmethod-mips2c "(method 16 ocean)" 16 ocean)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1094,7 +1094,8 @@
|
||||
(else
|
||||
(format
|
||||
0
|
||||
"ERROR: <asg> ~A in spool anim loop for ~A ~D, but not loaded.~"
|
||||
;; og:preserve-this fixed missing %
|
||||
"ERROR: <asg> ~A in spool anim loop for ~A ~D, but not loaded.~%"
|
||||
self
|
||||
(-> gp-0 anim name)
|
||||
(-> gp-0 part)
|
||||
|
||||
@@ -2281,7 +2281,7 @@
|
||||
(logclear! (-> self root status) (collide-status on-surface on-ground touch-surface))
|
||||
(let ((s5-1 2))
|
||||
(logior! (-> self focus-status) (focus-status in-air))
|
||||
(until (on-ground? self)
|
||||
(until (on-ground? self gp-0)
|
||||
(+! (-> gp-0 hang-time) (- (current-time) (-> self clock old-frame-counter)))
|
||||
(jump-anim-handler self s5-1 gp-0)
|
||||
(in-jump-handler self s5-1 gp-0)
|
||||
|
||||
@@ -208,7 +208,7 @@ Based on the implementation of point-poly-intersection?, these should likely be
|
||||
(:methods
|
||||
(debug-draw (_type_) none)
|
||||
(nav-mesh-method-10 (_type_ vector vector nav-poly) nav-poly)
|
||||
(nav-mesh-method-11 (_type_ vector) none)
|
||||
(nav-mesh-method-11 (_type_ vector) nav-poly)
|
||||
(nav-mesh-method-12 (_type_ vector float nav-poly) symbol)
|
||||
(poly-centroid (_type_ nav-poly vector) vector)
|
||||
(poly-centroid-local (_type_ nav-poly vector) vector)
|
||||
|
||||
@@ -2048,7 +2048,6 @@
|
||||
)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch nav-poly vs none.
|
||||
(defmethod nav-mesh-method-11 ((this nav-mesh) (arg0 vector))
|
||||
(let ((v1-0 (new 'stack-no-clear 'nav-find-poly-parms)))
|
||||
(vector-! (-> v1-0 point) arg0 (the-as vector (-> this bounds)))
|
||||
@@ -2056,7 +2055,6 @@
|
||||
(set! (-> v1-0 ignore) (the-as uint 2))
|
||||
(nav-mesh-method-45 this (the-as nav-poly (-> v1-0 point)))
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
(deftype nav-find-clear-spot-work (structure)
|
||||
|
||||
@@ -36,18 +36,18 @@
|
||||
(negate-y symbol)
|
||||
(axial-slop float)
|
||||
(maximum-stretch float)
|
||||
(turn-off-start uint64)
|
||||
(turn-off-duration uint64)
|
||||
(turn-off-start time-frame)
|
||||
(turn-off-duration time-frame)
|
||||
)
|
||||
(:methods
|
||||
(chain-physics-method-9 () none)
|
||||
(chain-physics-method-10 () none)
|
||||
(chain-physics-method-11 () none)
|
||||
(chain-physics-method-12 () none)
|
||||
(chain-physics-method-13 () none)
|
||||
(chain-physics-method-14 () none)
|
||||
(chain-physics-method-15 () none)
|
||||
(chain-physics-method-16 () none)
|
||||
(chain-physics-method-17 () none)
|
||||
(initialize-chain-joints (_type_) symbol)
|
||||
(turn-off (_type_ time-frame) none)
|
||||
(update (_type_ process-drawable) none)
|
||||
(gravity-update (_type_ process-drawable) none)
|
||||
(apply-gravity (_type_ vector int process-drawable) none)
|
||||
(chain-physics-method-14 (_type_ vector int) none)
|
||||
(clamp-length (_type_ vector vector object process-drawable) vector)
|
||||
(chain-physics-method-16 (_type_ int) float)
|
||||
(chain-physics-method-17 (_type_ vector int) none)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -7,3 +7,374 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(defmethod gravity-update ((this chain-physics) (arg0 process-drawable))
|
||||
(vector-seek-3d-smooth! (-> this gravity) (-> this gravity-target) 0.05 0.1)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod apply-gravity ((this chain-physics) (arg0 vector) (arg1 int) (arg2 process-drawable))
|
||||
(with-pp
|
||||
(vector-float*!
|
||||
arg0
|
||||
(-> this gravity)
|
||||
(* 4096.0 (-> pp clock time-adjust-ratio) (fmax 0.2 (lerp-scale 0.38 0.18 (the float arg1) 0.0 5.0)))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod chain-physics-method-14 ((this chain-physics) (arg0 vector) (arg1 int))
|
||||
(vector-float*!
|
||||
arg0
|
||||
(the-as vector (+ (the-as uint (-> this chain-joints 0 velocity)) (* (+ arg1 1) 64)))
|
||||
(fmin 0.9 (lerp-scale 0.2 1.0 (the float arg1) 0.0 4.0))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod clamp-length ((this chain-physics) (arg0 vector) (arg1 vector) (arg2 object) (arg3 process-drawable))
|
||||
(let ((gp-0 (new 'stack-no-clear 'vector)))
|
||||
(vector-! gp-0 arg0 arg1)
|
||||
(vector-normalize! gp-0 (-> this joint-length))
|
||||
(vector+! arg0 gp-0 arg1)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod chain-physics-method-16 ((this chain-physics) (arg0 int))
|
||||
(lerp-scale 5461.3335 10922.667 (the float arg0) 0.0 8.0)
|
||||
)
|
||||
|
||||
(defmethod chain-physics-method-17 ((this chain-physics) (arg0 vector) (arg1 int))
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod initialize-chain-joints ((this chain-physics))
|
||||
(set! (-> this turn-off-start) 0)
|
||||
(dotimes (s5-0 (the-as int (-> this num-joints)))
|
||||
(let ((s4-0 (-> this chain-joints s5-0)))
|
||||
(vector<-cspace! (-> s4-0 position) (-> s4-0 joint-mod joint))
|
||||
(vector-reset! (-> s4-0 velocity))
|
||||
(mode-set! (-> s4-0 joint-mod) (joint-mod-mode foot-rot))
|
||||
)
|
||||
)
|
||||
#f
|
||||
)
|
||||
|
||||
(defmethod turn-off ((this chain-physics) (arg0 time-frame))
|
||||
(set-time! (-> this turn-off-start))
|
||||
(set! (-> this turn-off-duration) arg0)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod update ((this chain-physics) (arg0 process-drawable))
|
||||
(local-vars
|
||||
(v1-78 float)
|
||||
(f0-11 float)
|
||||
(sv-272 chain-physics-joint)
|
||||
(sv-288 vector)
|
||||
(sv-304 vector)
|
||||
(sv-320 (function vector float vector))
|
||||
(sv-336 vector)
|
||||
(sv-352 vector)
|
||||
(sv-368 vector)
|
||||
(sv-384 vector)
|
||||
(sv-400 vector)
|
||||
(sv-416 vector)
|
||||
(sv-432 vector)
|
||||
(sv-448 vector)
|
||||
(sv-464 vector)
|
||||
(sv-480 vector)
|
||||
(sv-496 vector)
|
||||
(sv-512 vector)
|
||||
(sv-528 vector)
|
||||
)
|
||||
(rlet ((acc :class vf)
|
||||
(vf0 :class vf)
|
||||
(vf1 :class vf)
|
||||
(vf2 :class vf)
|
||||
(vf3 :class vf)
|
||||
(vf4 :class vf)
|
||||
(vf5 :class vf)
|
||||
(vf6 :class vf)
|
||||
)
|
||||
(init-vf0-vector)
|
||||
(gravity-update this arg0)
|
||||
(let ((s4-0 (new 'stack-no-clear 'matrix))
|
||||
(s3-0 (vector<-cspace! (new 'stack-no-clear 'vector) (-> arg0 node-list data (-> this root-joint-index))))
|
||||
(s2-0 (vector-normalize-copy!
|
||||
(new 'stack-no-clear 'vector)
|
||||
(-> arg0 node-list data (-> this root-joint-index) bone transform fvec)
|
||||
1.0
|
||||
)
|
||||
)
|
||||
(s1-0 (vector-normalize-copy!
|
||||
(new 'stack-no-clear 'vector)
|
||||
(-> arg0 node-list data (-> this root-joint-index) bone transform uvec)
|
||||
1.0
|
||||
)
|
||||
)
|
||||
)
|
||||
(new 'stack-no-clear 'vector)
|
||||
(let ((f30-0 1.0))
|
||||
(if (nonzero? (-> this turn-off-start))
|
||||
(set! f30-0
|
||||
(fmax
|
||||
0.0
|
||||
(fmin
|
||||
1.0
|
||||
(parameter-ease-sin-clamp
|
||||
(- 1.0 (/ (the float (- (current-time) (-> this turn-off-start))) (the float (-> this turn-off-duration))))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(dotimes (s0-0 (the-as int (-> this num-joints)))
|
||||
(set! sv-272 (-> this chain-joints s0-0))
|
||||
(set! sv-528 (new 'stack-no-clear 'vector))
|
||||
(let ((v1-27 (-> sv-272 position quad)))
|
||||
(set! (-> sv-528 quad) v1-27)
|
||||
)
|
||||
(set! (-> sv-272 joint-mod flex-blend) f30-0)
|
||||
(if (-> this negate-y)
|
||||
(vector-negate! s1-0 s1-0)
|
||||
)
|
||||
(set! sv-288 (new 'stack-no-clear 'vector))
|
||||
(apply-gravity this sv-288 s0-0 arg0)
|
||||
(let ((v1-34 sv-528))
|
||||
(let ((a0-10 sv-528))
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
(.lvf vf4 (&-> a0-10 quad))
|
||||
)
|
||||
(.lvf vf5 (&-> sv-288 quad))
|
||||
(.add.vf vf6 vf4 vf5 :mask #b111)
|
||||
(.svf (&-> v1-34 quad) vf6)
|
||||
)
|
||||
(when (< s0-0 (the-as int (+ (-> this num-joints) -1)))
|
||||
(set! sv-304 (new 'stack-no-clear 'vector))
|
||||
(chain-physics-method-14 this sv-304 s0-0)
|
||||
(let ((v1-40 sv-528))
|
||||
(let ((a0-13 sv-528))
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
(.lvf vf4 (&-> a0-13 quad))
|
||||
)
|
||||
(.lvf vf5 (&-> sv-304 quad))
|
||||
(.add.vf vf6 vf4 vf5 :mask #b111)
|
||||
(.svf (&-> v1-40 quad) vf6)
|
||||
)
|
||||
)
|
||||
(clamp-length this sv-528 s3-0 s0-0 arg0)
|
||||
(set! sv-400 (new 'stack-no-clear 'vector))
|
||||
(let ((v1-43 sv-528)
|
||||
(a0-16 s3-0)
|
||||
)
|
||||
(.lvf vf4 (&-> v1-43 quad))
|
||||
(.lvf vf5 (&-> a0-16 quad))
|
||||
)
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
(.sub.vf vf6 vf4 vf5 :mask #b111)
|
||||
(.svf (&-> sv-400 quad) vf6)
|
||||
(let ((f28-1 (vector-normalize-ret-len! sv-400 1.0))
|
||||
(f24-0 (vector-dot sv-400 s1-0))
|
||||
(f26-0 (chain-physics-method-16 this s0-0))
|
||||
)
|
||||
(when (< f24-0 (cos f26-0))
|
||||
(vector--float*! sv-400 sv-400 s1-0 f24-0)
|
||||
(set! sv-320 vector-normalize!)
|
||||
(set! sv-336 sv-400)
|
||||
(let ((a1-17 (sin f26-0)))
|
||||
(sv-320 sv-336 a1-17)
|
||||
)
|
||||
(set! sv-384 sv-400)
|
||||
(set! sv-352 sv-400)
|
||||
(set! sv-368 s1-0)
|
||||
(let ((f0-6 (cos f26-0)))
|
||||
(.lvf vf2 (&-> sv-368 quad))
|
||||
(.lvf vf1 (&-> sv-352 quad))
|
||||
(let ((v1-55 f0-6))
|
||||
(.mov vf3 v1-55)
|
||||
)
|
||||
)
|
||||
(.add.x.vf vf4 vf0 vf0 :mask #b1000)
|
||||
(.mul.x.vf acc vf2 vf3)
|
||||
(.add.mul.w.vf vf4 vf1 vf0 acc :mask #b111)
|
||||
(.svf (&-> sv-384 quad) vf4)
|
||||
(vector+float*! sv-528 s3-0 sv-400 f28-1)
|
||||
)
|
||||
)
|
||||
(chain-physics-method-17 this sv-528 s0-0)
|
||||
(set! sv-432 (new 'stack-no-clear 'vector))
|
||||
(let ((v1-61 s3-0)
|
||||
(a0-27 sv-528)
|
||||
)
|
||||
(.lvf vf4 (&-> v1-61 quad))
|
||||
(.lvf vf5 (&-> a0-27 quad))
|
||||
)
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
(.sub.vf vf6 vf4 vf5 :mask #b111)
|
||||
(.svf (&-> sv-432 quad) vf6)
|
||||
(vector-normalize-ret-len! sv-432 1.0)
|
||||
(set! sv-416 (new 'stack-no-clear 'vector))
|
||||
(let ((v1-64 sv-528)
|
||||
(a0-30 (-> sv-272 position))
|
||||
)
|
||||
(.lvf vf4 (&-> v1-64 quad))
|
||||
(.lvf vf5 (&-> a0-30 quad))
|
||||
)
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
(.sub.vf vf6 vf4 vf5 :mask #b111)
|
||||
(.svf (&-> sv-416 quad) vf6)
|
||||
(let ((f28-2 (vector-dot sv-432 sv-416)))
|
||||
(vector--float*! sv-416 sv-416 sv-432 f28-2)
|
||||
(cond
|
||||
((< f28-2 0.0)
|
||||
(set! f0-11 (* f28-2 (-> this compress-vel-parallel)))
|
||||
(vector-float*! sv-416 sv-416 (-> this compress-vel))
|
||||
)
|
||||
(else
|
||||
(set! f0-11 (* f28-2 (-> this stretch-vel-parallel)))
|
||||
(vector-float*! sv-416 sv-416 (-> this stretch-vel))
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-73 (-> sv-272 velocity)))
|
||||
(.lvf vf2 (&-> sv-432 quad))
|
||||
(.lvf vf1 (&-> sv-416 quad))
|
||||
(let ((a0-37 f0-11))
|
||||
(.mov vf3 a0-37)
|
||||
)
|
||||
(.add.x.vf vf4 vf0 vf0 :mask #b1000)
|
||||
(.mul.x.vf acc vf2 vf3)
|
||||
(.add.mul.w.vf vf4 vf1 vf0 acc :mask #b111)
|
||||
(.svf (&-> v1-73 quad) vf4)
|
||||
)
|
||||
(vector+! sv-528 (-> sv-272 position) (-> sv-272 velocity))
|
||||
(let ((a2-9 (vector-! (new 'stack-no-clear 'vector) s3-0 sv-528)))
|
||||
(.lvf vf1 (&-> a2-9 quad))
|
||||
(.add.w.vf vf2 vf0 vf0 :mask #b1)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.mul.x.vf acc vf2 vf1 :mask #b1)
|
||||
(.add.mul.y.vf acc vf2 vf1 acc :mask #b1)
|
||||
(.add.mul.z.vf vf1 vf2 vf1 acc :mask #b1)
|
||||
(.mov v1-78 vf1)
|
||||
(let* ((f0-13 v1-78)
|
||||
(f1-6 (* (-> this maximum-stretch) (-> this joint-length)))
|
||||
(f2-3 f1-6)
|
||||
)
|
||||
(if (< (* f2-3 f2-3) f0-13)
|
||||
(vector--float*! sv-528 s3-0 a2-9 (/ f1-6 (sqrtf f0-13)))
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> sv-272 position quad) (-> sv-528 quad))
|
||||
(if (-> sv-272 joint-mod)
|
||||
(set! (-> sv-272 joint-mod trans quad) (-> sv-528 quad))
|
||||
)
|
||||
(when (< s0-0 (the-as int (-> this num-joints)))
|
||||
(vector-! (-> s4-0 uvec) sv-528 s3-0)
|
||||
(vector-normalize! (-> s4-0 uvec) 1.0)
|
||||
(if (-> this negate-y)
|
||||
(vector-negate! (-> s4-0 uvec) (-> s4-0 uvec))
|
||||
)
|
||||
(vector-cross! (-> s4-0 rvec) (-> s4-0 uvec) s2-0)
|
||||
(vector-normalize! (-> s4-0 rvec) 1.0)
|
||||
(set! sv-496 (new 'stack-no-clear 'vector))
|
||||
(let ((v1-97 (-> sv-272 old-x))
|
||||
(a0-51 (-> s4-0 rvec))
|
||||
)
|
||||
(.lvf vf1 (&-> v1-97 quad))
|
||||
(.lvf vf2 (&-> a0-51 quad))
|
||||
)
|
||||
(.outer.product.a.vf acc vf1 vf2)
|
||||
(.outer.product.b.vf vf3 vf2 vf1 acc)
|
||||
(.svf (&-> sv-496 quad) vf3)
|
||||
(vector-flatten! sv-496 (-> sv-272 old-x) (-> s4-0 uvec))
|
||||
(vector-normalize! sv-496 1.0)
|
||||
(cond
|
||||
((< (vector-dot (-> s4-0 rvec) sv-496) (cos (-> this axial-slop)))
|
||||
(vector-cross! sv-496 sv-496 (-> s4-0 rvec))
|
||||
(vector-cross! sv-496 (-> s4-0 rvec) sv-496)
|
||||
(vector-normalize! sv-496 1.0)
|
||||
(set! sv-464 (-> s4-0 rvec))
|
||||
(set! sv-448 (-> s4-0 rvec))
|
||||
(let ((f0-20 (cos (-> this axial-slop))))
|
||||
(.lvf vf1 (&-> sv-448 quad))
|
||||
(let ((v1-107 f0-20))
|
||||
(.mov vf2 v1-107)
|
||||
)
|
||||
)
|
||||
(.add.x.vf vf1 vf0 vf0 :mask #b1000)
|
||||
(.mul.x.vf vf1 vf1 vf2 :mask #b111)
|
||||
(.svf (&-> sv-464 quad) vf1)
|
||||
(set! sv-512 (-> s4-0 rvec))
|
||||
(set! sv-480 (-> s4-0 rvec))
|
||||
(let ((f0-22 (sin (-> this axial-slop))))
|
||||
(.lvf vf2 (&-> sv-496 quad))
|
||||
(.lvf vf1 (&-> sv-480 quad))
|
||||
(let ((v1-113 f0-22))
|
||||
(.mov vf3 v1-113)
|
||||
)
|
||||
)
|
||||
(.add.x.vf vf4 vf0 vf0 :mask #b1000)
|
||||
(.mul.x.vf acc vf2 vf3)
|
||||
(.add.mul.w.vf vf4 vf1 vf0 acc :mask #b111)
|
||||
(.svf (&-> sv-512 quad) vf4)
|
||||
(set! (-> sv-272 old-x quad) (-> s4-0 rvec quad))
|
||||
)
|
||||
(else
|
||||
(set! (-> s4-0 rvec quad) (-> sv-496 quad))
|
||||
(set! (-> sv-272 old-x quad) (-> s4-0 rvec quad))
|
||||
)
|
||||
)
|
||||
(vector-cross! (-> s4-0 fvec) (-> s4-0 rvec) (-> s4-0 uvec))
|
||||
(matrix->quaternion (-> sv-272 joint-mod quat) s4-0)
|
||||
(set! (-> s1-0 quad) (-> s4-0 uvec quad))
|
||||
(set! (-> s2-0 quad) (-> s4-0 fvec quad))
|
||||
0
|
||||
)
|
||||
(set! (-> s3-0 quad) (-> sv-528 quad))
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod relocate ((this chain-physics) (offset int))
|
||||
(dotimes (v1-0 (the-as int (-> this num-joints)))
|
||||
(if (nonzero? (-> this chain-joints v1-0 joint-mod))
|
||||
(&+! (-> this chain-joints v1-0 joint-mod) offset)
|
||||
)
|
||||
)
|
||||
this
|
||||
)
|
||||
|
||||
(defun chain-physics-initialize ((arg0 process-drawable) (arg1 chain-physics) (arg2 int) (arg3 float) (arg4 (array chain-physics-setup)))
|
||||
(set! (-> arg1 num-joints) (the-as uint (min 20 (-> arg4 length))))
|
||||
(dotimes (s1-0 (the-as int (-> arg1 num-joints)))
|
||||
(set! (-> arg1 chain-joints s1-0 joint-mod)
|
||||
(new 'process 'joint-mod (joint-mod-mode flex-blend) arg0 (-> arg4 s1-0 joint-index))
|
||||
)
|
||||
(set! (-> arg1 chain-joints s1-0 joint-mod track-mode) (track-mode no-scale))
|
||||
)
|
||||
(set! (-> arg1 root-joint-index) (the-as uint arg2))
|
||||
(set! (-> arg1 joint-length) arg3)
|
||||
(set-vector! (-> arg1 gravity) 0.0 -1.0 0.0 1.0)
|
||||
(set! (-> arg1 gravity-target quad) (-> arg1 gravity quad))
|
||||
(set! (-> arg1 stretch-vel) 0.7)
|
||||
(set! (-> arg1 stretch-vel-parallel) 0.8)
|
||||
(set! (-> arg1 compress-vel) 0.85)
|
||||
(set! (-> arg1 compress-vel-parallel) 0.75)
|
||||
(set! (-> arg1 negate-y) #f)
|
||||
(set! (-> arg1 axial-slop) 3640.889)
|
||||
(set! (-> arg1 maximum-stretch) 1.5)
|
||||
(set! (-> arg1 turn-off-start) 0)
|
||||
0
|
||||
)
|
||||
|
||||
@@ -193,7 +193,7 @@
|
||||
(ragdoll-setup! (_type_ process-drawable ragdoll-setup) none)
|
||||
(ragdoll-method-17 (_type_ process-drawable) none)
|
||||
(ragdoll-method-18 (_type_) none)
|
||||
(ragdoll-method-19 (_type_ vector int object vector) none)
|
||||
(ragdoll-method-19 (_type_ vector int object matrix) none)
|
||||
(reset-vec! (_type_ vector) none)
|
||||
(ragdoll-method-21 (_type_ vector vector float) vector)
|
||||
(get-max-angle-for-joint-idx (_type_ int) degrees)
|
||||
@@ -205,7 +205,8 @@
|
||||
|
||||
|
||||
(deftype ragdoll-proc (process)
|
||||
((parent (pointer process-drawable) :override)
|
||||
((self ragdoll-proc :override)
|
||||
(parent (pointer process-drawable) :override)
|
||||
(ragdoll ragdoll)
|
||||
(last-attack-id uint32)
|
||||
)
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod ragdoll-method-19 ((this ragdoll) (arg0 vector) (arg1 int) (arg2 object) (arg3 vector))
|
||||
(defmethod ragdoll-method-19 ((this ragdoll) (arg0 vector) (arg1 int) (arg2 object) (arg3 matrix))
|
||||
(local-vars (v1-22 float))
|
||||
(with-pp
|
||||
(rlet ((acc :class vf)
|
||||
@@ -1184,7 +1184,7 @@
|
||||
)
|
||||
(when (or (zero? (the-as object arg1)) (-> arg1 gravity))
|
||||
(set! sv-320 (new 'stack-no-clear 'vector))
|
||||
(ragdoll-method-19 this sv-320 s1-1 arg0 (the-as vector s2-1))
|
||||
(ragdoll-method-19 this sv-320 s1-1 arg0 s2-1)
|
||||
(let ((v1-93 sv-560))
|
||||
(let ((a0-39 sv-560))
|
||||
(.mov.vf vf6 vf0 :mask #b1000)
|
||||
@@ -1537,13 +1537,7 @@
|
||||
|
||||
(defmethod ragdoll-proc-method-15 ((this ragdoll-proc) (arg0 symbol) (arg1 vector) (arg2 symbol))
|
||||
(if (nonzero? (-> this ragdoll))
|
||||
(ragdoll-method-10
|
||||
(-> this ragdoll)
|
||||
(the-as process-drawable (ppointer->process (-> this parent)))
|
||||
arg0
|
||||
arg1
|
||||
arg2
|
||||
)
|
||||
(ragdoll-method-10 (-> this ragdoll) (ppointer->process (-> this parent)) arg0 arg1 arg2)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -1559,7 +1553,7 @@
|
||||
|
||||
(defmethod ragdoll-proc-method-17 ((this ragdoll-proc) (arg0 ragdoll-edit-info))
|
||||
(if (nonzero? (-> this ragdoll))
|
||||
(ragdoll-method-15 (-> this ragdoll) (the-as process-drawable (ppointer->process (-> this parent))) arg0)
|
||||
(ragdoll-method-15 (-> this ragdoll) (ppointer->process (-> this parent)) arg0)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -1567,11 +1561,7 @@
|
||||
|
||||
(defmethod ragdoll-proc-method-18 ((this ragdoll-proc) (arg0 ragdoll-edit-info))
|
||||
(if (and (nonzero? (-> this ragdoll)) (-> this ragdoll) (nonzero? arg0) arg0)
|
||||
(ragdoll-edit-info-method-17
|
||||
arg0
|
||||
(-> this ragdoll)
|
||||
(the-as process-drawable (ppointer->process (-> this parent)))
|
||||
)
|
||||
(ragdoll-edit-info-method-17 arg0 (-> this ragdoll) (ppointer->process (-> this parent)))
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -1605,23 +1595,23 @@
|
||||
)
|
||||
((= proc *target*)
|
||||
(set! (-> s4-0 quad) (-> (the-as process-drawable proc) root trans quad))
|
||||
(vector-! s5-0 (-> (the-as process-drawable s2-0) root trans) (-> (the-as process-drawable proc) root trans))
|
||||
(vector-! s5-0 (-> s2-0 root trans) (-> (the-as process-drawable proc) root trans))
|
||||
(set! s3-0 #t)
|
||||
)
|
||||
(else
|
||||
(when (and (-> block param 0) (type? (-> (the-as process-drawable s2-0) root) collide-shape))
|
||||
(when (and (-> block param 0) (type? (-> s2-0 root) collide-shape))
|
||||
(let* ((a3-1 (the-as object (-> block param 0)))
|
||||
(a1-10 (-> (the-as touching-prims-entry a3-1) u))
|
||||
)
|
||||
(get-intersect-point
|
||||
s5-0
|
||||
(the-as touching-prims-entry a1-10)
|
||||
(the-as collide-shape (-> (the-as process-drawable s2-0) root))
|
||||
(the-as collide-shape (-> s2-0 root))
|
||||
(the-as touching-shapes-entry a3-1)
|
||||
)
|
||||
)
|
||||
(set! (-> s4-0 quad) (-> s5-0 quad))
|
||||
(vector-! s5-0 (-> (the-as process-drawable s2-0) root trans) s5-0)
|
||||
(vector-! s5-0 (-> s2-0 root trans) s5-0)
|
||||
(set! s3-0 #t)
|
||||
)
|
||||
(when (logtest? (attack-mask attacker-velocity) (-> (the-as attack-info gp-0) mask))
|
||||
@@ -1665,11 +1655,7 @@
|
||||
((and (logtest? (-> self ragdoll ragdoll-flags) (ragdoll-flag rf4))
|
||||
(or (< 0.0 (-> self ragdoll flex-blend)) (logtest? (-> self ragdoll ragdoll-flags) (ragdoll-flag rf5)))
|
||||
)
|
||||
(ragdoll-method-15
|
||||
(-> self ragdoll)
|
||||
(the-as process-drawable (ppointer->process (-> self parent)))
|
||||
(the-as ragdoll-edit-info 0)
|
||||
)
|
||||
(ragdoll-method-15 (-> self ragdoll) (ppointer->process (-> self parent)) (the-as ragdoll-edit-info 0))
|
||||
)
|
||||
((and (logtest? (-> self ragdoll ragdoll-flags) (ragdoll-flag rf3))
|
||||
(and (= (-> self ragdoll flex-blend) 0.0) (not (logtest? (-> self ragdoll ragdoll-flags) (ragdoll-flag rf5))))
|
||||
@@ -1686,7 +1672,7 @@
|
||||
(defmethod deactivate ((this ragdoll-proc))
|
||||
"Make a process dead, clean it up, remove it from the active pool, and return to dead pool."
|
||||
(if (nonzero? (-> this ragdoll))
|
||||
(ragdoll-method-17 (-> this ragdoll) (the-as process-drawable (ppointer->process (-> this parent))))
|
||||
(ragdoll-method-17 (-> this ragdoll) (ppointer->process (-> this parent)))
|
||||
)
|
||||
((method-of-type process deactivate) this)
|
||||
(none)
|
||||
@@ -1704,7 +1690,7 @@
|
||||
(set! (-> self last-attack-id) (the-as uint 0))
|
||||
(set! (-> self ragdoll) (new 'process 'ragdoll))
|
||||
(if (nonzero? (-> self ragdoll))
|
||||
(ragdoll-setup! (-> self ragdoll) (the-as process-drawable (ppointer->process (-> self parent))) arg0)
|
||||
(ragdoll-setup! (-> self ragdoll) (ppointer->process (-> self parent)) arg0)
|
||||
(format 0 "ERROR<gmj>: didn't have enough memory to allocate ragdoll for ragdoll-proc~%")
|
||||
)
|
||||
(go-virtual idle)
|
||||
|
||||
@@ -197,14 +197,15 @@
|
||||
|
||||
|
||||
(deftype rigid-body-object (process-focusable)
|
||||
((info rigid-body-object-constants)
|
||||
((root collide-shape-moving :override)
|
||||
(info rigid-body-object-constants)
|
||||
(flags rigid-body-object-flag)
|
||||
(max-time-step float)
|
||||
(incoming-attack-id uint32)
|
||||
(player-touch-time time-frame)
|
||||
(disturbed-time time-frame)
|
||||
(player-force-position vector :inline)
|
||||
(player-force vector :inline)
|
||||
(player-force-position vector :inline)
|
||||
(player-force vector :inline)
|
||||
)
|
||||
(:state-methods
|
||||
idle
|
||||
|
||||
@@ -843,7 +843,7 @@
|
||||
(while (nonzero? s4-1)
|
||||
(+! s4-1 -1)
|
||||
(s3-0 arg0 f30-0)
|
||||
(rigid-body-control-method-9 this (the-as collide-shape-moving (-> arg0 root)) f30-0)
|
||||
(rigid-body-control-method-9 this (-> arg0 root) f30-0)
|
||||
)
|
||||
)
|
||||
0
|
||||
@@ -1023,7 +1023,7 @@
|
||||
(defmethod rbody-post ((this rigid-body-object))
|
||||
(rigid-body-object-method-32 this)
|
||||
(rigid-body-object-method-38 this)
|
||||
(update-rbody-transform! (-> this rbody) (the-as collide-shape-moving (-> this root)))
|
||||
(update-rbody-transform! (-> this rbody) (-> this root))
|
||||
(rigid-body-object-method-30 this)
|
||||
(update-transforms (-> this root))
|
||||
0
|
||||
|
||||
@@ -1519,11 +1519,11 @@
|
||||
(merc-eye-anim this)
|
||||
)
|
||||
(label cfg-45)
|
||||
;; (let ((a0-26 (-> gp-0 effect)))
|
||||
;; (if a0-26
|
||||
;; (effect-control-method-9 a0-26)
|
||||
;; )
|
||||
;; )
|
||||
(let ((a0-26 (-> gp-0 effect)))
|
||||
(if a0-26
|
||||
(effect-control-method-9 a0-26)
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -1706,15 +1706,11 @@
|
||||
|
||||
(defmethod update ((this top-anim-joint-control))
|
||||
(with-pp
|
||||
(let* ((v1-0 (-> this process))
|
||||
(pp (if v1-0
|
||||
(the-as process-drawable (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
(s3-0 (get-channel this 1))
|
||||
(s5-0 (get-channel this 0))
|
||||
(s4-0 (-> this base-anim))
|
||||
)
|
||||
(let ((pp (ppointer->process (-> this process)))
|
||||
(s3-0 (get-channel this 1))
|
||||
(s5-0 (get-channel this 0))
|
||||
(s4-0 (-> this base-anim))
|
||||
)
|
||||
(set! (-> this frame-group-push) #f)
|
||||
(cond
|
||||
((= (-> this interp) 0.0)
|
||||
|
||||
@@ -81,7 +81,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype process-focusable (process-drawable)
|
||||
((root collide-shape :override)
|
||||
((self process-focusable :override)
|
||||
(root collide-shape :override)
|
||||
(focus-status focus-status)
|
||||
)
|
||||
(:methods
|
||||
@@ -127,7 +128,10 @@
|
||||
(-> (the-as collide-shape-moving cshape) gspot-pos)
|
||||
)
|
||||
((and (or (= mode 2) (= mode 3) (= mode 10)) (type? cshape collide-shape))
|
||||
(-> (the-as collide-shape-moving cshape) root-prim prim-core)
|
||||
;; og:preserve-this added check here so we don't use invalid bones
|
||||
(if (logtest? (-> this draw status) (draw-control-status uninited))
|
||||
(-> (the-as collide-shape-moving cshape) trans)
|
||||
(-> (the-as collide-shape-moving cshape) root-prim prim-core))
|
||||
)
|
||||
(else
|
||||
(-> cshape trans)
|
||||
|
||||
@@ -45,7 +45,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype board (process-drawable)
|
||||
((parent (pointer target) :override)
|
||||
((self board :override)
|
||||
(parent (pointer target) :override)
|
||||
(control control-info :overlay-at root)
|
||||
(shadow-backup shadow-geo :offset 208)
|
||||
(main joint-mod)
|
||||
|
||||
@@ -2682,14 +2682,14 @@
|
||||
(sound-stop (-> self board ride-sound-id))
|
||||
)
|
||||
(let* ((v1-65 (-> self control ground-pat material))
|
||||
(a0-44 (if (or (= v1-65 (pat-material wood)) (= v1-65 (pat-material crwood)) (= v1-65 (pat-material hdwood)))
|
||||
(make-u128 (the-as uint #x646f6f772d6c69) (the-as uint #x61722d6472616f62))
|
||||
(make-u128 (the-as uint #x6c746d2d6c69) (the-as uint #x61722d6472616f62))
|
||||
)
|
||||
)
|
||||
(name (if (or (= v1-65 (pat-material wood)) (= v1-65 (pat-material crwood)) (= v1-65 (pat-material hdwood)))
|
||||
(the-as sound-name (static-sound-name "board-rail-wood"))
|
||||
(the-as sound-name (static-sound-name "board-rail-mtl"))
|
||||
)
|
||||
)
|
||||
)
|
||||
(sound-play-by-name
|
||||
(the-as sound-name a0-44)
|
||||
name
|
||||
(-> self board ride-sound-id)
|
||||
(the int (* 1024.0 f30-1))
|
||||
(the int (* 1524.0 f28-1))
|
||||
|
||||
@@ -17,30 +17,30 @@
|
||||
|
||||
(defbehavior board-post board ()
|
||||
(let ((v1-0 (ppointer->process (-> self parent))))
|
||||
(set! (-> self root trans quad) (-> (the-as target v1-0) board board-trans quad))
|
||||
(let ((a0-4 (-> (the-as target v1-0) board board-quat quad)))
|
||||
(set! (-> self root trans quad) (-> v1-0 board board-trans quad))
|
||||
(let ((a0-4 (-> v1-0 board board-quat quad)))
|
||||
(set! (-> self root quat quad) a0-4)
|
||||
)
|
||||
(set! (-> self root scale quad) (-> (the-as target v1-0) board board-scale quad))
|
||||
(set! (-> self draw light-index) (-> (the-as target v1-0) draw light-index))
|
||||
(let ((a0-10 (-> (the-as target v1-0) draw color-mult quad)))
|
||||
(set! (-> self root scale quad) (-> v1-0 board board-scale quad))
|
||||
(set! (-> self draw light-index) (-> v1-0 draw light-index))
|
||||
(let ((a0-10 (-> v1-0 draw color-mult quad)))
|
||||
(set! (-> self draw color-mult quad) a0-10)
|
||||
)
|
||||
(let ((a0-12 (-> (the-as target v1-0) draw color-emissive quad)))
|
||||
(let ((a0-12 (-> v1-0 draw color-emissive quad)))
|
||||
(set! (-> self draw color-emissive quad) a0-12)
|
||||
)
|
||||
(set! (-> self draw force-fade) (-> (the-as target v1-0) draw force-fade))
|
||||
(set! (-> self draw global-effect) (-> (the-as target v1-0) draw global-effect))
|
||||
(set! (-> self draw force-fade) (-> v1-0 draw force-fade))
|
||||
(set! (-> self draw global-effect) (-> v1-0 draw global-effect))
|
||||
(set! (-> self draw death-vertex-skip) (-> self parent 0 draw death-vertex-skip))
|
||||
(set! (-> self draw death-effect) (-> self parent 0 draw death-effect))
|
||||
(set! (-> self draw death-timer) (-> self parent 0 draw death-timer))
|
||||
(set! (-> self draw death-timer-org) (-> self parent 0 draw death-timer-org))
|
||||
(set! (-> self draw death-draw-overlap) (-> self parent 0 draw death-draw-overlap))
|
||||
(let ((a0-39 (-> (the-as target v1-0) draw shadow-ctrl settings shadow-dir quad)))
|
||||
(let ((a0-39 (-> v1-0 draw shadow-ctrl settings shadow-dir quad)))
|
||||
(set! (-> self draw shadow-ctrl settings shadow-dir quad) a0-39)
|
||||
)
|
||||
(cond
|
||||
((logtest? (-> (the-as target v1-0) draw shadow-ctrl settings flags) (shadow-flags disable-draw))
|
||||
((logtest? (-> v1-0 draw shadow-ctrl settings flags) (shadow-flags disable-draw))
|
||||
(let ((a0-45 (-> self draw shadow-ctrl)))
|
||||
(logior! (-> a0-45 settings flags) (shadow-flags disable-draw))
|
||||
)
|
||||
@@ -53,25 +53,21 @@
|
||||
0
|
||||
)
|
||||
)
|
||||
(if (or (logtest? (-> (the-as target v1-0) draw status)
|
||||
(draw-control-status no-draw no-draw-temp no-draw-bounds no-draw-bounds2)
|
||||
)
|
||||
(or (logtest? (-> (the-as target v1-0) target-effect) 1)
|
||||
(zero? (-> (the-as target v1-0) skel active-channels))
|
||||
)
|
||||
(if (or (logtest? (-> v1-0 draw status) (draw-control-status no-draw no-draw-temp no-draw-bounds no-draw-bounds2))
|
||||
(or (logtest? (-> v1-0 target-effect) 1) (zero? (-> v1-0 skel active-channels)))
|
||||
)
|
||||
(logior! (-> self draw status) (draw-control-status no-draw))
|
||||
(logclear! (-> self draw status) (draw-control-status no-draw))
|
||||
)
|
||||
(if (logtest? (-> (the-as target v1-0) draw status) (draw-control-status force-fade))
|
||||
(if (logtest? (-> v1-0 draw status) (draw-control-status force-fade))
|
||||
(logior! (-> self draw status) (draw-control-status force-fade))
|
||||
(logclear! (-> self draw status) (draw-control-status force-fade))
|
||||
)
|
||||
(if (logtest? (-> (the-as target v1-0) target-effect) 7)
|
||||
(if (logtest? (-> v1-0 target-effect) 7)
|
||||
(logior! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
(logclear! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
)
|
||||
(if (logtest? (-> (the-as target v1-0) target-effect) 56)
|
||||
(if (logtest? (-> v1-0 target-effect) 56)
|
||||
(logior! (-> self draw global-effect) (draw-control-global-effect rim-lights))
|
||||
(logclear! (-> self draw global-effect) (draw-control-global-effect rim-lights))
|
||||
)
|
||||
@@ -84,18 +80,9 @@
|
||||
(defstate hidden (board)
|
||||
:virtual #t
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(if (not (focus-test?
|
||||
(the-as target (if v1-0
|
||||
(the-as target (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
)
|
||||
(go-virtual idle #t)
|
||||
)
|
||||
)
|
||||
(if (not (focus-test? (the-as target (ppointer->process (-> self parent))) in-head))
|
||||
(go-virtual idle #t)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-set! 0)
|
||||
@@ -116,24 +103,16 @@
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(cond
|
||||
((focus-test?
|
||||
(the-as target (if v1-0
|
||||
(the-as target (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
(cond
|
||||
((focus-test? (the-as target (ppointer->process (-> self parent))) in-head)
|
||||
(+! (-> self in-head-time) (- (current-time) (-> self clock old-frame-counter)))
|
||||
(if (< (seconds 0.1) (-> self in-head-time))
|
||||
(go-virtual hidden)
|
||||
)
|
||||
(+! (-> self in-head-time) (- (current-time) (-> self clock old-frame-counter)))
|
||||
(if (< (seconds 0.1) (-> self in-head-time))
|
||||
(go-virtual hidden)
|
||||
)
|
||||
)
|
||||
(else
|
||||
(set! (-> self in-head-time) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
(else
|
||||
(set! (-> self in-head-time) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -172,32 +151,13 @@
|
||||
(-> v1-0 0 self)
|
||||
)
|
||||
)
|
||||
(let ((v1-2 (-> self parent)))
|
||||
(cond
|
||||
((focus-test?
|
||||
(the-as target (if v1-2
|
||||
(the-as target (-> v1-2 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
(go-virtual hidden)
|
||||
)
|
||||
((let ((v1-9 #x40000)
|
||||
(a0-3 (-> self parent))
|
||||
)
|
||||
(not (logtest? (the-as focus-status v1-9) (-> (the-as target (if a0-3
|
||||
(the-as target (-> a0-3 0 self))
|
||||
)
|
||||
)
|
||||
focus-status
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(go-virtual idle #f)
|
||||
)
|
||||
)
|
||||
(cond
|
||||
((focus-test? (the-as target (ppointer->process (-> self parent))) in-head)
|
||||
(go-virtual hidden)
|
||||
)
|
||||
((not (focus-test? (the-as target (ppointer->process (-> self parent))) board))
|
||||
(go-virtual idle #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
|
||||
@@ -1353,7 +1353,7 @@
|
||||
)
|
||||
)
|
||||
(let ((t9-12 sound-play-by-spec)
|
||||
(a0-18 (static-sound-spec "board-steady" :group 1 :volume 0.0 :mask (pitch reg0)))
|
||||
(a0-18 (static-sound-spec "board-steady" :group 0 :volume 0.0 :mask (pitch reg0)))
|
||||
)
|
||||
(set! (-> a0-18 volume) (the int (* 1024.0 (-> self board engine-sound-volume))))
|
||||
(set! (-> a0-18 pitch-mod) (the int (* 1524.0 (-> self board engine-sound-pitch))))
|
||||
@@ -1373,7 +1373,7 @@
|
||||
)
|
||||
)
|
||||
(let ((t9-15 sound-play-by-spec)
|
||||
(a0-23 (static-sound-spec "board-wind" :group 1 :volume 0.0 :mask (pitch reg0)))
|
||||
(a0-23 (static-sound-spec "board-wind" :group 0 :volume 0.0 :mask (pitch reg0)))
|
||||
)
|
||||
(set! (-> a0-23 volume) (the int (-> self board wind-sound-volume)))
|
||||
(set! (-> a0-23 pitch-mod) (the int (-> self board wind-sound-pitch)))
|
||||
@@ -1417,7 +1417,7 @@
|
||||
)
|
||||
(seek! (-> self board eco-sound-volume) 1.0 (seconds-per-frame))
|
||||
(let ((t9-22 sound-play-by-spec)
|
||||
(a0-43 (static-sound-spec "eco-loop" :group 1 :volume 0.0))
|
||||
(a0-43 (static-sound-spec "eco-loop" :group 0 :volume 0.0))
|
||||
)
|
||||
(set! (-> a0-43 volume) (the int (* 1024.0 (-> self board eco-sound-volume))))
|
||||
(t9-22 a0-43 (-> self board eco-sound-id) (the-as vector #t))
|
||||
|
||||
@@ -5,5 +5,720 @@
|
||||
;; name in dgo: flut-racer
|
||||
;; dgos: WASLEAPR
|
||||
|
||||
(declare-type civilian nav-enemy)
|
||||
(define-extern wascity-race-ring-cleared? (function quaternion vector symbol))
|
||||
(define-extern flut-random-color-index (function int))
|
||||
(define-extern flut-color-from-index (function int none :behavior flut))
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype flut-racer (nav-enemy)
|
||||
((current-ring uint8)
|
||||
(taskman handle)
|
||||
(minimap connection-minimap)
|
||||
(probe vector :inline)
|
||||
(last-speed-update time-frame)
|
||||
)
|
||||
(:state-methods
|
||||
wait
|
||||
race
|
||||
halt
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(defskelgroup skel-flut-racer flut-wild flut-wild-lod0-jg flut-wild-idle-ja
|
||||
((flut-wild-lod0-mg (meters 999999)))
|
||||
:bounds (static-spherem 0 0 0 4)
|
||||
:shadow flut-wild-shadow-mg
|
||||
)
|
||||
|
||||
(define *flut-racer-enemy-info*
|
||||
(new 'static 'nav-enemy-info
|
||||
:use-die-falling #f
|
||||
:use-victory #f
|
||||
:use-jump-blocked #f
|
||||
:debug-draw-neck #f
|
||||
:jump-debug-draw #t
|
||||
:move-to-ground #t
|
||||
:hover-if-no-ground #f
|
||||
:idle-anim-script (new 'static 'inline-array idle-control-frame 3
|
||||
(new 'static 'idle-control-frame :command (idle-control-cmd push) :param0 30)
|
||||
(new 'static 'idle-control-frame
|
||||
:command (idle-control-cmd play)
|
||||
:anim #x3
|
||||
:param0 2
|
||||
:param1 2
|
||||
:param2 '((new 'static 'bfloat :data 1.0) (new 'static 'bfloat :data 1.0))
|
||||
)
|
||||
(new 'static 'idle-control-frame)
|
||||
)
|
||||
:idle-anim 3
|
||||
:notice-anim 3
|
||||
:hostile-anim 6
|
||||
:hit-anim 3
|
||||
:knocked-anim -1
|
||||
:knocked-land-anim -1
|
||||
:die-anim -1
|
||||
:die-falling-anim -1
|
||||
:victory-anim -1
|
||||
:jump-wind-up-anim -1
|
||||
:jump-in-air-anim 8
|
||||
:jump-land-anim 10
|
||||
:neck-joint 27
|
||||
:look-at-joint 28
|
||||
:bullseye-joint 28
|
||||
:notice-distance-delta (meters 10)
|
||||
:proximity-notice-distance (meters 15)
|
||||
:default-hit-points 100.0
|
||||
:gnd-collide-with (collide-spec backgnd)
|
||||
:overlaps-others-collide-with-filter (collide-spec jak bot player-list)
|
||||
:movement-gravity (meters -100)
|
||||
:friction 0.8
|
||||
:attack-shove-back (meters 3)
|
||||
:attack-shove-up (meters 2)
|
||||
:attack-mode 'shove
|
||||
:recover-gnd-collide-with (collide-spec backgnd crate obstacle hit-by-others-list pusher)
|
||||
:knocked-can-land-timeout (seconds 0.1)
|
||||
:knocked-recover-timeout (seconds 2)
|
||||
:ragdoll-blend-out-time (seconds 0.25)
|
||||
:ragdoll-rotate-velocity-mult 1.0
|
||||
:jump-height-min (meters 3)
|
||||
:jump-height-factor 0.5
|
||||
:knocked-seek-ry-clamp 2730.6667
|
||||
:knocked-soft-vxz-lo 72089.6
|
||||
:knocked-soft-vxz-hi 108134.4
|
||||
:knocked-soft-vy-lo 81920.0
|
||||
:knocked-soft-vy-hi 122880.0
|
||||
:knocked-medium-vxz-lo 147456.0
|
||||
:knocked-medium-vxz-hi 196608.0
|
||||
:knocked-medium-vy-lo 135168.0
|
||||
:knocked-medium-vy-hi 151552.0
|
||||
:knocked-hard-vxz-lo 78643.2
|
||||
:knocked-hard-vxz-hi 117964.8
|
||||
:knocked-hard-vy-lo 183500.8
|
||||
:knocked-hard-vy-hi 209715.2
|
||||
:knocked-huge-vxz-lo 164659.2
|
||||
:knocked-huge-vxz-hi 249036.8
|
||||
:knocked-huge-vy-lo 183500.8
|
||||
:knocked-huge-vy-hi 217907.2
|
||||
:knocked-yellow-vxz-lo 40960.0
|
||||
:knocked-yellow-vxz-hi 49152.0
|
||||
:knocked-yellow-vy-lo 57344.0
|
||||
:knocked-yellow-vy-hi 81920.0
|
||||
:knocked-red-vxz-lo 24576.0
|
||||
:knocked-red-vxz-hi 196608.0
|
||||
:knocked-red-vy-lo 94208.0
|
||||
:knocked-red-vy-hi 151552.0
|
||||
:knocked-blue-vxz-lo 40960.0
|
||||
:knocked-blue-vxz-hi 49152.0
|
||||
:knocked-blue-vy-lo 24576.0
|
||||
:knocked-blue-vy-hi 81920.0
|
||||
:ragdoll-info #f
|
||||
:shadow-size (meters 1)
|
||||
:shadow-max-y (meters 1)
|
||||
:shadow-min-y (meters -20)
|
||||
:shadow-locus-dist (meters 150)
|
||||
:gem-joint -1
|
||||
:gem-offset (new 'static 'sphere :r 163840.0)
|
||||
:knocked-off #t
|
||||
:callback-info #f
|
||||
:use-momentum #f
|
||||
:use-frustration #f
|
||||
:use-stop-chase #f
|
||||
:use-circling #f
|
||||
:use-pacing #f
|
||||
:walk-anim 4
|
||||
:turn-anim -1
|
||||
:run-anim 6
|
||||
:taunt-anim -1
|
||||
:run-travel-speed (meters 35)
|
||||
:run-acceleration (meters 5.8333335)
|
||||
:run-turning-acceleration (meters 100)
|
||||
:walk-travel-speed (meters 5)
|
||||
:walk-acceleration (meters 1)
|
||||
:walk-turning-acceleration (meters 100)
|
||||
:maximum-rotation-rate (degrees 720)
|
||||
:notice-nav-radius (meters 1)
|
||||
:frustration-distance (meters 8)
|
||||
:frustration-time (seconds 4)
|
||||
:blocked-time (seconds 0.3)
|
||||
:circle-dist-lo 20480.0
|
||||
:circle-dist-hi 61440.0
|
||||
:nav-mesh #f
|
||||
)
|
||||
)
|
||||
|
||||
(set! (-> *flut-racer-enemy-info* fact-defaults) *fact-info-enemy-defaults*)
|
||||
|
||||
;; WARN: Return type mismatch uint vs none.
|
||||
(defbehavior ring-hit-logic flut-racer ()
|
||||
(let* ((v1-2 (-> *game-info* sub-task-list (game-task-node wascity-leaper-race-resolution)))
|
||||
(gp-0 (if (-> v1-2 manager)
|
||||
(-> v1-2 manager manager)
|
||||
(the-as handle #f)
|
||||
)
|
||||
)
|
||||
(a1-0 (new 'stack-no-clear 'event-message-block))
|
||||
)
|
||||
(set! (-> a1-0 from) (process->ppointer self))
|
||||
(set! (-> a1-0 num-params) 0)
|
||||
(set! (-> a1-0 message) 'challenger-current-ring-ent)
|
||||
(let* ((a0-6 (the-as entity (send-event-function (handle->process gp-0) a1-0)))
|
||||
(v1-9 (if a0-6
|
||||
(-> a0-6 extra process)
|
||||
)
|
||||
)
|
||||
)
|
||||
(when v1-9
|
||||
(let ((a1-1 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> a1-1 quad) (-> self root trans quad))
|
||||
(let ((a0-11 (-> (the-as process-drawable v1-9) root quat)))
|
||||
(new 'stack-no-clear 'vector)
|
||||
(+! (-> a1-1 y) 8192.0)
|
||||
(vector-! a1-1 a1-1 (-> (the-as process-drawable v1-9) root trans))
|
||||
(when (wascity-race-ring-cleared? a0-11 a1-1)
|
||||
(sound-play "ring-pass" :vol 50)
|
||||
(send-event (handle->process gp-0) 'ring-hit 'challenger (-> self current-ring))
|
||||
(+! (-> self current-ring) 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
(defstate wait (flut-racer)
|
||||
:virtual #t
|
||||
:event enemy-event-handler
|
||||
:enter (behavior ()
|
||||
(logclear! (-> self mask) (process-mask actor-pause))
|
||||
(ja :num-func num-func-identity
|
||||
:frame-num (the float (mod (the-as uint (&-> self entity)) (the-as uint (ja-num-frames 0))))
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(ja :num! (loop!))
|
||||
)
|
||||
:code (behavior ()
|
||||
(sleep-code)
|
||||
)
|
||||
:post (behavior ()
|
||||
(if (and (nonzero? (-> self draw)) (logtest? (-> self draw status) (draw-control-status on-screen)))
|
||||
(set-time! (-> self last-draw-time))
|
||||
)
|
||||
(update-focus self)
|
||||
(ja-post)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate race (flut-racer)
|
||||
:virtual #t
|
||||
:event enemy-event-handler
|
||||
:enter (behavior ()
|
||||
(logclear! (-> self mask) (process-mask actor-pause))
|
||||
(nav-enemy-method-177 self)
|
||||
(nav-enemy-method-181 self)
|
||||
(nav-enemy-method-183 self)
|
||||
(when (zero? (-> self taskman))
|
||||
(let ((v1-12 (-> *game-info* sub-task-list (game-task-node wascity-leaper-race-resolution))))
|
||||
(set! (-> self taskman) (if (-> v1-12 manager)
|
||||
(-> v1-12 manager manager)
|
||||
(the-as handle #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if (not (-> self minimap))
|
||||
(set! (-> self minimap) (add-icon! *minimap* self (the-as uint 10) (the-as int #f) (the-as vector #t) 0))
|
||||
)
|
||||
(vector-reset! (-> self probe))
|
||||
)
|
||||
:trans (behavior ()
|
||||
(let ((a1-0 (new 'stack-no-clear 'event-message-block)))
|
||||
(set! (-> a1-0 from) (process->ppointer self))
|
||||
(set! (-> a1-0 num-params) 0)
|
||||
(set! (-> a1-0 message) 'challenger-current-ring)
|
||||
(let ((gp-0 (the-as int (send-event-function (handle->process (-> self taskman)) a1-0)))
|
||||
(a1-1 (new 'stack-no-clear 'event-message-block))
|
||||
)
|
||||
(set! (-> a1-1 from) (process->ppointer self))
|
||||
(set! (-> a1-1 num-params) 0)
|
||||
(set! (-> a1-1 message) 'target-current-ring)
|
||||
(let ((s5-0 (the-as int (send-event-function (handle->process (-> self taskman)) a1-1))))
|
||||
(when (and gp-0 s5-0)
|
||||
(when (time-elapsed? (-> self last-speed-update) (seconds 4))
|
||||
(let ((s4-0 (-> self nav)))
|
||||
(set! (-> s4-0 target-speed)
|
||||
(* 143360.0 (rand-vu-float-range 0.75 1.0) (lerp-scale 1.225 0.5 (the float (- gp-0 s5-0)) -2.0 2.0))
|
||||
)
|
||||
)
|
||||
0
|
||||
(set-time! (-> self last-speed-update))
|
||||
)
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(let ((f26-0 0.0)
|
||||
(f30-0 0.0)
|
||||
(f28-0 0.0)
|
||||
)
|
||||
(let ((gp-0 22))
|
||||
(let ((v1-2 (ja-group)))
|
||||
(cond
|
||||
((and v1-2 (= v1-2 flut-wild-idle-ja))
|
||||
(set! gp-0 60)
|
||||
)
|
||||
((let ((v1-9 (ja-group)))
|
||||
(and v1-9 (or (= v1-9 flut-wild-jump-ja) (= v1-9 flut-wild-jump-loop-ja)))
|
||||
)
|
||||
(ja-channel-push! 1 (seconds 0.08))
|
||||
(ja-no-eval :group! flut-wild-run-squash-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-39 (ja-group)))
|
||||
(set! f28-0
|
||||
(cond
|
||||
((and v1-39 (= v1-39 flut-wild-run-squash-ja))
|
||||
(ja-channel-set! 3)
|
||||
(set! f30-0 1.0)
|
||||
1.0
|
||||
)
|
||||
(else
|
||||
(let ((v1-47 (ja-group)))
|
||||
(cond
|
||||
((and v1-47 (= v1-47 flut-wild-walk-ja))
|
||||
(set! f26-0 (ja-frame-num 0))
|
||||
(set! f30-0 (-> self skel root-channel 1 frame-interp (-> self skel active-frame-interp)))
|
||||
(-> self skel root-channel 2 frame-interp (-> self skel active-frame-interp))
|
||||
)
|
||||
(else
|
||||
(ja-channel-push! 3 (the-as time-frame gp-0))
|
||||
f28-0
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(ja-no-eval :group! flut-wild-walk-ja :num! (loop!) :dist 20480.0 :frame-num f26-0)
|
||||
(ja-no-eval :chan 1
|
||||
:group! flut-wild-jog-ja
|
||||
:num! (identity f26-0)
|
||||
:frame-interp0 f30-0
|
||||
:frame-interp1 f30-0
|
||||
:dist 47104.0
|
||||
)
|
||||
(ja-no-eval :chan 2
|
||||
:group! flut-wild-run-ja
|
||||
:num! (identity f26-0)
|
||||
:frame-interp0 f28-0
|
||||
:frame-interp1 f28-0
|
||||
:dist 53248.0
|
||||
)
|
||||
(until #f
|
||||
(suspend)
|
||||
(let ((f24-0 (lerp-scale 0.0 1.0 (-> self nav state speed) 36864.0 40960.0))
|
||||
(f26-1 (lerp-scale 0.0 1.0 (-> self nav state speed) 49152.0 77824.0))
|
||||
)
|
||||
(set! f30-0 (seek f30-0 f24-0 (* 4.0 (seconds-per-frame))))
|
||||
(set! f28-0 (seek f28-0 f26-1 (seconds-per-frame)))
|
||||
)
|
||||
(ja :chan 1 :frame-interp0 f30-0 :frame-interp1 f30-0)
|
||||
(ja :chan 2 :frame-interp0 f28-0 :frame-interp1 f28-0)
|
||||
(let* ((f0-17 (* (current-cycle-distance (-> self skel)) (-> self root scale x)))
|
||||
(f0-19 (/ (* 58.0 (-> self nav state speed)) (* 60.0 f0-17)))
|
||||
)
|
||||
(ja :num! (loop! f0-19))
|
||||
)
|
||||
(ja :chan 1 :num! (chan 0))
|
||||
(ja :chan 2 :num! (chan 0))
|
||||
)
|
||||
)
|
||||
#f
|
||||
)
|
||||
:post (behavior ()
|
||||
(let ((a1-0 (new 'stack-no-clear 'event-message-block)))
|
||||
(set! (-> a1-0 from) (process->ppointer self))
|
||||
(set! (-> a1-0 num-params) 0)
|
||||
(set! (-> a1-0 message) 'challenger-current-ring-ent)
|
||||
(let ((a0-5 (the-as entity-actor (send-event-function (handle->process (-> self taskman)) a1-0)))
|
||||
(gp-0 (new 'stack-no-clear 'vector))
|
||||
)
|
||||
(b! (not a0-5) cfg-20 :delay (nop!))
|
||||
(set! (-> gp-0 quad) (-> a0-5 extra trans quad))
|
||||
(let ((f0-0 (vector-vector-xz-distance gp-0 (-> self root trans)))
|
||||
(f30-0 (- (-> gp-0 y) (-> self root trans y)))
|
||||
)
|
||||
(let ((a0-10 (-> self nav state))
|
||||
(v1-9 gp-0)
|
||||
)
|
||||
(logclear! (-> a0-10 flags) (nav-state-flag directional-mode))
|
||||
(logior! (-> a0-10 flags) (nav-state-flag target-poly-dirty))
|
||||
(set! (-> a0-10 target-pos quad) (-> v1-9 quad))
|
||||
)
|
||||
0
|
||||
(when (and (< f0-0 40960.0) (< 24576.0 (+ -8192.0 f30-0)))
|
||||
(let ((a0-13 (vector-z-quaternion! (new 'stack-no-clear 'vector) (-> self root quat))))
|
||||
(vector+! gp-0 gp-0 (vector-normalize! a0-13 40960.0))
|
||||
)
|
||||
(set! (-> gp-0 y) (-> self root trans y))
|
||||
(set! (-> self enemy-info jump-height-min) (* 0.8 f30-0))
|
||||
(set! (-> self enemy-flags)
|
||||
(the-as enemy-flag (logior (enemy-flag jump-check-blocked) (-> self enemy-flags)))
|
||||
)
|
||||
(send-event self 'jump 0 gp-0)
|
||||
#t
|
||||
(b! #t cfg-22 :delay (nop!))
|
||||
(the-as none 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(ring-hit-logic)
|
||||
(b! #t cfg-21 :delay (nop!))
|
||||
(label cfg-20)
|
||||
0
|
||||
(label cfg-21)
|
||||
(nav-enemy-travel-post)
|
||||
(label cfg-22)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate jump (flut-racer)
|
||||
:virtual #t
|
||||
:enter (behavior ()
|
||||
(let ((t9-0 (-> (method-of-type nav-enemy jump) enter)))
|
||||
(if t9-0
|
||||
(t9-0)
|
||||
)
|
||||
)
|
||||
(logclear! (-> self focus-status) (focus-status dangerous))
|
||||
)
|
||||
:post (behavior ()
|
||||
(ring-hit-logic)
|
||||
(let ((t9-1 (-> (method-of-type nav-enemy jump) post)))
|
||||
(if t9-1
|
||||
((the-as (function none) t9-1))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate halt (flut-racer)
|
||||
:virtual #t
|
||||
:code sleep-code
|
||||
)
|
||||
|
||||
(defmethod jump-land-anim ((this flut-racer) (arg0 enemy-jump-info))
|
||||
#f
|
||||
)
|
||||
|
||||
(defmethod jump-wind-up-anim ((this flut-racer) (arg0 enemy-jump-info))
|
||||
#f
|
||||
)
|
||||
|
||||
(defmethod go-directed2 ((this flut-racer))
|
||||
(go (method-of-object this race))
|
||||
)
|
||||
|
||||
(defmethod enemy-method-108 ((this flut-racer) (arg0 process-focusable))
|
||||
#t
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch symbol vs vector.
|
||||
(defmethod nav-enemy-method-167 ((this flut-racer))
|
||||
(the-as vector #f)
|
||||
)
|
||||
|
||||
(defmethod get-damage-from-attack ((this flut-racer) (arg0 object) (arg1 event-message-block))
|
||||
0.0
|
||||
)
|
||||
|
||||
(defmethod go-idle2 ((this flut-racer))
|
||||
(go (method-of-object this wait))
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch object vs symbol.
|
||||
;; WARN: disable def twice: 5. This may happen when a cond (no else) is nested inside of another conditional, but it should be rare.
|
||||
(defmethod jump-anim-handler ((this flut-racer) (arg0 int) (arg1 enemy-jump-info))
|
||||
(let ((v1-0 arg0))
|
||||
(the-as symbol (cond
|
||||
((= v1-0 4)
|
||||
(when (not (focus-test? this dangerous))
|
||||
(let ((v0-0 (the-as object (logior (-> this focus-status) (focus-status dangerous)))))
|
||||
(set! (-> this focus-status) (the-as focus-status v0-0))
|
||||
v0-0
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
((method-of-type nav-enemy jump-anim-handler) this arg0 arg1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod event-handler ((this flut-racer) (arg0 process) (arg1 int) (arg2 symbol) (arg3 event-message-block))
|
||||
(case arg2
|
||||
(('trigger)
|
||||
(if (and (-> this next-state) (= (-> this next-state name) 'wait))
|
||||
(go (method-of-object this race))
|
||||
)
|
||||
)
|
||||
(('touch)
|
||||
(send-shoves (-> this root) arg0 (the-as touching-shapes-entry (-> arg3 param 0)) 0.7 6144.0 16384.0)
|
||||
)
|
||||
(('stop)
|
||||
(go (method-of-object this halt))
|
||||
)
|
||||
(else
|
||||
((method-of-type nav-enemy event-handler) this arg0 arg1 arg2 arg3)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod nav-enemy-method-187 ((this flut-racer))
|
||||
(local-vars (v1-26 float) (v1-40 float))
|
||||
(rlet ((acc :class vf)
|
||||
(vf0 :class vf)
|
||||
(vf1 :class vf)
|
||||
(vf2 :class vf)
|
||||
)
|
||||
(init-vf0-vector)
|
||||
(let ((t9-0 (method-of-type nav-enemy nav-enemy-method-187)))
|
||||
(t9-0 this)
|
||||
)
|
||||
(let ((s5-0 (new 'stack 'traffic-danger-info)))
|
||||
(set! (-> s5-0 danger-type) (the-as uint 8))
|
||||
(set! (-> s5-0 sphere quad) (-> this root trans quad))
|
||||
(set! (-> s5-0 sphere r) 122880.0)
|
||||
(copy-nav-state-vel! this (-> s5-0 velocity))
|
||||
(vector-normalize! (-> s5-0 velocity) 122880.0)
|
||||
(set! (-> s5-0 danger-level) 0.5)
|
||||
(set! (-> s5-0 notify-radius) 491520.0)
|
||||
(set! (-> s5-0 decay-rate) 0.0)
|
||||
;; og:preserve-this not-yet-implemented
|
||||
; (add-danger *traffic-engine* s5-0)
|
||||
)
|
||||
(let ((s5-1 (new 'stack-no-clear 'vector)))
|
||||
(vector-normalize!
|
||||
(vector-z-quaternion! s5-1 (-> this root quat))
|
||||
(* (-> this nav target-speed) (seconds-per-frame) (seconds-per-frame))
|
||||
)
|
||||
(vector+! s5-1 s5-1 (-> this root trans))
|
||||
(set! (-> s5-1 w) 16384.0)
|
||||
(let ((s4-1 (new 'stack-no-clear 'array 'collide-shape 384)))
|
||||
(countdown (s3-0 (fill-actor-list-for-box *actor-hash* (the-as bounding-box s5-1) s4-1 384))
|
||||
(let* ((s2-0 (-> s4-1 s3-0))
|
||||
(v1-21 (if (type? s2-0 collide-shape)
|
||||
s2-0
|
||||
)
|
||||
)
|
||||
)
|
||||
(when v1-21
|
||||
(let* ((s1-0 (-> v1-21 process))
|
||||
(s2-1 (if (type? s1-0 process-focusable)
|
||||
s1-0
|
||||
)
|
||||
)
|
||||
)
|
||||
(when s2-1
|
||||
(when (and (!= *target* s2-1) (type? s2-1 civilian))
|
||||
(let ((v1-25 (vector-! (new 'stack-no-clear 'vector) (-> s2-1 root trans) s5-1)))
|
||||
0.0
|
||||
(.lvf vf1 (&-> v1-25 quad))
|
||||
)
|
||||
(.add.w.vf vf2 vf0 vf0 :mask #b1)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.mul.x.vf acc vf2 vf1 :mask #b1)
|
||||
(.add.mul.y.vf acc vf2 vf1 acc :mask #b1)
|
||||
(.add.mul.z.vf vf1 vf2 vf1 acc :mask #b1)
|
||||
(.mov v1-26 vf1)
|
||||
(let ((f0-10 v1-26)
|
||||
(f1-2 (-> s5-1 w))
|
||||
)
|
||||
(when (>= (* f1-2 f1-2) f0-10)
|
||||
(set! (-> this enemy-info attack-damage) 15)
|
||||
(send-attack this s2-1 (the-as touching-shapes-entry #f) (-> this attack-id))
|
||||
(set! (-> this enemy-info attack-damage) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let* ((s3-1 *target*)
|
||||
(s4-2 (if (type? s3-1 process-focusable)
|
||||
s3-1
|
||||
)
|
||||
)
|
||||
)
|
||||
(when (and s4-2 (< (vector-vector-distance (get-trans s4-2 0) s5-1) (-> s5-1 w)))
|
||||
(when (and (!= *target* s4-2) (type? s4-2 civilian))
|
||||
(let ((v1-39 (vector-! (new 'stack-no-clear 'vector) (-> s4-2 control trans) s5-1)))
|
||||
0.0
|
||||
(.lvf vf1 (&-> v1-39 quad))
|
||||
)
|
||||
(.add.w.vf vf2 vf0 vf0 :mask #b1)
|
||||
(.mul.vf vf1 vf1 vf1)
|
||||
(.mul.x.vf acc vf2 vf1 :mask #b1)
|
||||
(.add.mul.y.vf acc vf2 vf1 acc :mask #b1)
|
||||
(.add.mul.z.vf vf1 vf2 vf1 acc :mask #b1)
|
||||
(.mov v1-40 vf1)
|
||||
(let ((f0-13 v1-40)
|
||||
(f1-6 (-> s5-1 w))
|
||||
)
|
||||
(when (>= (* f1-6 f1-6) f0-13)
|
||||
(set! (-> this enemy-info attack-damage) 15)
|
||||
(send-attack this s4-2 (the-as touching-shapes-entry #f) (-> this attack-id))
|
||||
(set! (-> this enemy-info attack-damage) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod init-enemy! ((this flut-racer))
|
||||
(initialize-skeleton
|
||||
this
|
||||
(the-as skeleton-group (art-group-get-by-name *level* "skel-flut-racer" (the-as (pointer level) #f)))
|
||||
(the-as pair 0)
|
||||
)
|
||||
(init-enemy-defaults! this *flut-racer-enemy-info*)
|
||||
(let ((v1-5 (-> this neck)))
|
||||
(set! (-> v1-5 up) (the-as uint 1))
|
||||
(set! (-> v1-5 nose) (the-as uint 2))
|
||||
(set! (-> v1-5 ear) (the-as uint 0))
|
||||
(set-vector! (-> v1-5 twist-max) 11832.889 11832.889 0.0 1.0)
|
||||
(set! (-> v1-5 ignore-angle) 30947.555)
|
||||
)
|
||||
(set! (-> this current-ring) (the-as uint 0))
|
||||
(logclear! (-> this mask) (process-mask enemy))
|
||||
(logior! (-> this mask) (process-mask bot))
|
||||
(logclear! (-> this enemy-flags) (enemy-flag vulnerable vulnerable-backup))
|
||||
(let ((v1-13 (-> this nav)))
|
||||
(set! (-> v1-13 sphere-mask) (the-as uint #x1000fe))
|
||||
)
|
||||
0
|
||||
(let ((v1-15 (-> this nav)))
|
||||
(set! (-> v1-15 nav-cull-radius) 143360.0)
|
||||
)
|
||||
0
|
||||
(set! (-> this minimap) #f)
|
||||
(flut-color-from-index (flut-random-color-index))
|
||||
(let ((s5-2 (process-spawn
|
||||
manipy
|
||||
:init manipy-init
|
||||
(-> this root trans)
|
||||
(-> this entity)
|
||||
(art-group-get-by-name *level* "skel-monk" (the-as (pointer level) #f))
|
||||
'collide-shape-moving
|
||||
0
|
||||
:name "manipy"
|
||||
:to this
|
||||
:stack-size #x20000
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(when s5-2
|
||||
(let* ((v1-24 (res-lump-value
|
||||
(-> this entity)
|
||||
'extra-id
|
||||
uint128
|
||||
:default (the-as uint128 (rand-vu-int-range 0 5))
|
||||
:time -1000000000.0
|
||||
)
|
||||
)
|
||||
(gp-2 (cond
|
||||
((zero? v1-24)
|
||||
4171
|
||||
)
|
||||
((= (the-as uint v1-24) 1)
|
||||
8357
|
||||
)
|
||||
((= (the-as uint v1-24) 2)
|
||||
#x4113
|
||||
)
|
||||
((= (the-as uint v1-24) 3)
|
||||
#x8225
|
||||
)
|
||||
((= (the-as uint v1-24) 4)
|
||||
#x10407
|
||||
)
|
||||
((= (the-as uint v1-24) 5)
|
||||
#x20825
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(send-event (ppointer->process s5-2) 'no-actor-pause)
|
||||
(send-event (ppointer->process s5-2) 'segment 0 -8)
|
||||
(send-event (ppointer->process s5-2) 'segment (* gp-2 8) 0)
|
||||
)
|
||||
(send-event (ppointer->process s5-2) 'anim-mode 'clone-anim)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch collide-shape-moving vs none.
|
||||
(defmethod init-enemy-collision! ((this flut-racer))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving this (collide-list-enum hit-by-others))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction) cshape-reaction-default)
|
||||
(set! (-> s5-0 no-reaction)
|
||||
(the-as (function collide-shape-moving collide-query vector vector object) nothing)
|
||||
)
|
||||
(let ((s4-0 (new 'process 'collide-shape-prim-group s5-0 (the-as uint 1) 0)))
|
||||
(set! (-> s5-0 total-prims) (the-as uint 2))
|
||||
(set! (-> s4-0 prim-core collide-as) (collide-spec bot))
|
||||
(set! (-> s4-0 prim-core collide-with)
|
||||
(collide-spec backgnd jak crate enemy obstacle vehicle-sphere hit-by-others-list player-list pusher)
|
||||
)
|
||||
(set! (-> s4-0 prim-core action) (collide-action solid no-standon))
|
||||
(set-vector! (-> s4-0 local-sphere) 0.0 8192.0 0.0 4915.2)
|
||||
(set! (-> s5-0 root-prim) s4-0)
|
||||
)
|
||||
(let ((v1-12 (new 'process 'collide-shape-prim-sphere s5-0 (the-as uint 0))))
|
||||
(set! (-> v1-12 prim-core collide-as) (collide-spec bot))
|
||||
(set! (-> v1-12 prim-core collide-with)
|
||||
(collide-spec backgnd jak crate enemy obstacle vehicle-sphere hit-by-others-list player-list pusher)
|
||||
)
|
||||
(set! (-> v1-12 prim-core action) (collide-action solid no-standon))
|
||||
(set-vector! (-> v1-12 local-sphere) 0.0 8192.0 0.0 4915.2)
|
||||
)
|
||||
(set! (-> s5-0 nav-radius) 5324.8)
|
||||
(let ((v1-14 (-> s5-0 root-prim)))
|
||||
(set! (-> s5-0 backup-collide-as) (-> v1-14 prim-core collide-as))
|
||||
(set! (-> s5-0 backup-collide-with) (-> v1-14 prim-core collide-with))
|
||||
)
|
||||
(set! (-> this root) s5-0)
|
||||
)
|
||||
(none)
|
||||
)
|
||||
|
||||
@@ -213,8 +213,7 @@
|
||||
(set! (-> self count-lock) #t)
|
||||
(+! (-> *game-info* flut-count) 1)
|
||||
)
|
||||
;; og:preserve-this not-yet-implemented check
|
||||
(if (and (nonzero? *minimap*) (not (-> self minimap)))
|
||||
(if (not (-> self minimap))
|
||||
(set! (-> self minimap) (add-icon! *minimap* self (the-as uint 11) (the-as int #f) (the-as vector #t) 0))
|
||||
)
|
||||
(change-parent self *entity-pool*)
|
||||
@@ -601,7 +600,7 @@
|
||||
)
|
||||
)
|
||||
(set! (-> self sound)
|
||||
(new 'process 'ambient-sound (static-sound-spec "zoom-teleport" :group 1 :fo-max 30) (-> self root trans) 0.0)
|
||||
(new 'process 'ambient-sound (static-sound-spec "zoom-teleport" :group 0 :fo-max 30) (-> self root trans) 0.0)
|
||||
)
|
||||
(set! (-> self draw light-index) (the-as uint 30))
|
||||
(logior! (-> self mask) (process-mask crate))
|
||||
|
||||
@@ -766,7 +766,7 @@
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch symbol vs object.
|
||||
(defbehavior target-flut-hit-ground-anim target ()
|
||||
(defbehavior target-flut-hit-ground-anim target ((arg0 symbol))
|
||||
(let ((v1-2 (ja-group)))
|
||||
(cond
|
||||
((and v1-2 (= v1-2 jakb-flut-jump-loop-ja))
|
||||
@@ -2254,9 +2254,7 @@
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(let ((t9-0 target-flut-hit-ground-anim))
|
||||
(t9-0)
|
||||
)
|
||||
(target-flut-hit-ground-anim #f)
|
||||
(go target-flut-stance)
|
||||
)
|
||||
:post target-flut-post
|
||||
@@ -3211,7 +3209,91 @@
|
||||
)
|
||||
)
|
||||
(('bot)
|
||||
;; (L138)
|
||||
((lambda :behavior target
|
||||
()
|
||||
(local-vars (v0-1 uint))
|
||||
(set! (-> self trans-hook) #f)
|
||||
(b! (-> self flut as-daxter?) cfg-40 :delay (nop!))
|
||||
(let ((gp-0 0))
|
||||
(while (not (if (and (< (target-move-dist (-> *TARGET-bank* stuck-time)) (-> *TARGET-bank* stuck-distance)) (< 30 gp-0))
|
||||
#t
|
||||
)
|
||||
)
|
||||
(let ((v1-4 (ja-group)))
|
||||
(if (not (and v1-4 (= v1-4 jakb-flut-jump-loop-ja)))
|
||||
(ja-no-eval :group! jakb-flut-jump-loop-ja :num! (loop!) :frame-num 0.0)
|
||||
)
|
||||
)
|
||||
(+! gp-0 (- (current-time) (-> self clock old-frame-counter)))
|
||||
(when (-> self control unknown-spool-anim00)
|
||||
(set! v0-1 (the-as uint #f))
|
||||
(goto cfg-39)
|
||||
)
|
||||
(suspend)
|
||||
(ja :num! (loop!))
|
||||
)
|
||||
(if (or (> gp-0 0) (let ((v1-38 (ja-group)))
|
||||
(and v1-38 (or (= v1-38 jakb-flut-jump-ja) (= v1-38 jakb-flut-jump-loop-ja)))
|
||||
)
|
||||
)
|
||||
(target-flut-hit-ground-anim #f)
|
||||
)
|
||||
)
|
||||
(ja-channel-push! 1 (seconds 0.075))
|
||||
(label cfg-33)
|
||||
(ja-no-eval :group! jakb-flut-idle-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(when (-> self control unknown-spool-anim00)
|
||||
(set! v0-1 (the-as uint #f))
|
||||
(goto cfg-39)
|
||||
)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
(b! (not #f) cfg-33 :delay (set! v0-1 (the-as uint #f)))
|
||||
(label cfg-39)
|
||||
(b! #t cfg-78 :delay (nop!))
|
||||
(label cfg-40)
|
||||
(let ((gp-1 0))
|
||||
(while (not (if (and (< (target-move-dist (-> *TARGET-bank* stuck-time)) (-> *TARGET-bank* stuck-distance)) (< 30 gp-1))
|
||||
#t
|
||||
)
|
||||
)
|
||||
(let ((v1-73 (ja-group)))
|
||||
(if (not (and v1-73 (= v1-73 jakb-mech-death-a-ja)))
|
||||
(ja-no-eval :group! jakb-mech-death-a-ja :num! (loop!) :frame-num 0.0)
|
||||
)
|
||||
)
|
||||
(+! gp-1 (- (current-time) (-> self clock old-frame-counter)))
|
||||
(if (-> self control unknown-spool-anim00)
|
||||
(return (the-as object #f))
|
||||
)
|
||||
(suspend)
|
||||
(ja :num! (loop!))
|
||||
)
|
||||
(if (or (> gp-1 0) (let ((v1-107 (ja-group)))
|
||||
(and v1-107 (or (= v1-107 jakb-mech-get-on-ja) (= v1-107 jakb-mech-death-a-ja)))
|
||||
)
|
||||
)
|
||||
(target-flut-hit-ground-anim #f)
|
||||
)
|
||||
)
|
||||
(ja-channel-push! 1 (seconds 0.075))
|
||||
(until #f
|
||||
(ja-no-eval :group! jakb-mech-punch-u-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(if (-> self control unknown-spool-anim00)
|
||||
(return (the-as object #f))
|
||||
)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
(set! v0-1 (the-as uint #f))
|
||||
(label cfg-78)
|
||||
v0-1
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
(set! (-> self control mod-surface) *neutral-mods*)
|
||||
|
||||
@@ -2363,7 +2363,7 @@
|
||||
:merge-count 2
|
||||
:radius 3276.8
|
||||
:duration 60.0
|
||||
:sound (static-sound-spec "stretched-zap" :group 1)
|
||||
:sound (static-sound-spec "stretched-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
:radius 3276.8
|
||||
:duration 45.0
|
||||
:duration-rand 60.0
|
||||
:sound (static-sound-spec "stretched-zap" :group 1)
|
||||
:sound (static-sound-spec "stretched-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
:merge-count 2
|
||||
:radius 3276.8
|
||||
:duration 60.0
|
||||
:sound (static-sound-spec "stretched-zap" :group 1)
|
||||
:sound (static-sound-spec "stretched-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -974,8 +974,8 @@
|
||||
(when (> v1-12 0)
|
||||
(cond
|
||||
((< v1-12 (the-as int (-> this num-dying-vehicles)))
|
||||
(sound-play-by-spec (static-sound-spec "vehicle-explode" :group 1) (new-sound-id) (the-as vector #t))
|
||||
(sound-play-by-spec (static-sound-spec "vehicle-explo-b" :group 1) (new-sound-id) (the-as vector #t))
|
||||
(sound-play-by-spec (static-sound-spec "vehicle-explode" :group 0) (new-sound-id) (the-as vector #t))
|
||||
(sound-play-by-spec (static-sound-spec "vehicle-explo-b" :group 0) (new-sound-id) (the-as vector #t))
|
||||
(+! (-> this num-dying-vehicles) -1)
|
||||
)
|
||||
((< v1-12 (the-as int (+ (-> this num-dying-guards) (-> this num-dying-vehicles))))
|
||||
|
||||
@@ -21,7 +21,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype gun (process-drawable)
|
||||
((parent (pointer target) :override)
|
||||
((self gun :override)
|
||||
(parent (pointer target) :override)
|
||||
(control control-info :overlay-at root)
|
||||
(shadow-backup shadow-geo :offset 208)
|
||||
(read-scale symbol)
|
||||
|
||||
@@ -1202,7 +1202,7 @@ gun
|
||||
:init-specs ((:texture (shell-casing-01 level-default-sprite))
|
||||
(:birth-func 'birth-func-texture-group)
|
||||
(:num 1.0)
|
||||
(:sound (static-sound-spec "blue-gun-shell" :group 1))
|
||||
(:sound (static-sound-spec "blue-gun-shell" :group 0))
|
||||
(:scale-x (meters 0.35))
|
||||
(:rot-z (degrees 0) (degrees 360))
|
||||
(:scale-y :copy scale-x)
|
||||
@@ -1229,7 +1229,7 @@ gun
|
||||
:init-specs ((:texture (shell-casing-01 level-default-sprite))
|
||||
(:birth-func 'birth-func-texture-group)
|
||||
(:num 1.0)
|
||||
(:sound (static-sound-spec "blue-gun-shell" :group 1))
|
||||
(:sound (static-sound-spec "blue-gun-shell" :group 0))
|
||||
(:scale-x (meters 0.35))
|
||||
(:rot-z (degrees 30) (degrees 120))
|
||||
(:scale-y :copy scale-x)
|
||||
@@ -1254,7 +1254,7 @@ gun
|
||||
)
|
||||
|
||||
(defpart 241
|
||||
:init-specs ((:sound (static-sound-spec "blue-gun-shell" :group 1))
|
||||
:init-specs ((:sound (static-sound-spec "blue-gun-shell" :group 0))
|
||||
(:vel-x (meters 0))
|
||||
(:vel-y (meters 0))
|
||||
(:vel-z (meters 0))
|
||||
@@ -1266,7 +1266,7 @@ gun
|
||||
)
|
||||
|
||||
(defpart 242
|
||||
:init-specs ((:sound (static-sound-spec "blue-gun-shell" :group 1)) (:fade-a -0.512))
|
||||
:init-specs ((:sound (static-sound-spec "blue-gun-shell" :group 0)) (:fade-a -0.512))
|
||||
)
|
||||
|
||||
(defun check-shell-level1 ((arg0 sparticle-system) (arg1 sparticle-cpuinfo) (arg2 vector))
|
||||
@@ -1394,7 +1394,7 @@ gun
|
||||
(defpart 244
|
||||
:init-specs ((:texture (glow level-default-sprite))
|
||||
(:num 1.0)
|
||||
(:sound (static-sound-spec "blue-gun-rico" :group 1))
|
||||
(:sound (static-sound-spec "blue-gun-rico" :group 0))
|
||||
(:scale-x (meters 3) (meters 1))
|
||||
(:rot-x (degrees 2.25))
|
||||
(:rot-z (degrees 0) (degrees 3600))
|
||||
|
||||
@@ -429,18 +429,9 @@
|
||||
(defstate hidden (gun)
|
||||
:virtual #t
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(if (not (focus-test?
|
||||
(the-as process-focusable (if v1-0
|
||||
(the-as process-focusable (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
)
|
||||
(go-virtual idle)
|
||||
)
|
||||
)
|
||||
(if (not (focus-test? (ppointer->process (-> self parent)) in-head))
|
||||
(go-virtual idle)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-set! 0)
|
||||
@@ -457,7 +448,7 @@
|
||||
(set! (-> self gun-type) (-> self parent 0 game gun-type))
|
||||
(let ((a0-0 (ppointer->process (-> self parent))))
|
||||
(cond
|
||||
((focus-test? (the-as process-focusable a0-0) in-head)
|
||||
((focus-test? a0-0 in-head)
|
||||
(go-virtual hidden)
|
||||
)
|
||||
((nonzero? (-> self parent 0 gun gun-type))
|
||||
@@ -513,23 +504,13 @@
|
||||
)
|
||||
:trans (behavior ()
|
||||
(local-vars (a0-14 object))
|
||||
(let ((v1-0 (ppointer->process (-> self parent)))
|
||||
(a0-1 (-> self parent))
|
||||
)
|
||||
(let ((v1-0 (ppointer->process (-> self parent))))
|
||||
(cond
|
||||
((focus-test?
|
||||
(the-as process-focusable (if a0-1
|
||||
(the-as process-focusable (-> a0-1 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
((focus-test? (ppointer->process (-> self parent)) in-head)
|
||||
(go-virtual hidden)
|
||||
)
|
||||
((and (= (-> self parent 0 gun gun-type) (pickup-type none))
|
||||
(or (not (-> (the-as process-focusable v1-0) skel top-anim frame-group))
|
||||
(!= (-> (the-as process-focusable v1-0) skel top-anim interp) 1.0)
|
||||
)
|
||||
(or (not (-> v1-0 skel top-anim frame-group)) (!= (-> v1-0 skel top-anim interp) 1.0))
|
||||
)
|
||||
(go-virtual idle)
|
||||
)
|
||||
@@ -648,11 +629,7 @@
|
||||
("jakb-gun-blue-fire-2" . "gun-blue-fire-2")
|
||||
)
|
||||
)
|
||||
(v1-156 (-> self parent))
|
||||
(s4-0 (if v1-156
|
||||
(the-as process-focusable (-> v1-156 0 self))
|
||||
)
|
||||
)
|
||||
(s4-0 (ppointer->process (-> self parent)))
|
||||
)
|
||||
(until #f
|
||||
(let* ((v1-160 (-> s4-0 skel top-anim frame-group))
|
||||
@@ -800,12 +777,7 @@
|
||||
)
|
||||
:post (behavior ()
|
||||
(gun-post)
|
||||
(let* ((v1-0 (-> self parent))
|
||||
(gp-0 (if v1-0
|
||||
(the-as process-drawable (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((gp-0 (ppointer->process (-> self parent))))
|
||||
(let ((s5-0
|
||||
(and (-> (the-as target gp-0) skel top-anim frame-group)
|
||||
(not (or (focus-test? (the-as target gp-0) pilot)
|
||||
|
||||
@@ -7,3 +7,510 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(define *indax-hang-walk-mods* (new 'static 'surface
|
||||
:name 'run
|
||||
:turnv 131072.0
|
||||
:turnvf 30.0
|
||||
:turnvv 524288.0
|
||||
:turnvvf 30.0
|
||||
:tiltv 65536.0
|
||||
:tiltvf 150.0
|
||||
:tiltvv 262144.0
|
||||
:tiltvvf 15.0
|
||||
:transv-max 16384.0
|
||||
:target-speed 16384.0
|
||||
:seek0 1.0
|
||||
:seek90 1.0
|
||||
:seek180 1.0
|
||||
:fric 1.0
|
||||
:nonlin-fric-dist 1.0
|
||||
:slip-factor 1.0
|
||||
:slide-factor 1.0
|
||||
:slope-up-factor 1.0
|
||||
:slope-down-factor 1.0
|
||||
:slope-slip-angle 1.0
|
||||
:impact-fric 1.0
|
||||
:bend-factor 1.0
|
||||
:bend-speed 1.0
|
||||
:alignv 1.0
|
||||
:slope-up-traction 1.0
|
||||
:align-speed 1.0
|
||||
:flags (surface-flag gun-off gun-fast-exit)
|
||||
)
|
||||
)
|
||||
|
||||
(define *indax-hang-dodge-mods* (new 'static 'surface
|
||||
:name 'run
|
||||
:tiltv 65536.0
|
||||
:tiltvf 150.0
|
||||
:tiltvv 262144.0
|
||||
:tiltvvf 15.0
|
||||
:fric 1.0
|
||||
:nonlin-fric-dist 1.0
|
||||
:slip-factor 1.0
|
||||
:slide-factor 1.0
|
||||
:slope-up-factor 1.0
|
||||
:slope-down-factor 1.0
|
||||
:slope-slip-angle 1.0
|
||||
:impact-fric 1.0
|
||||
:bend-factor 1.0
|
||||
:bend-speed 1.0
|
||||
:slope-up-traction 1.0
|
||||
:flags (surface-flag gun-off gun-fast-exit)
|
||||
)
|
||||
)
|
||||
|
||||
(let ((v1-3 (copy *attack-mods* 'loading-level)))
|
||||
(set! (-> v1-3 flags) (surface-flag attack spin gun-off gun-fast-exit))
|
||||
(set! (-> v1-3 target-speed) 16384.0)
|
||||
(set! (-> v1-3 transv-max) 16384.0)
|
||||
(set! (-> v1-3 seek90) 0.0)
|
||||
(set! (-> v1-3 seek180) 0.0)
|
||||
(set! *indax-hang-attack-mods* v1-3)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang (target)
|
||||
:event (behavior ((proc process) (argc int) (message symbol) (block event-message-block))
|
||||
(if (and (= message 'change-mode) (= (-> block param 0) 'hang))
|
||||
#f
|
||||
(target-indax-handler proc argc message block)
|
||||
)
|
||||
)
|
||||
:enter (behavior ()
|
||||
(set-time! (-> self state-time))
|
||||
(set! (-> self control dynam gravity-length) (- (-> self control standard-dynamics gravity-length)))
|
||||
(when (not (logtest? (target-flags tf27) (-> self target-flags)))
|
||||
(set-time! (-> self indax indax-hang-start-time))
|
||||
(set-setting! 'string-max-length 'low (meters 4) 0)
|
||||
(set-setting! 'string-min-length 'low (meters 4) 0)
|
||||
(let ((a0-4 (-> self current-level)))
|
||||
(case (if a0-4
|
||||
(-> a0-4 info taskname)
|
||||
)
|
||||
(('volcano)
|
||||
(set-setting! 'string-max-height 'low (meters 1.5) 0)
|
||||
(set-setting! 'string-min-height 'low (meters 1.5) 0)
|
||||
)
|
||||
(else
|
||||
(format #t "definitely hitting this code~%")
|
||||
(set-setting! 'string-max-height 'low (meters -1.4) 0)
|
||||
(set-setting! 'string-min-height 'low (meters -4.1) 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set-setting! 'fov 'abs (degrees 84.0) 0)
|
||||
(set-setting! 'head-offset 'abs (meters 1) 0)
|
||||
(set-setting! 'foot-offset 'abs (meters -1) 0)
|
||||
(set-setting! 'target-height 'abs (meters 1.5) 0)
|
||||
(logior! (-> self target-flags) (target-flags tf26 tf27))
|
||||
)
|
||||
)
|
||||
:exit (behavior ()
|
||||
(when (not (or (and (-> self next-state)
|
||||
(begin (-> self next-state name) (state-type? (-> self next-state) 'target-indax-hang))
|
||||
)
|
||||
(and (-> self next-state) (= (-> self next-state name) 'target-indax-hit))
|
||||
)
|
||||
)
|
||||
(logclear! (-> self target-flags) (target-flags tf26 tf27))
|
||||
(set! (-> self control dynam gravity-max) (-> self control standard-dynamics gravity-max))
|
||||
(set! (-> self control dynam gravity-length) (-> self control standard-dynamics gravity-length))
|
||||
(target-indax-reset)
|
||||
)
|
||||
(target-indax-exit)
|
||||
)
|
||||
:code nothing
|
||||
:post (behavior ()
|
||||
(target-indax-post)
|
||||
(let ((gp-0 (new 'stack-no-clear 'collide-query)))
|
||||
(let ((v1-0 gp-0))
|
||||
(set! (-> v1-0 radius) 819.2)
|
||||
(set! (-> v1-0 collide-with)
|
||||
(logclear (-> self control root-prim prim-core collide-with) (collide-spec water))
|
||||
)
|
||||
(set! (-> v1-0 ignore-process0) self)
|
||||
(set! (-> v1-0 ignore-process1) #f)
|
||||
(set! (-> v1-0 ignore-pat)
|
||||
(logior (new 'static 'pat-surface :noendlessfall #x1) (-> self control pat-ignore-mask))
|
||||
)
|
||||
(set! (-> v1-0 action-mask) (collide-action solid))
|
||||
)
|
||||
(set! (-> gp-0 start-pos quad) (-> self control trans quad))
|
||||
(vector-reset! (-> gp-0 move-dist))
|
||||
(set! (-> gp-0 move-dist y) 40960.0)
|
||||
(when (not (and (>= (fill-and-probe-using-line-sphere *collide-cache* gp-0) 0.0)
|
||||
(= (-> gp-0 best-other-tri pat event) (pat-event hang))
|
||||
)
|
||||
)
|
||||
(let ((v1-11 (new-stack-vector0)))
|
||||
(let ((f0-4 (vector-dot (-> self control dynam gravity-normal) (-> self control transv))))
|
||||
0.0
|
||||
(vector-! v1-11 (-> self control transv) (vector-float*! v1-11 (-> self control dynam gravity-normal) f0-4))
|
||||
)
|
||||
(let* ((f0-5 (vector-length v1-11))
|
||||
(f1-2 f0-5)
|
||||
(f2-0 0.0)
|
||||
)
|
||||
(vector+!
|
||||
(-> self control transv)
|
||||
(vector-float*! (-> self control transv) (-> self control dynam gravity-normal) f2-0)
|
||||
(vector-float*! v1-11 v1-11 (/ f0-5 f1-2))
|
||||
)
|
||||
)
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang-stance (target)
|
||||
:parent target-indax-hang
|
||||
:enter (behavior ()
|
||||
(let ((a0-0 (-> self state parent)))
|
||||
(when a0-0
|
||||
(let ((t9-0 (-> a0-0 enter)))
|
||||
(if t9-0
|
||||
((the-as (function none) t9-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self control mod-surface) *indax-hang-walk-mods*)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons x)
|
||||
)
|
||||
(not (logtest? (-> self control current-surface flags) (surface-flag no-jump)))
|
||||
(not (logtest? (-> self target-flags) (target-flags prevent-jump)))
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
(when (move-legs?)
|
||||
(set! (-> self control bend-target) 0.0)
|
||||
(logclear! (-> self target-flags) (target-flags lleg-still rleg-still))
|
||||
(go target-indax-hang-walk)
|
||||
)
|
||||
(if (cpad-hold? (-> self control cpad number) l1)
|
||||
(go target-indax-hang-dodge)
|
||||
)
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons circle)
|
||||
)
|
||||
(can-feet? #t)
|
||||
)
|
||||
(go target-indax-hang-attack)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(let ((v1-2 (ja-group)))
|
||||
(cond
|
||||
((and v1-2 (= v1-2 jakb-dummy-58-ja))
|
||||
(ja-channel-push! 1 (seconds 0.1))
|
||||
(ja-no-eval :group! jakb-ladder-stance-to-down-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
((not (time-elapsed? (-> self indax indax-hang-start-time) (seconds 0.1)))
|
||||
(ja-channel-push! 1 (seconds 0.1))
|
||||
(ja-no-eval :group! jakb-ladder-down-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
(else
|
||||
(ja-channel-push! 1 (seconds 0.1))
|
||||
)
|
||||
)
|
||||
)
|
||||
(until #f
|
||||
(ja-no-eval :group! jakb-dummy-57-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
#f
|
||||
)
|
||||
:post (behavior ()
|
||||
(let ((gp-0 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> gp-0 quad) (-> self control trans quad))
|
||||
(let ((a0-0 (-> self state parent)))
|
||||
(when a0-0
|
||||
(let ((t9-0 (-> a0-0 post)))
|
||||
(if t9-0
|
||||
((the-as (function none) t9-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(when (not (move-legs?))
|
||||
(set! (-> gp-0 y) (-> self control trans y))
|
||||
(move-to-point! (-> self control) gp-0)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang-walk (target)
|
||||
:parent target-indax-hang
|
||||
:enter (-> target-indax-hang-stance enter)
|
||||
:trans (behavior ()
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons x)
|
||||
)
|
||||
(not (logtest? (-> self control current-surface flags) (surface-flag no-jump)))
|
||||
(not (logtest? (-> self target-flags) (target-flags prevent-jump)))
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
(if (not (move-legs?))
|
||||
(go target-indax-hang-stance)
|
||||
)
|
||||
(if (cpad-hold? (-> self control cpad number) l1)
|
||||
(go target-indax-hang-dodge)
|
||||
)
|
||||
(when (and (turn-around?) (time-elapsed? (-> self state-time) (seconds 0.3)))
|
||||
(set! (-> self control transv quad)
|
||||
(-> self control transv-history (-> self control idx-of-fastest-xz-vel) quad)
|
||||
)
|
||||
(set! (-> self control transv w) 1.0)
|
||||
(go target-indax-hang-turn-around)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(let ((f30-0 0.0))
|
||||
(let ((v1-2 (ja-group)))
|
||||
(cond
|
||||
((and v1-2 (= v1-2 jakb-dummy-58-ja))
|
||||
(set! f30-0 (ja-frame-num 0))
|
||||
)
|
||||
(else
|
||||
(ja-channel-push! 1 (seconds 0.05))
|
||||
(ja-no-eval :group! jakb-dummy-59-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(compute-alignment! (-> self align))
|
||||
(align! (-> self align) (align-opts adjust-xz-vel) 1.0 1.0 1.0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(ja-no-eval :group! jakb-dummy-58-ja :num! (loop!) :dist 4096.0 :frame-num f30-0)
|
||||
)
|
||||
(until #f
|
||||
(suspend)
|
||||
(let* ((f0-10 (* (current-cycle-distance (-> self skel)) (-> self control scale x)))
|
||||
(f0-12 (/ (* 30.0 (-> self control ctrl-xz-vel)) (* 60.0 f0-10)))
|
||||
)
|
||||
(ja :num! (loop! f0-12))
|
||||
)
|
||||
)
|
||||
#f
|
||||
)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang-dodge (target)
|
||||
:parent target-indax-hang
|
||||
:enter (behavior ()
|
||||
(let ((a0-0 (-> self state parent)))
|
||||
(when a0-0
|
||||
(let ((t9-0 (-> a0-0 enter)))
|
||||
(if t9-0
|
||||
((the-as (function none) t9-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self control mod-surface) *indax-hang-dodge-mods*)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons x)
|
||||
)
|
||||
(not (logtest? (-> self control current-surface flags) (surface-flag no-jump)))
|
||||
(not (logtest? (-> self target-flags) (target-flags prevent-jump)))
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
(set-forward-vel 0.0)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-push! 1 (seconds 0.1))
|
||||
(ja-no-eval :group! jakb-ladder-stance-to-up-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
(ja :group! jakb-ladder-up-ja :num! min)
|
||||
(while (cpad-hold? (-> self control cpad number) l1)
|
||||
(suspend)
|
||||
(ja :num! (loop!))
|
||||
)
|
||||
(ja-no-eval :group! jakb-ladder-up-to-stance-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
(go target-indax-hang-stance)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang-attack (target)
|
||||
:parent target-indax-hang
|
||||
:event (behavior ((proc process) (argc int) (message symbol) (block event-message-block))
|
||||
(if (and (= message 'change-mode) (= (-> block param 0) 'hang))
|
||||
#f
|
||||
(target-indax-dangerous-event-handler proc argc message block)
|
||||
)
|
||||
)
|
||||
:enter (behavior ()
|
||||
(let ((a0-0 (-> self state parent)))
|
||||
(when a0-0
|
||||
(let ((t9-0 (-> a0-0 enter)))
|
||||
(if t9-0
|
||||
((the-as (function none) t9-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
((-> target-attack enter))
|
||||
(set! (-> self control mod-surface) *indax-hang-attack-mods*)
|
||||
)
|
||||
:exit (behavior ()
|
||||
((-> target-attack exit))
|
||||
(let ((v1-2 (-> self prev-state parent)))
|
||||
(when v1-2
|
||||
(let ((t9-1 (-> v1-2 exit)))
|
||||
(if t9-1
|
||||
(t9-1)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons x)
|
||||
)
|
||||
(not (logtest? (-> self control current-surface flags) (surface-flag no-jump)))
|
||||
(not (logtest? (-> self target-flags) (target-flags prevent-jump)))
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-push! 1 (seconds 0.05))
|
||||
(ja-no-eval :group! jakb-ladder-stance-ja :num! (seek!) :frame-num 0.0)
|
||||
(until (ja-done? 0)
|
||||
(compute-alignment! (-> self align))
|
||||
(let ((v1-19 (and (>= (ja-aframe-num 0) 4.0) (>= 9.0 (ja-aframe-num 0)))))
|
||||
(if v1-19
|
||||
(align! (-> self align) (align-opts adjust-xz-vel) 1.0 1.0 1.0)
|
||||
(set-forward-vel 0.0)
|
||||
)
|
||||
)
|
||||
(suspend)
|
||||
(ja :num! (seek!))
|
||||
)
|
||||
(go target-indax-hang-stance)
|
||||
)
|
||||
)
|
||||
|
||||
(defstate target-indax-hang-turn-around (target)
|
||||
:parent target-indax-hang
|
||||
:enter (behavior ()
|
||||
(let ((a0-0 (-> self state parent)))
|
||||
(when a0-0
|
||||
(let ((t9-0 (-> a0-0 enter)))
|
||||
(if t9-0
|
||||
((the-as (function none) t9-0))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(vector-turn-to (-> self control transv))
|
||||
(set! (-> self control mod-surface) *turn-around-mods*)
|
||||
(set! (-> self control bend-target) 1.0)
|
||||
(set-forward-vel 0.0)
|
||||
)
|
||||
:exit (behavior ()
|
||||
(set-forward-vel 0.0)
|
||||
(set! (-> self control ctrl-xz-vel) 0.0)
|
||||
(set-quaternion! (-> self control) (-> self control dir-targ))
|
||||
(set! (-> self control bend-target) 0.0)
|
||||
(let ((v1-6 (-> self prev-state parent)))
|
||||
(when v1-6
|
||||
(let ((t9-2 (-> v1-6 exit)))
|
||||
(if t9-2
|
||||
(t9-2)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(if (and (logtest? (logior (logior (-> *cpad-list* cpads (-> self control cpad number) button0-rel 0)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 1)
|
||||
)
|
||||
(-> *cpad-list* cpads (-> self control cpad number) button0-rel 2)
|
||||
)
|
||||
(pad-buttons x)
|
||||
)
|
||||
(not (logtest? (-> self control current-surface flags) (surface-flag no-jump)))
|
||||
(not (logtest? (-> self target-flags) (target-flags prevent-jump)))
|
||||
)
|
||||
(go target-indax-falling #f)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-push! 1 (seconds 0.04))
|
||||
(ja :group! jakb-ladder-get-on-ja :num! min)
|
||||
(quaternion-rotate-y! (-> self control dir-targ) (-> self control dir-targ) 32768.0)
|
||||
(compute-alignment! (-> self align))
|
||||
(until (ja-done? 0)
|
||||
(suspend)
|
||||
(ja :num! (seek! max 2.0))
|
||||
(compute-alignment! (-> self align))
|
||||
(align! (-> self align) (align-opts adjust-quat) 1.0 1.0 1.0)
|
||||
)
|
||||
(remove-exit)
|
||||
(let ((a0-8 target-indax-hang))
|
||||
(when a0-8
|
||||
(let ((t9-9 (-> a0-8 exit)))
|
||||
(if t9-9
|
||||
(t9-9)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self control ctrl-xz-vel) 16384.0)
|
||||
(set-forward-vel (-> self control ctrl-xz-vel))
|
||||
(go target-indax-hang-walk)
|
||||
)
|
||||
)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -16,7 +16,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype wings (process-drawable)
|
||||
((parent (pointer target) :override)
|
||||
((self wings :override)
|
||||
(parent (pointer target) :override)
|
||||
(shadow-backup shadow-geo :offset 208)
|
||||
(ragdoll-proc handle)
|
||||
(lock? symbol)
|
||||
|
||||
@@ -395,12 +395,7 @@
|
||||
)
|
||||
|
||||
(defbehavior wings-post wings ()
|
||||
(let* ((a0-0 (-> self parent))
|
||||
(v1-0 (if a0-0
|
||||
(the-as process-drawable (-> a0-0 0 self))
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-0 (ppointer->process (-> self parent))))
|
||||
(set! (-> self draw light-index) (-> (the-as process-focusable v1-0) draw light-index))
|
||||
(set-vector! (-> self draw color-mult) 0.0 0.0 0.0 0.0)
|
||||
(set-vector! (-> self draw color-emissive) 1.0 1.0 1.0 1.0)
|
||||
@@ -498,18 +493,9 @@
|
||||
(defstate hidden (wings)
|
||||
:virtual #t
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(if (not (focus-test?
|
||||
(the-as process-focusable (if v1-0
|
||||
(the-as process-focusable (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
)
|
||||
(go-virtual idle #f)
|
||||
)
|
||||
)
|
||||
(if (not (focus-test? (ppointer->process (-> self parent)) in-head))
|
||||
(go-virtual idle #f)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(ja-channel-set! 0)
|
||||
@@ -543,28 +529,11 @@
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(b!
|
||||
(not (focus-test?
|
||||
(the-as process-focusable (if v1-0
|
||||
(the-as process-focusable (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
)
|
||||
cfg-4
|
||||
:delay (empty-form)
|
||||
)
|
||||
)
|
||||
(b! (not (focus-test? (ppointer->process (-> self parent)) in-head)) cfg-4 :delay (empty-form))
|
||||
(go-virtual hidden)
|
||||
(b! #t cfg-27 :delay (nop!))
|
||||
(label cfg-4)
|
||||
(if (and (not (-> self lock?)) (let* ((a0-1 (-> self parent))
|
||||
(v1-10 (if a0-1
|
||||
(the-as process-drawable (-> a0-1 0 self))
|
||||
)
|
||||
)
|
||||
(if (and (not (-> self lock?)) (let* ((v1-10 (ppointer->process (-> self parent)))
|
||||
(a0-4 (if (> (-> v1-10 skel active-channels) 0)
|
||||
(-> v1-10 skel root-channel 0 frame-group)
|
||||
)
|
||||
@@ -632,7 +601,7 @@
|
||||
)
|
||||
(set! a0-17 (handle->process (-> self ragdoll-proc)))
|
||||
)
|
||||
(if (and a0-17 (-> (the-as process-drawable a0-17) root))
|
||||
(if (and (the-as ragdoll-proc a0-17) (-> (the-as ragdoll-proc a0-17) ragdoll))
|
||||
(logior! (-> (the-as ragdoll-proc a0-17) ragdoll ragdoll-flags) (ragdoll-flag rf3 rf4 rf10))
|
||||
)
|
||||
(ragdoll-proc-method-15 (the-as ragdoll-proc a0-17) #f (the-as vector #f) #t)
|
||||
@@ -682,31 +651,23 @@
|
||||
)
|
||||
)
|
||||
:trans (behavior ()
|
||||
(let ((v1-0 (ppointer->process (-> self parent)))
|
||||
(a0-1 (-> self parent))
|
||||
)
|
||||
(let ((v1-0 (ppointer->process (-> self parent))))
|
||||
(cond
|
||||
((focus-test?
|
||||
(the-as process-focusable (if a0-1
|
||||
(the-as process-focusable (-> a0-1 0 self))
|
||||
)
|
||||
)
|
||||
in-head
|
||||
)
|
||||
((focus-test? (ppointer->process (-> self parent)) in-head)
|
||||
(go-virtual hidden)
|
||||
)
|
||||
((let ((a0-8 (if (> (-> (the-as process-focusable v1-0) skel active-channels) 0)
|
||||
(-> (the-as process-focusable v1-0) skel root-channel 0 frame-group)
|
||||
((let ((a0-8 (if (> (-> v1-0 skel active-channels) 0)
|
||||
(-> v1-0 skel root-channel 0 frame-group)
|
||||
)
|
||||
)
|
||||
)
|
||||
(not (and a0-8 (or (= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 493))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 494))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 495))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 496))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 482))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 485))
|
||||
(= a0-8 (-> (the-as process-focusable v1-0) draw art-group data 483))
|
||||
(not (and a0-8 (or (= a0-8 (-> v1-0 draw art-group data 493))
|
||||
(= a0-8 (-> v1-0 draw art-group data 494))
|
||||
(= a0-8 (-> v1-0 draw art-group data 495))
|
||||
(= a0-8 (-> v1-0 draw art-group data 496))
|
||||
(= a0-8 (-> v1-0 draw art-group data 482))
|
||||
(= a0-8 (-> v1-0 draw art-group data 485))
|
||||
(= a0-8 (-> v1-0 draw art-group data 483))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -751,7 +712,7 @@
|
||||
(a0-6 (-> self node-list data))
|
||||
)
|
||||
(set! (-> a0-6 0 param0) (the-as (function cspace transformq none) cspace<-cspace-normalized!))
|
||||
(set! (-> a0-6 0 param1) (the-as basic (-> (the-as process-drawable v1-6) node-list data 6)))
|
||||
(set! (-> a0-6 0 param1) (the-as basic (-> v1-6 node-list data 6)))
|
||||
(set! (-> a0-6 0 param2) #f)
|
||||
)
|
||||
(set! (-> self ragdoll-proc) (the-as handle #f))
|
||||
@@ -781,7 +742,7 @@
|
||||
|
||||
|
||||
;; WARN: Return type mismatch vector vs none.
|
||||
(defmethod ragdoll-method-19 ((this wings-ragdoll) (arg0 vector) (arg1 int) (arg2 object) (arg3 vector))
|
||||
(defmethod ragdoll-method-19 ((this wings-ragdoll) (arg0 vector) (arg1 int) (arg2 object) (arg3 matrix))
|
||||
(let ((s3-0 (new 'stack-no-clear 'vector)))
|
||||
(set! (-> s3-0 quad) (-> this gravity quad))
|
||||
(let ((s1-0 (-> this ragdoll-joints arg1))
|
||||
@@ -810,25 +771,19 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(vector-float*! (-> this gravity) (&+ arg3 16) f30-0)
|
||||
(vector-float*! (-> this gravity) (-> arg3 uvec) f30-0)
|
||||
(let ((t9-0 (method-of-type ragdoll ragdoll-method-19)))
|
||||
(t9-0 this arg0 arg1 arg2 arg3)
|
||||
)
|
||||
(when (= (-> s1-0 parent-joint) -1)
|
||||
(let* ((f0-4
|
||||
(+ (* 54.613335 (the float (current-time)))
|
||||
(* 10922.667 (the float (-> this chain-pos)))
|
||||
(* 29127.111 (the float (-> this which-chain)))
|
||||
)
|
||||
)
|
||||
(let* ((f0-4 (+ (* 54.613335 (the float (current-time)))
|
||||
(* 10922.667 (the float (-> this chain-pos)))
|
||||
(* 29127.111 (the float (-> this which-chain)))
|
||||
)
|
||||
)
|
||||
(f0-5 (- f0-4 (* (the float (the int (/ f0-4 65536.0))) 65536.0)))
|
||||
)
|
||||
(vector+float*!
|
||||
arg0
|
||||
arg0
|
||||
(the-as vector (&-> arg3 x))
|
||||
(* 5.0 (cos f0-5) f30-0 (the float (-> this chain-pos)))
|
||||
)
|
||||
(vector+float*! arg0 arg0 (-> arg3 rvec) (* 5.0 (cos f0-5) f30-0 (the float (-> this chain-pos))))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -875,11 +830,7 @@
|
||||
(set! (-> self last-attack-id) (the-as uint 0))
|
||||
(set! (-> self ragdoll) (new 'process 'wings-ragdoll))
|
||||
(if (nonzero? (-> self ragdoll))
|
||||
(ragdoll-setup!
|
||||
(-> self ragdoll)
|
||||
(the-as process-drawable (ppointer->process (-> self parent)))
|
||||
(the-as ragdoll-setup arg0)
|
||||
)
|
||||
(ragdoll-setup! (-> self ragdoll) (ppointer->process (-> self parent)) (the-as ragdoll-setup arg0))
|
||||
(format 0 "ERROR<gmj>: didn't have enough memory to allocate wings-ragdoll for wings-ragdoll-proc~%")
|
||||
)
|
||||
(go-virtual idle)
|
||||
|
||||
@@ -234,63 +234,27 @@
|
||||
)
|
||||
)
|
||||
(change-parent (ppointer->process (-> arg0 process)) (ppointer->process (-> this process)))
|
||||
(let* ((v1-46 (-> arg0 process))
|
||||
(v1-49
|
||||
(-> (the-as collide-shape (-> (the-as process-drawable (if v1-46
|
||||
(the-as process-drawable (-> v1-46 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
)
|
||||
)
|
||||
root-prim
|
||||
(let ((v1-49 (-> (the-as collide-shape (-> (the-as process-drawable (ppointer->process (-> arg0 process))) root))
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((a0-30 (-> v1-49 prim-core collide-as))
|
||||
(a1-25 (-> arg0 process))
|
||||
)
|
||||
(set! (-> (the-as collide-shape (-> (the-as process-drawable (ppointer->process (-> arg0 process))) root))
|
||||
backup-collide-as
|
||||
)
|
||||
(-> v1-49 prim-core collide-as)
|
||||
)
|
||||
(set! (-> (the-as collide-shape (-> (the-as process-drawable (if a1-25
|
||||
(the-as process-drawable (-> a1-25 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
)
|
||||
)
|
||||
backup-collide-as
|
||||
)
|
||||
a0-30
|
||||
)
|
||||
)
|
||||
(let ((v1-50 (-> v1-49 prim-core collide-with))
|
||||
(a0-31 (-> arg0 process))
|
||||
(set! (-> (the-as collide-shape (-> (the-as process-drawable (ppointer->process (-> arg0 process))) root))
|
||||
backup-collide-with
|
||||
)
|
||||
(-> v1-49 prim-core collide-with)
|
||||
)
|
||||
(set! (-> (the-as collide-shape (-> (the-as process-drawable (if a0-31
|
||||
(the-as process-drawable (-> a0-31 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
)
|
||||
)
|
||||
backup-collide-with
|
||||
)
|
||||
v1-50
|
||||
)
|
||||
)
|
||||
)
|
||||
(let* ((v1-51 (-> arg0 process))
|
||||
(v1-54
|
||||
(-> (the-as collide-shape (-> (the-as process-drawable (if v1-51
|
||||
(the-as process-drawable (-> v1-51 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
)
|
||||
)
|
||||
root-prim
|
||||
(let ((v1-54 (-> (the-as collide-shape (-> (the-as process-drawable (ppointer->process (-> arg0 process))) root))
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> v1-54 prim-core collide-as) (collide-spec))
|
||||
(set! (-> v1-54 prim-core collide-with) (collide-spec))
|
||||
)
|
||||
@@ -317,41 +281,18 @@
|
||||
(set! (-> this other) (the-as handle #f))
|
||||
(set! (-> arg0 other) (the-as handle #f))
|
||||
(change-parent (ppointer->process (-> arg0 process)) *entity-pool*)
|
||||
(let* ((v1-13 (-> arg0 process))
|
||||
(v1-16
|
||||
(-> (the-as collide-shape (-> (the-as process-drawable (if v1-13
|
||||
(the-as process-drawable (-> v1-13 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
)
|
||||
)
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((a0-8 (-> arg0 process)))
|
||||
(set! (-> v1-16 prim-core collide-as)
|
||||
(-> (the-as process-focusable (if a0-8
|
||||
(the-as process-focusable (-> a0-8 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
backup-collide-as
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((a0-12 (-> arg0 process)))
|
||||
(set! (-> v1-16 prim-core collide-with)
|
||||
(-> (the-as process-focusable (if a0-12
|
||||
(the-as process-focusable (-> a0-12 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
backup-collide-with
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-16
|
||||
(-> (the-as collide-shape (-> (the-as process-drawable (ppointer->process (-> arg0 process))) root))
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> v1-16 prim-core collide-as)
|
||||
(-> (the-as process-focusable (ppointer->process (-> arg0 process))) root backup-collide-as)
|
||||
)
|
||||
(set! (-> v1-16 prim-core collide-with)
|
||||
(-> (the-as process-focusable (ppointer->process (-> arg0 process))) root backup-collide-with)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
@@ -463,53 +404,15 @@
|
||||
)
|
||||
(vector+float*! arg1 (-> arg0 point) arg2 (- (-> arg0 carry-radius)))
|
||||
(change-parent (ppointer->process (-> arg0 process)) (ppointer->process (-> this process)))
|
||||
(let* ((v1-46 (-> arg0 process))
|
||||
(v1-49 (-> (the-as process-focusable (if v1-46
|
||||
(the-as process-focusable (-> v1-46 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((a0-32 (-> v1-49 prim-core collide-as))
|
||||
(a1-7 (-> arg0 process))
|
||||
(let ((v1-49 (-> (the-as process-focusable (ppointer->process (-> arg0 process))) root root-prim)))
|
||||
(set! (-> (the-as process-focusable (ppointer->process (-> arg0 process))) root backup-collide-as)
|
||||
(-> v1-49 prim-core collide-as)
|
||||
)
|
||||
(set! (-> (the-as process-focusable (if a1-7
|
||||
(the-as process-focusable (-> a1-7 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
backup-collide-as
|
||||
)
|
||||
a0-32
|
||||
)
|
||||
)
|
||||
(let ((v1-50 (-> v1-49 prim-core collide-with))
|
||||
(a0-33 (-> arg0 process))
|
||||
(set! (-> (the-as process-focusable (ppointer->process (-> arg0 process))) root backup-collide-with)
|
||||
(-> v1-49 prim-core collide-with)
|
||||
)
|
||||
(set! (-> (the-as process-focusable (if a0-33
|
||||
(the-as process-focusable (-> a0-33 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
backup-collide-with
|
||||
)
|
||||
v1-50
|
||||
)
|
||||
)
|
||||
)
|
||||
(let* ((v1-51 (-> arg0 process))
|
||||
(v1-54 (-> (the-as process-focusable (if v1-51
|
||||
(the-as process-focusable (-> v1-51 0 self))
|
||||
)
|
||||
)
|
||||
root
|
||||
root-prim
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-54 (-> (the-as process-focusable (ppointer->process (-> arg0 process))) root root-prim)))
|
||||
(set! (-> v1-54 prim-core collide-as) (collide-spec))
|
||||
(set! (-> v1-54 prim-core collide-with) (collide-spec))
|
||||
)
|
||||
|
||||
@@ -404,7 +404,7 @@
|
||||
(set! s5-0 jakb-mech-punch-l-ja)
|
||||
((method-of-type impact-control initialize)
|
||||
(the-as impact-control (-> self mech state-impact))
|
||||
(the-as process-drawable (ppointer->process (-> self manipy)))
|
||||
(ppointer->process (-> self manipy))
|
||||
7
|
||||
6963.2
|
||||
(logior (collide-spec mech-punch) (-> self control root-prim prim-core collide-with))
|
||||
@@ -415,7 +415,7 @@
|
||||
(set! s5-0 jakb-mech-punch-r-ja)
|
||||
((method-of-type impact-control initialize)
|
||||
(the-as impact-control (-> self mech state-impact))
|
||||
(the-as process-drawable (ppointer->process (-> self manipy)))
|
||||
(ppointer->process (-> self manipy))
|
||||
17
|
||||
6963.2
|
||||
(logior (collide-spec mech-punch) (-> self control root-prim prim-core collide-with))
|
||||
@@ -426,7 +426,7 @@
|
||||
(set! s5-0 jakb-mech-punch-b-ja)
|
||||
((method-of-type impact-control initialize)
|
||||
(the-as impact-control (-> self mech state-impact))
|
||||
(the-as process-drawable (ppointer->process (-> self manipy)))
|
||||
(ppointer->process (-> self manipy))
|
||||
39
|
||||
11141.12
|
||||
(logior (collide-spec mech-punch) (-> self control root-prim prim-core collide-with))
|
||||
@@ -437,7 +437,7 @@
|
||||
(set! s5-0 jakb-mech-punch-u-ja)
|
||||
((method-of-type impact-control initialize)
|
||||
(the-as impact-control (-> self mech state-impact))
|
||||
(the-as process-drawable (ppointer->process (-> self manipy)))
|
||||
(ppointer->process (-> self manipy))
|
||||
39
|
||||
11141.12
|
||||
(logior (collide-spec mech-punch) (-> self control root-prim prim-core collide-with))
|
||||
@@ -1214,7 +1214,7 @@
|
||||
(when (>= (- (-> *display* game-clock frame-counter) (-> self shock-effect-time)) (seconds 0.03))
|
||||
(set! (-> self shock-effect-time) (-> *display* game-clock frame-counter))
|
||||
(process-drawable-shock-effect
|
||||
(the-as process-drawable (ppointer->process (-> self manipy)))
|
||||
(ppointer->process (-> self manipy))
|
||||
(-> *lightning-spec-id-table* 1)
|
||||
lightning-probe-callback
|
||||
(-> *part-id-table* 160)
|
||||
|
||||
@@ -352,7 +352,7 @@
|
||||
)
|
||||
)
|
||||
(set! (-> self sound)
|
||||
(new 'process 'ambient-sound (static-sound-spec "zoom-teleport" :group 1 :fo-max 30) (-> self root trans) 0.0)
|
||||
(new 'process 'ambient-sound (static-sound-spec "zoom-teleport" :group 0 :fo-max 30) (-> self root trans) 0.0)
|
||||
)
|
||||
(set! (-> self draw light-index) (the-as uint 30))
|
||||
(if (handle->process arg2)
|
||||
|
||||
@@ -242,7 +242,7 @@
|
||||
(go target-falling #f)
|
||||
)
|
||||
(#t
|
||||
(let ((s4-0 (new 'stack-no-clear 'matrix)))
|
||||
(let ((s4-0 (new 'stack-no-clear 'inline-array 'vector 10)))
|
||||
(set! (-> gp-0 accel-array 7 quad) (-> gp-0 accel-array 6 quad))
|
||||
(set! (-> gp-0 accel-array 6 quad) (-> gp-0 accel-array 5 quad))
|
||||
(set! (-> gp-0 accel-array 5 quad) (-> gp-0 accel-array 4 quad))
|
||||
@@ -251,18 +251,18 @@
|
||||
(set! (-> gp-0 accel-array 2 quad) (-> gp-0 accel-array 1 quad))
|
||||
(set! (-> gp-0 accel-array 1 quad) (-> gp-0 accel-array 0 quad))
|
||||
(get-linear-accel! s5-0 (the-as vector (-> gp-0 accel-array)))
|
||||
(vector-reset! (-> s4-0 rvec))
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (the-as vector (-> gp-0 accel-array)) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 1) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 2) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 3) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 4) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 5) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 6) 1.0)
|
||||
(vector+float*! (-> s4-0 rvec) (-> s4-0 rvec) (-> gp-0 accel-array 7) 1.0)
|
||||
(vector-float*! (-> s4-0 rvec) (-> s4-0 rvec) 0.5)
|
||||
(matrix-transpose! (the-as matrix (-> s4-0 uvec)) (-> self node-list data 0 bone transform))
|
||||
(vector-rotate*! (-> gp-0 local-accel) (-> s4-0 rvec) (the-as matrix (-> s4-0 uvec)))
|
||||
(vector-reset! (-> s4-0 0))
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (the-as vector (-> gp-0 accel-array)) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 1) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 2) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 3) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 4) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 5) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 6) 1.0)
|
||||
(vector+float*! (-> s4-0 0) (-> s4-0 0) (-> gp-0 accel-array 7) 1.0)
|
||||
(vector-float*! (-> s4-0 0) (-> s4-0 0) 0.5)
|
||||
(matrix-transpose! (the-as matrix (-> s4-0 1)) (-> self node-list data 0 bone transform))
|
||||
(vector-rotate*! (-> gp-0 local-accel) (-> s4-0 0) (the-as matrix (-> s4-0 1)))
|
||||
)
|
||||
(copy-vehicle-controls! s5-0 (-> gp-0 controls))
|
||||
(let ((f30-0 (* 182.04445 (* 0.6 (the float (current-time)))))
|
||||
|
||||
@@ -73,19 +73,16 @@
|
||||
(set! (-> self special-anim-frame) 0.0)
|
||||
)
|
||||
(cond
|
||||
((or (and (= (-> (the-as target gp-0) control mod-surface name) 'spin)
|
||||
(!= (-> (the-as target gp-0) board rotyv) 0.0)
|
||||
)
|
||||
((or (and (= (-> gp-0 control mod-surface name) 'spin) (!= (-> gp-0 board rotyv) 0.0))
|
||||
(!= (-> self special-anim-interp) 0.0)
|
||||
)
|
||||
(case arg2
|
||||
((1)
|
||||
(set-time! (-> self special-anim-time))
|
||||
(cond
|
||||
((= (-> (the-as target gp-0) control mod-surface name) 'spin)
|
||||
(set! (-> arg1 z) (* (lerp-scale 0.0 5.0 (fabs (-> (the-as target gp-0) board rotyv)) 0.0 182044.44)
|
||||
(-> self special-anim-interp)
|
||||
)
|
||||
((= (-> gp-0 control mod-surface name) 'spin)
|
||||
(set! (-> arg1 z)
|
||||
(* (lerp-scale 0.0 5.0 (fabs (-> gp-0 board rotyv)) 0.0 182044.44) (-> self special-anim-interp))
|
||||
)
|
||||
(set! (-> self special-anim-frame) (-> arg1 z))
|
||||
(seek! (-> self special-anim-interp) 1.0 (* 8.0 (seconds-per-frame)))
|
||||
@@ -97,7 +94,7 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(if (>= (-> (the-as target gp-0) board rotyv) 0.0)
|
||||
(if (>= (-> gp-0 board rotyv) 0.0)
|
||||
"board-spin-ccw"
|
||||
"board-spin-cw"
|
||||
)
|
||||
@@ -263,240 +260,197 @@
|
||||
)
|
||||
:code looping-code
|
||||
:post (behavior ()
|
||||
(local-vars (v1-100 symbol))
|
||||
(let ((v1-0 (-> self parent)))
|
||||
(when (not (and (-> (the-as target (if v1-0
|
||||
(the-as target (-> v1-0 0 self))
|
||||
)
|
||||
)
|
||||
next-state
|
||||
)
|
||||
(let ((v1-4 (-> self parent)))
|
||||
(= (-> (the-as target (if v1-4
|
||||
(the-as target (-> v1-4 0 self))
|
||||
)
|
||||
)
|
||||
next-state
|
||||
name
|
||||
)
|
||||
'process-drawable-art-error
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(quaternion-rotate-y!
|
||||
(-> self control quat)
|
||||
(-> self parent 0 control quat)
|
||||
(-> self parent 0 upper-body twist z)
|
||||
(when (not (and (-> (ppointer->process (-> self parent)) next-state)
|
||||
(= (-> (ppointer->process (-> self parent)) next-state name) 'process-drawable-art-error)
|
||||
)
|
||||
)
|
||||
(quaternion-rotate-y!
|
||||
(-> self control quat)
|
||||
(-> self parent 0 control quat)
|
||||
(-> self parent 0 upper-body twist z)
|
||||
)
|
||||
(set! (-> self anim-seed) (-> self parent 0 anim-seed))
|
||||
(set! (-> self draw status) (-> self parent 0 draw status))
|
||||
(cond
|
||||
((logtest? (-> self parent 0 target-effect) 1)
|
||||
(logior! (-> self draw status) (draw-control-status no-draw))
|
||||
(logior! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
)
|
||||
(else
|
||||
(logclear! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
)
|
||||
(set! (-> self anim-seed) (-> self parent 0 anim-seed))
|
||||
(set! (-> self draw status) (-> self parent 0 draw status))
|
||||
)
|
||||
(logclear! (-> self draw status) (draw-control-status no-draw-bounds2))
|
||||
(let ((gp-0 0))
|
||||
(cond
|
||||
((logtest? (-> self parent 0 target-effect) 1)
|
||||
(logior! (-> self draw status) (draw-control-status no-draw))
|
||||
(logior! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
((and (not (logtest? (-> self parent 0 focus-status) (focus-status edge-grab)))
|
||||
(> (-> self parent 0 skel float-channels) 0)
|
||||
)
|
||||
(let ((gp-1 (-> self skel)))
|
||||
(joint-control-copy! gp-1 (-> self parent 0 skel))
|
||||
(set! (-> gp-1 root-channel)
|
||||
(the-as (inline-array joint-control-channel) (-> gp-1 channel (-> gp-1 active-channels)))
|
||||
)
|
||||
(dotimes (s5-0 (the-as int (-> self parent 0 skel float-channels)))
|
||||
(let ((s4-0 (-> gp-1 channel (+ s5-0 (-> gp-1 active-channels)))))
|
||||
(mem-copy!
|
||||
(the-as pointer s4-0)
|
||||
(the-as pointer (-> self parent 0 skel channel (+ s5-0 (-> self parent 0 skel active-channels))))
|
||||
64
|
||||
)
|
||||
(set! (-> s4-0 frame-interp 0) (-> s4-0 frame-interp 1))
|
||||
(set! (-> s4-0 command) (joint-control-command blend))
|
||||
)
|
||||
)
|
||||
(dotimes (v1-70 (the-as int (-> gp-1 allocated-length)))
|
||||
(set! (-> gp-1 channel v1-70 parent) gp-1)
|
||||
)
|
||||
(+! (-> gp-1 active-channels) (-> self parent 0 skel float-channels))
|
||||
(set! (-> gp-1 float-channels) (the-as uint 0))
|
||||
)
|
||||
(set! gp-0 1)
|
||||
)
|
||||
(else
|
||||
(logclear! (-> self draw global-effect) (draw-control-global-effect no-textures))
|
||||
(joint-control-copy! (-> self skel) (-> self parent 0 skel))
|
||||
)
|
||||
)
|
||||
(logclear! (-> self draw status) (draw-control-status no-draw-bounds2))
|
||||
(let ((gp-0 0))
|
||||
(cond
|
||||
((and (not (logtest? (-> self parent 0 focus-status) (focus-status edge-grab)))
|
||||
(> (-> self parent 0 skel float-channels) 0)
|
||||
)
|
||||
(let ((gp-1 (-> self skel)))
|
||||
(joint-control-copy! gp-1 (-> self parent 0 skel))
|
||||
(set! (-> gp-1 root-channel)
|
||||
(the-as (inline-array joint-control-channel) (-> gp-1 channel (-> gp-1 active-channels)))
|
||||
)
|
||||
(dotimes (s5-0 (the-as int (-> self parent 0 skel float-channels)))
|
||||
(let ((s4-0 (-> gp-1 channel (+ s5-0 (-> gp-1 active-channels)))))
|
||||
(mem-copy!
|
||||
(the-as pointer s4-0)
|
||||
(the-as pointer (-> self parent 0 skel channel (+ s5-0 (-> self parent 0 skel active-channels))))
|
||||
64
|
||||
)
|
||||
(set! (-> s4-0 frame-interp 0) (-> s4-0 frame-interp 1))
|
||||
(set! (-> s4-0 command) (joint-control-command blend))
|
||||
)
|
||||
)
|
||||
(dotimes (v1-70 (the-as int (-> gp-1 allocated-length)))
|
||||
(set! (-> gp-1 channel v1-70 parent) gp-1)
|
||||
)
|
||||
(+! (-> gp-1 active-channels) (-> self parent 0 skel float-channels))
|
||||
(set! (-> gp-1 float-channels) (the-as uint 0))
|
||||
)
|
||||
(set! gp-0 1)
|
||||
)
|
||||
(else
|
||||
(joint-control-copy! (-> self skel) (-> self parent 0 skel))
|
||||
)
|
||||
)
|
||||
(joint-control-remap!
|
||||
(-> self skel)
|
||||
(-> self draw art-group)
|
||||
(-> self parent 0 draw art-group)
|
||||
*sidekick-remap*
|
||||
(the-as int (-> self anim-seed))
|
||||
""
|
||||
)
|
||||
(cond
|
||||
((zero? gp-0)
|
||||
(set! (-> self skel effect channel-offset) (-> self parent 0 skel effect channel-offset))
|
||||
)
|
||||
((= gp-0 1)
|
||||
(set! (-> self skel effect channel-offset) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-97 (-> self parent 0 draw color-mult quad)))
|
||||
(set! (-> self draw color-mult quad) v1-97)
|
||||
)
|
||||
(let ((v1-98 #x20000)
|
||||
(a0-27 (-> self parent))
|
||||
)
|
||||
(cond
|
||||
((and (logtest? (the-as focus-status v1-98) (-> (the-as target (if a0-27
|
||||
(the-as target (-> a0-27 0 self))
|
||||
)
|
||||
)
|
||||
focus-status
|
||||
)
|
||||
)
|
||||
(begin
|
||||
(let* ((v1-101 #t)
|
||||
(a0-30 (-> self parent))
|
||||
(a0-32 (the-as lightjak-info (-> (the-as target (if a0-30
|
||||
(the-as target (-> a0-30 0 self))
|
||||
)
|
||||
)
|
||||
lightjak
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(cmove-#f-zero v1-100 a0-32 v1-101)
|
||||
)
|
||||
v1-100
|
||||
)
|
||||
)
|
||||
(set-vector! (-> self draw color-emissive) 0.1 0.4 1.0 0.5)
|
||||
)
|
||||
(else
|
||||
(let ((a0-37 (-> self parent 0 draw color-emissive quad)))
|
||||
(set! (-> self draw color-emissive quad) a0-37)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(set! (-> self draw force-fade) (-> self parent 0 draw force-fade))
|
||||
(set! (-> self draw death-vertex-skip) (-> self parent 0 draw death-vertex-skip))
|
||||
(set! (-> self draw death-effect) (-> self parent 0 draw death-effect))
|
||||
(set! (-> self draw death-timer) (-> self parent 0 draw death-timer))
|
||||
(set! (-> self draw death-timer-org) (-> self parent 0 draw death-timer-org))
|
||||
(set! (-> self draw death-draw-overlap) (-> self parent 0 draw death-draw-overlap))
|
||||
(quaternion-copy! (-> self offset quat) (-> self control quat))
|
||||
(let ((f0-7 (* (-> self parent 0 darkjak-interp) (-> self parent 0 darkjak-giant-interp))))
|
||||
(set! (-> self offset trans x) (* 286.72 f0-7))
|
||||
(set! (-> self offset trans y) (* 204.8 f0-7))
|
||||
(set! (-> self offset trans z) (* 409.6 f0-7))
|
||||
(joint-control-remap!
|
||||
(-> self skel)
|
||||
(-> self draw art-group)
|
||||
(-> self parent 0 draw art-group)
|
||||
*sidekick-remap*
|
||||
(the-as int (-> self anim-seed))
|
||||
""
|
||||
)
|
||||
(cond
|
||||
((= (-> self parent 0 skel override 0) 0.00001)
|
||||
(set! (-> self skel override 0) 0.00001)
|
||||
(set! (-> self skel override 41) 1.0)
|
||||
(set! (-> self skel override 46) 1.0)
|
||||
(set! (-> self skel override 52) 1.0)
|
||||
((zero? gp-0)
|
||||
(set! (-> self skel effect channel-offset) (-> self parent 0 skel effect channel-offset))
|
||||
)
|
||||
((!= (-> self skel override 0) 0.0)
|
||||
(set! (-> self skel override 0) 0.0)
|
||||
(set! (-> self skel override 41) 0.0)
|
||||
((= gp-0 1)
|
||||
(set! (-> self skel effect channel-offset) 0)
|
||||
0
|
||||
)
|
||||
)
|
||||
(let ((f30-0 (vector-length (-> self parent 0 control transv))))
|
||||
(seek!
|
||||
(-> self ear 0 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self ear 0 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-26 (+ (-> self ear 0 twist z) (* (-> self ear 0 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self ear 0 twist z) (- f0-26 (* (the float (the int (/ f0-26 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self ear 0)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self ear 0 twist z))) (-> self ear 0 twist-max z))
|
||||
)
|
||||
(let ((v1-97 (-> self parent 0 draw color-mult quad)))
|
||||
(set! (-> self draw color-mult quad) v1-97)
|
||||
)
|
||||
(cond
|
||||
((and (focus-test? (ppointer->process (-> self parent)) light)
|
||||
(nonzero? (-> (ppointer->process (-> self parent)) lightjak))
|
||||
)
|
||||
(the-as vector #f)
|
||||
(set-vector! (-> self draw color-emissive) 0.1 0.4 1.0 0.5)
|
||||
)
|
||||
(else
|
||||
(let ((a0-37 (-> self parent 0 draw color-emissive quad)))
|
||||
(set! (-> self draw color-emissive quad) a0-37)
|
||||
)
|
||||
(seek!
|
||||
(-> self ear 1 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self ear 1 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-41 (+ (-> self ear 1 twist z) (* (-> self ear 1 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self ear 1 twist z) (- f0-41 (* (the float (the int (/ f0-41 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self ear 1)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self ear 1 twist z))) (-> self ear 1 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(seek!
|
||||
(-> self flap 0 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self flap 0 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-56 (+ (-> self flap 0 twist z) (* (-> self flap 0 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self flap 0 twist z) (- f0-56 (* (the float (the int (/ f0-56 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self flap 0)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self flap 0 twist z))) (-> self flap 0 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(seek!
|
||||
(-> self flap 1 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self flap 1 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
)
|
||||
(let ((f0-71 (+ (-> self flap 1 twist z) (* (-> self flap 1 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self flap 1 twist z) (- f0-71 (* (the float (the int (/ f0-71 1.0))) 1.0)))
|
||||
)
|
||||
(set! (-> self draw force-fade) (-> self parent 0 draw force-fade))
|
||||
(set! (-> self draw death-vertex-skip) (-> self parent 0 draw death-vertex-skip))
|
||||
(set! (-> self draw death-effect) (-> self parent 0 draw death-effect))
|
||||
(set! (-> self draw death-timer) (-> self parent 0 draw death-timer))
|
||||
(set! (-> self draw death-timer-org) (-> self parent 0 draw death-timer-org))
|
||||
(set! (-> self draw death-draw-overlap) (-> self parent 0 draw death-draw-overlap))
|
||||
(quaternion-copy! (-> self offset quat) (-> self control quat))
|
||||
(let ((f0-7 (* (-> self parent 0 darkjak-interp) (-> self parent 0 darkjak-giant-interp))))
|
||||
(set! (-> self offset trans x) (* 286.72 f0-7))
|
||||
(set! (-> self offset trans y) (* 204.8 f0-7))
|
||||
(set! (-> self offset trans z) (* 409.6 f0-7))
|
||||
)
|
||||
(cond
|
||||
((= (-> self parent 0 skel override 0) 0.00001)
|
||||
(set! (-> self skel override 0) 0.00001)
|
||||
(set! (-> self skel override 41) 1.0)
|
||||
(set! (-> self skel override 46) 1.0)
|
||||
(set! (-> self skel override 52) 1.0)
|
||||
)
|
||||
((!= (-> self skel override 0) 0.0)
|
||||
(set! (-> self skel override 0) 0.0)
|
||||
(set! (-> self skel override 41) 0.0)
|
||||
)
|
||||
)
|
||||
(let ((f30-0 (vector-length (-> self parent 0 control transv))))
|
||||
(seek!
|
||||
(-> self ear 0 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self ear 0 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-26 (+ (-> self ear 0 twist z) (* (-> self ear 0 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self ear 0 twist z) (- f0-26 (* (the float (the int (/ f0-26 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self flap 1)
|
||||
(-> self ear 0)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self flap 1 twist z))) (-> self flap 1 twist-max z))
|
||||
(* (sin (* 32768.0 (-> self ear 0 twist z))) (-> self ear 0 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(update-anim-data (-> self skel))
|
||||
(do-joint-math (-> self draw) (-> self node-list) (-> self skel))
|
||||
(seek!
|
||||
(-> self ear 1 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self ear 1 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-41 (+ (-> self ear 1 twist z) (* (-> self ear 1 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self ear 1 twist z) (- f0-41 (* (the float (the int (/ f0-41 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self ear 1)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self ear 1 twist z))) (-> self ear 1 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(seek!
|
||||
(-> self flap 0 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self flap 0 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
(let ((f0-56 (+ (-> self flap 0 twist z) (* (-> self flap 0 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self flap 0 twist z) (- f0-56 (* (the float (the int (/ f0-56 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self flap 0)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self flap 0 twist z))) (-> self flap 0 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(seek!
|
||||
(-> self flap 1 twist-max z)
|
||||
(lerp-scale 0.0 5461.3335 f30-0 4096.0 122880.0)
|
||||
(* 65536.0 (seconds-per-frame))
|
||||
)
|
||||
(seek! (-> self flap 1 twist-speed-x) (lerp-scale 1.0 8.0 f30-0 4096.0 122880.0) (* 10.0 (seconds-per-frame)))
|
||||
)
|
||||
(let ((f0-71 (+ (-> self flap 1 twist z) (* (-> self flap 1 twist-speed-x) (seconds-per-frame)))))
|
||||
(set! (-> self flap 1 twist z) (- f0-71 (* (the float (the int (/ f0-71 1.0))) 1.0)))
|
||||
)
|
||||
(trs-set!
|
||||
(-> self flap 1)
|
||||
(the-as vector #f)
|
||||
(quaternion-rotate-x!
|
||||
(new 'stack-no-clear 'quaternion)
|
||||
(the-as quaternion *null-vector*)
|
||||
(* (sin (* 32768.0 (-> self flap 1 twist z))) (-> self flap 1 twist-max z))
|
||||
)
|
||||
(the-as vector #f)
|
||||
)
|
||||
(update-anim-data (-> self skel))
|
||||
(do-joint-math (-> self draw) (-> self node-list) (-> self skel))
|
||||
)
|
||||
(when *display-sidekick-stats*
|
||||
(format *stdcon* "~%")
|
||||
@@ -537,11 +491,11 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
;; (let ((a0-84 (-> self skel effect)))
|
||||
;; (if a0-84
|
||||
;; (effect-control-method-9 a0-84)
|
||||
;; )
|
||||
;; )
|
||||
(let ((a0-84 (-> self skel effect)))
|
||||
(if a0-84
|
||||
(effect-control-method-9 a0-84)
|
||||
)
|
||||
)
|
||||
(if (logtest? (-> self skel status) (joint-control-status blend-shape blend-shape-valid))
|
||||
(merc-blend-shape self)
|
||||
)
|
||||
|
||||
@@ -2201,7 +2201,7 @@
|
||||
:radius 2048.0
|
||||
:duration 300.0
|
||||
:duration-rand 90.0
|
||||
:sound (static-sound-spec "transform-zap" :group 1)
|
||||
:sound (static-sound-spec "transform-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
@@ -905,7 +905,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -915,7 +915,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -928,7 +928,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((or (and (= arg1 (pickup-type eco-red)) (= v1-2 (pickup-type eco-yellow)))
|
||||
@@ -942,7 +942,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-yellow)) (= v1-2 (pickup-type eco-red)))
|
||||
@@ -954,7 +954,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-red)) (= v1-2 (pickup-type eco-blue)))
|
||||
@@ -966,7 +966,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-2 (pickup-type eco-red)))
|
||||
@@ -978,7 +978,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-yellow)) (= v1-2 (pickup-type eco-blue)))
|
||||
@@ -990,7 +990,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 v1-2) (= v1-2 (pickup-type eco-blue)))
|
||||
@@ -1002,7 +1002,7 @@
|
||||
0
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-2 (pickup-type eco-yellow)))
|
||||
@@ -1014,7 +1014,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-dark)) (= v1-2 (pickup-type eco-yellow)))
|
||||
@@ -1026,7 +1026,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-dark)) (= v1-2 (pickup-type eco-blue)))
|
||||
@@ -1038,7 +1038,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-2 (pickup-type eco-dark)))
|
||||
@@ -1050,7 +1050,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-yellow)) (= v1-2 (pickup-type eco-dark)))
|
||||
@@ -1062,7 +1062,7 @@
|
||||
0
|
||||
-1.0
|
||||
0.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1081,7 +1081,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -1091,7 +1091,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1109,7 +1109,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -1119,7 +1119,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1133,7 +1133,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -1143,7 +1143,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1157,7 +1157,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -1167,7 +1167,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-3" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-3" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1181,7 +1181,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-2" :group 0))
|
||||
)
|
||||
(push-anim-to-targ
|
||||
(-> self skel top-anim)
|
||||
@@ -1191,7 +1191,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-3" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-3" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -1204,7 +1204,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-yellow)) (= v1-60 (pickup-type eco-dark)))
|
||||
@@ -1216,7 +1216,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-1" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-red)) (= v1-60 (pickup-type eco-blue)))
|
||||
@@ -1228,7 +1228,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-dark)) (= v1-60 (pickup-type eco-blue)))
|
||||
@@ -1240,7 +1240,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-60 (pickup-type eco-red)))
|
||||
@@ -1252,7 +1252,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-5" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-5" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-60 (pickup-type eco-dark)))
|
||||
@@ -1264,7 +1264,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-5" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-5" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-yellow)) (= v1-60 (pickup-type eco-blue)))
|
||||
@@ -1276,7 +1276,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-4" :group 0))
|
||||
)
|
||||
)
|
||||
((and (= arg1 (pickup-type eco-blue)) (= v1-60 (pickup-type eco-yellow)))
|
||||
@@ -1288,7 +1288,7 @@
|
||||
19
|
||||
1.0
|
||||
2.0
|
||||
(the-as symbol (static-sound-spec "gun-trans-6" :group 1))
|
||||
(the-as symbol (static-sound-spec "gun-trans-6" :group 0))
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -194,6 +194,21 @@
|
||||
(define-extern *pilot-get-on-mods* surface)
|
||||
(define-extern *pilot-get-off-mods* surface)
|
||||
|
||||
;; target-turret
|
||||
(define-extern *turret-get-on-mods* surface)
|
||||
|
||||
;; target-indax
|
||||
(define-extern *indax-walk-mods* surface)
|
||||
(define-extern *indax-jump-mods* surface)
|
||||
(define-extern *indax-double-jump-mods* surface)
|
||||
(define-extern *indax-bounce-mods* surface)
|
||||
(define-extern target-indax-exit (function none :behavior target))
|
||||
|
||||
;; target-indax-hang
|
||||
(define-extern *indax-hang-walk-mods* surface)
|
||||
(define-extern *indax-hang-dodge-mods* surface)
|
||||
(define-extern *indax-hang-attack-mods* surface)
|
||||
|
||||
;; +++lightjak-stage
|
||||
(defenum lightjak-stage
|
||||
:bitfield #t
|
||||
@@ -246,7 +261,8 @@
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(deftype target (process-focusable)
|
||||
((fact fact-info-target :override)
|
||||
((self target :override)
|
||||
(fact fact-info-target :override)
|
||||
(control control-info :overlay-at root)
|
||||
(skel2 joint-control)
|
||||
(shadow-backup shadow-geo)
|
||||
@@ -431,16 +447,21 @@
|
||||
target-ice-stance
|
||||
target-ice-walk
|
||||
target-indax-attack
|
||||
target-indax-attack-air
|
||||
target-indax-death
|
||||
target-indax-double-jump
|
||||
target-indax-falling
|
||||
(target-indax-attack-air symbol)
|
||||
(target-indax-death symbol)
|
||||
(target-indax-double-jump float float)
|
||||
(target-indax-falling symbol)
|
||||
target-indax-get-off
|
||||
target-indax-grab
|
||||
(target-indax-grab symbol)
|
||||
target-indax-hang
|
||||
target-indax-hit
|
||||
target-indax-hit-ground
|
||||
target-indax-jump
|
||||
target-indax-hang-attack
|
||||
target-indax-hang-dodge
|
||||
target-indax-hang-stance
|
||||
target-indax-hang-turn-around
|
||||
target-indax-hang-walk
|
||||
(target-indax-hit symbol attack-info)
|
||||
(target-indax-hit-ground symbol)
|
||||
(target-indax-jump float float surface)
|
||||
target-indax-running-attack
|
||||
target-indax-stance
|
||||
(target-indax-start handle object)
|
||||
|
||||
@@ -286,14 +286,7 @@
|
||||
)
|
||||
(set! sv-128 *launch-matrix*)
|
||||
(set! sv-112 (-> sv-128 trans))
|
||||
(let ((v1-6 (-> (process-drawable-random-point!
|
||||
(the-as process-drawable (ppointer->process arg1))
|
||||
(new 'stack-no-clear 'vector)
|
||||
)
|
||||
quad
|
||||
)
|
||||
)
|
||||
)
|
||||
(let ((v1-6 (-> (process-drawable-random-point! (ppointer->process arg1) (new 'stack-no-clear 'vector)) quad)))
|
||||
(set! (-> sv-112 quad) v1-6)
|
||||
)
|
||||
(let ((a3-1 #f)
|
||||
@@ -315,7 +308,7 @@
|
||||
)
|
||||
(process-drawable2-shock-effect
|
||||
(the-as process-drawable (handle->process arg0))
|
||||
(the-as process-drawable (ppointer->process arg1))
|
||||
(ppointer->process arg1)
|
||||
(-> *lightning-spec-id-table* 10)
|
||||
lightning-probe-callback
|
||||
(-> *part-id-table* 187)
|
||||
@@ -327,7 +320,7 @@
|
||||
)
|
||||
(send-event (handle->process arg0) 'color-effect 'shock (seconds 0.2))
|
||||
(process-drawable-shock-effect
|
||||
(the-as process-drawable (ppointer->process arg1))
|
||||
(ppointer->process arg1)
|
||||
(-> *lightning-spec-id-table* 10)
|
||||
lightning-probe-callback
|
||||
(-> *part-id-table* 187)
|
||||
|
||||
@@ -2499,7 +2499,8 @@
|
||||
)
|
||||
|
||||
(deftype freeze-watcher (process)
|
||||
((old-clock clock)
|
||||
((parent (pointer process-focusable) :override)
|
||||
(old-clock clock)
|
||||
)
|
||||
(:state-methods
|
||||
(active clock)
|
||||
@@ -2532,18 +2533,16 @@
|
||||
)
|
||||
)
|
||||
(and v1-31
|
||||
(or (focus-test? (the-as process-focusable v1-31) dead hit)
|
||||
(and (-> (the-as process-focusable v1-31) next-state)
|
||||
(let ((v1-34 (-> (the-as process-focusable v1-31) next-state name)))
|
||||
(or (= v1-34 'hit)
|
||||
(= v1-34 'knocked)
|
||||
(= v1-34 'knocked-recover)
|
||||
(= v1-34 'die)
|
||||
(= v1-34 'die-falling)
|
||||
(= v1-34 'die-fast)
|
||||
)
|
||||
)
|
||||
)
|
||||
(or (focus-test? v1-31 dead hit) (and (-> v1-31 next-state) (let ((v1-34 (-> v1-31 next-state name)))
|
||||
(or (= v1-34 'hit)
|
||||
(= v1-34 'knocked)
|
||||
(= v1-34 'knocked-recover)
|
||||
(= v1-34 'die)
|
||||
(= v1-34 'die-falling)
|
||||
(= v1-34 'die-fast)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(not (time-elapsed? gp-0 (seconds 5)))
|
||||
)
|
||||
@@ -3041,7 +3040,7 @@
|
||||
(init-vf0-vector)
|
||||
(let* ((gp-0 (ppointer->process (-> self parent)))
|
||||
(s3-0 (if (type? gp-0 process-focusable)
|
||||
(the-as process-focusable gp-0)
|
||||
gp-0
|
||||
)
|
||||
)
|
||||
(s4-0 (camera-matrix))
|
||||
|
||||
@@ -2761,7 +2761,7 @@
|
||||
:merge-count 2
|
||||
:radius 2048.0
|
||||
:duration 30.0
|
||||
:sound (static-sound-spec "shock" :group 1)
|
||||
:sound (static-sound-spec "shock" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2780,7 +2780,7 @@
|
||||
:merge-count 2
|
||||
:radius 2048.0
|
||||
:duration 30.0
|
||||
:sound (static-sound-spec "shock" :group 1)
|
||||
:sound (static-sound-spec "shock" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2799,7 +2799,7 @@
|
||||
:merge-count 2
|
||||
:radius 2048.0
|
||||
:duration 30.0
|
||||
:sound (static-sound-spec "shock" :group 1)
|
||||
:sound (static-sound-spec "shock" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2818,7 +2818,7 @@
|
||||
:merge-count 2
|
||||
:radius 2048.0
|
||||
:duration 30.0
|
||||
:sound (static-sound-spec "shock" :group 1)
|
||||
:sound (static-sound-spec "shock" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -2837,7 +2837,7 @@
|
||||
:merge-count 2
|
||||
:radius 1228.8
|
||||
:duration 30.0
|
||||
:sound (static-sound-spec "shock" :group 1)
|
||||
:sound (static-sound-spec "shock" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -3537,7 +3537,7 @@
|
||||
:radius 1638.4
|
||||
:duration 30.0
|
||||
:duration-rand 90.0
|
||||
:sound (static-sound-spec "transform-zap" :group 1)
|
||||
:sound (static-sound-spec "transform-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -3557,7 +3557,7 @@
|
||||
:radius 1638.4
|
||||
:duration 30.0
|
||||
:duration-rand 90.0
|
||||
:sound (static-sound-spec "transform-zap" :group 1)
|
||||
:sound (static-sound-spec "transform-zap" :group 0)
|
||||
:delay 60.0
|
||||
:delay-rand 120.0
|
||||
)
|
||||
@@ -3882,7 +3882,7 @@
|
||||
:radius 1638.4
|
||||
:duration 30.0
|
||||
:duration-rand 150.0
|
||||
:sound (static-sound-spec "transform-zap" :group 1)
|
||||
:sound (static-sound-spec "transform-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
@@ -3903,7 +3903,7 @@
|
||||
:radius 1638.4
|
||||
:duration 30.0
|
||||
:duration-rand 150.0
|
||||
:sound (static-sound-spec "stretched-zap" :group 1)
|
||||
:sound (static-sound-spec "stretched-zap" :group 0)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
@@ -295,7 +295,7 @@
|
||||
'player-got-on-vehicle-child
|
||||
(the-as vehicle s4-1)
|
||||
)
|
||||
(set! (-> s5-0 stance) (the-as uint (vehicle-method-70 (the-as vehicle s4-1))))
|
||||
(set! (-> s5-0 stance) (vehicle-method-70 (the-as vehicle s4-1)))
|
||||
(let ((s3-0 (vehicle-method-65 (the-as vehicle s4-1))))
|
||||
(dotimes (s2-0 s3-0)
|
||||
(let ((a0-35 (get-rider-in-seat (the-as vehicle s4-1) s2-0)))
|
||||
|
||||
@@ -430,14 +430,13 @@
|
||||
)
|
||||
)
|
||||
(('tube)
|
||||
(cond
|
||||
((focus-test? self indax)
|
||||
enter-state
|
||||
(-> *TARGET-bank* tube-jump-height-min)
|
||||
(-> *TARGET-bank* tube-jump-height-max)
|
||||
(go target-indax-jump)
|
||||
)
|
||||
(else
|
||||
(if (focus-test? self indax)
|
||||
(go
|
||||
target-indax-jump
|
||||
(-> *TARGET-bank* tube-jump-height-min)
|
||||
(-> *TARGET-bank* tube-jump-height-max)
|
||||
(the-as surface #f)
|
||||
)
|
||||
(go
|
||||
target-jump
|
||||
(-> *TARGET-bank* tube-jump-height-min)
|
||||
@@ -445,7 +444,6 @@
|
||||
(the-as surface #f)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@@ -666,16 +664,10 @@
|
||||
(and (< 4096.0 (target-height-above-ground)) (!= (-> self control gspot-pat-surfce event) 7))
|
||||
)
|
||||
(set! (-> self control unknown-float0000) (+ -24576.0 (-> self tube centertube y)))
|
||||
(cond
|
||||
((focus-test? self indax)
|
||||
enter-state
|
||||
'tube
|
||||
(go target-indax-falling)
|
||||
)
|
||||
(else
|
||||
(if (focus-test? self indax)
|
||||
(go target-indax-falling 'tube)
|
||||
(go target-falling 'tube)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
@@ -902,16 +894,10 @@
|
||||
(('endlessfall)
|
||||
(when (= (-> self game mode) 'play)
|
||||
(pickup-collectable! (-> self fact) (pickup-type health) -1000.0 (the-as handle #f))
|
||||
(cond
|
||||
((focus-test? self indax)
|
||||
enter-state
|
||||
(-> gp-0 mode)
|
||||
(go target-indax-death)
|
||||
)
|
||||
(else
|
||||
(if (focus-test? self indax)
|
||||
(go target-indax-death (-> gp-0 mode))
|
||||
(go target-death (-> gp-0 mode))
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(('lava 'melt)
|
||||
|
||||
@@ -7,3 +7,415 @@
|
||||
|
||||
;; DECOMP BEGINS
|
||||
|
||||
(defpart 1013
|
||||
:init-specs ((:texture (gun-yellow-beam level-default-sprite))
|
||||
(:birth-func 'birth-func-set-quat)
|
||||
(:num 1.0)
|
||||
(:scale-x (meters 0.4))
|
||||
(:scale-y (meters 9))
|
||||
(:r 128.0)
|
||||
(:g 0.0 64.0)
|
||||
(:b 0.0)
|
||||
(:a 128.0)
|
||||
(:scalevel-x (meters 0.0016666667))
|
||||
(:fade-a -2.1333334)
|
||||
(:timer (seconds 0.135))
|
||||
(:flags (sp-cpuinfo-flag-2 sp-cpuinfo-flag-14 left-multiply-quat))
|
||||
)
|
||||
)
|
||||
|
||||
(defpartgroup group-turret-shot-hit
|
||||
:id 234
|
||||
:duration (seconds 1)
|
||||
:flags (sp0)
|
||||
:bounds (static-bspherem 0 0 0 8)
|
||||
:parts ((sp-item 1014 :flags (sp6) :period (seconds 2) :length (seconds 0.017))
|
||||
(sp-item 1015 :flags (sp6) :period (seconds 2) :length (seconds 0.017))
|
||||
(sp-item 1016 :flags (sp6) :period (seconds 2) :length (seconds 0.017))
|
||||
(sp-item 1017 :period (seconds 2) :length (seconds 0.017))
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1015
|
||||
:init-specs ((:texture (glow level-default-sprite))
|
||||
(:num 2.0)
|
||||
(:scale-x (meters 1))
|
||||
(:rot-x (degrees 2.25))
|
||||
(:rot-z (degrees 0) (degrees 360))
|
||||
(:scale-y :copy scale-x)
|
||||
(:r 255.0)
|
||||
(:g 32.0)
|
||||
(:b 32.0 8.0)
|
||||
(:a 24.0)
|
||||
(:scalevel-x (meters 0.12857144))
|
||||
(:rotvel-z (degrees -0.3) (degrees 0.6))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-g -3.6571429)
|
||||
(:fade-b -0.9142857)
|
||||
(:timer (seconds 0.267))
|
||||
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-2 glow))
|
||||
(:userdata 4096.0)
|
||||
(:next-time (seconds 0.117))
|
||||
(:next-launcher 1018)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1018
|
||||
:init-specs ((:scale-x (meters 4.5))
|
||||
(:scale-y :copy scale-x)
|
||||
(:scalevel-x (meters -0.08888889))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-g -3.1111112)
|
||||
(:fade-b 0.0)
|
||||
(:fade-a -1.0666667)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1014
|
||||
:init-specs ((:texture (glow-soft level-default-sprite))
|
||||
(:num 1.0)
|
||||
(:scale-x (meters 0.5))
|
||||
(:rot-x (degrees 0.5625))
|
||||
(:rot-z (degrees 0) (degrees 360))
|
||||
(:scale-y :copy scale-x)
|
||||
(:r 255.0)
|
||||
(:g 32.0)
|
||||
(:b 255.0)
|
||||
(:a 64.0)
|
||||
(:scalevel-x (meters 0.16666667))
|
||||
(:rotvel-z (degrees 0.3))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:timer (seconds 0.335))
|
||||
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-2 sp-cpuinfo-flag-3 glow))
|
||||
(:userdata 4096.0)
|
||||
(:next-time (seconds 0.05))
|
||||
(:next-launcher 1019)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1019
|
||||
:init-specs ((:scale-x (meters 3.5))
|
||||
(:scale-y :copy scale-x)
|
||||
(:scalevel-x (meters -0.025))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-b -6.375)
|
||||
(:next-time (seconds 0.135))
|
||||
(:next-launcher 1020)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1020
|
||||
:init-specs ((:scale-x (meters 2))
|
||||
(:scale-y :copy scale-x)
|
||||
(:scalevel-x (meters -0.025))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-r 0.0)
|
||||
(:fade-g -1.6)
|
||||
(:fade-b 0.0)
|
||||
(:fade-a -1.6)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1016
|
||||
:init-specs ((:texture (explosion-nebula level-default-sprite))
|
||||
(:num 1.0)
|
||||
(:scale-x (meters 3) (meters 0.4))
|
||||
(:rot-x (degrees 1.125))
|
||||
(:rot-z (degrees 0) (degrees 3600))
|
||||
(:scale-y :copy scale-x)
|
||||
(:r 255.0)
|
||||
(:g 0.0)
|
||||
(:b 0.0)
|
||||
(:a 64.0)
|
||||
(:scalevel-x (meters 0.075))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-a -1.8285714)
|
||||
(:timer (seconds 0.135))
|
||||
(:flags (sp-cpuinfo-flag-2 sp-cpuinfo-flag-3 glow))
|
||||
(:userdata 4096.0)
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1017
|
||||
:init-specs ((:texture (bigpuff level-default-sprite))
|
||||
(:num 6.0 6.0)
|
||||
(:scale-x (meters 1.25) (meters 1))
|
||||
(:rot-z (degrees 0) (degrees 3600))
|
||||
(:scale-y :copy scale-x)
|
||||
(:r 255.0)
|
||||
(:g 0.0)
|
||||
(:b 0.0)
|
||||
(:a 16.0 48.0)
|
||||
(:vel-y (meters 0.026666667) (meters 0.026666667))
|
||||
(:scalevel-x (meters 0.0016666667) (meters 0.006666667))
|
||||
(:rotvel-z (degrees -0.2) (degrees 0.4))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-r -0.30476192)
|
||||
(:fade-g 0.15238096)
|
||||
(:fade-b 0.30476192)
|
||||
(:fade-a -0.15238096)
|
||||
(:accel-y (meters -0.00016666666) (meters -0.00016666666))
|
||||
(:friction 0.9)
|
||||
(:timer (seconds 1.4))
|
||||
(:flags (sp-cpuinfo-flag-2 sp-cpuinfo-flag-3))
|
||||
(:conerot-x (degrees 0) (degrees 3600))
|
||||
(:conerot-y (degrees 0) (degrees 3600))
|
||||
)
|
||||
)
|
||||
|
||||
(defpart 1021
|
||||
:init-specs ((:texture (radial-gradient level-default-sprite))
|
||||
(:num 4.0 4.0)
|
||||
(:z (meters 0) (meters -3))
|
||||
(:scale-x (meters 0.8) (meters 0.4))
|
||||
(:scale-y (meters 0.8) (meters 0.4))
|
||||
(:r 192.0)
|
||||
(:g 64.0 128.0)
|
||||
(:b 0.0)
|
||||
(:a 64.0)
|
||||
(:scalevel-x (meters -0.00234375))
|
||||
(:scalevel-y :copy scalevel-x)
|
||||
(:fade-g -1.2 -2.4)
|
||||
(:fade-a -1.6 -6.4)
|
||||
(:accel-y (meters -0.00016666666) (meters -0.00016666666))
|
||||
(:timer (seconds 0.8))
|
||||
(:flags (sp-cpuinfo-flag-0 sp-cpuinfo-flag-2 sp-cpuinfo-flag-3))
|
||||
(:rotate-y (degrees 0))
|
||||
)
|
||||
)
|
||||
|
||||
(deftype turret-shot (guard-shot)
|
||||
((hit-pos vector :inline)
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
(defstate impact (turret-shot)
|
||||
:virtual #t
|
||||
:event (behavior ((proc process) (argc int) (message symbol) (block event-message-block))
|
||||
(case message
|
||||
(('touched)
|
||||
(let* ((s4-0 proc)
|
||||
(v1-1 (if (type? s4-0 process-drawable)
|
||||
s4-0
|
||||
)
|
||||
)
|
||||
)
|
||||
(when v1-1
|
||||
(-> (the-as process-drawable v1-1) root)
|
||||
(send-event
|
||||
proc
|
||||
'attack
|
||||
(-> block param 0)
|
||||
(static-attack-info :mask (vehicle-impulse-factor) ((id (-> self attack-id))
|
||||
(damage (-> self damage))
|
||||
(vehicle-damage-factor 1.0)
|
||||
(vehicle-impulse-factor 1.0)
|
||||
(mode 'explode)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(else
|
||||
(projectile-event-handler proc argc message block)
|
||||
)
|
||||
)
|
||||
)
|
||||
:code (behavior ()
|
||||
(let ((v1-1 (-> self root root-prim)))
|
||||
(set! (-> (the-as collide-shape-prim-group v1-1) child 0 prim-core world-sphere w) 4915.2)
|
||||
)
|
||||
(let ((a1-0 (new 'stack-no-clear 'overlaps-others-params)))
|
||||
(set! (-> a1-0 options) (overlaps-others-options))
|
||||
(set! (-> a1-0 collide-with-filter) (the-as collide-spec -1))
|
||||
(set! (-> a1-0 tlist) *touching-list*)
|
||||
(find-overlapping-shapes (-> self root) a1-0)
|
||||
)
|
||||
(suspend)
|
||||
(go-virtual die)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod projectile-method-25 ((this turret-shot))
|
||||
(rlet ((acc :class vf)
|
||||
(vf0 :class vf)
|
||||
(vf4 :class vf)
|
||||
(vf5 :class vf)
|
||||
(vf6 :class vf)
|
||||
(vf7 :class vf)
|
||||
)
|
||||
(init-vf0-vector)
|
||||
(let* ((gp-0 (-> this root trans))
|
||||
(a1-0 (-> this tail-pos))
|
||||
(s5-1 (vector-! (new 'stack-no-clear 'vector) gp-0 a1-0))
|
||||
(f30-0 (vector-length s5-1))
|
||||
)
|
||||
(let ((s4-0 (new 'stack-no-clear 'vector)))
|
||||
(let ((v1-4 a1-0))
|
||||
(let ((a0-2 s5-1))
|
||||
(let ((a2-1 0.8))
|
||||
(.mov vf7 a2-1)
|
||||
)
|
||||
(.lvf vf5 (&-> a0-2 quad))
|
||||
)
|
||||
(.lvf vf4 (&-> v1-4 quad))
|
||||
)
|
||||
(.add.x.vf vf6 vf0 vf0 :mask #b1000)
|
||||
(.mul.x.vf acc vf5 vf7 :mask #b111)
|
||||
(.add.mul.w.vf vf6 vf4 vf0 acc :mask #b111)
|
||||
(.svf (&-> s4-0 quad) vf6)
|
||||
(let ((f28-0 (-> *part-id-table* 1013 init-specs 4 initial-valuef)))
|
||||
(set! (-> *part-id-table* 1013 init-specs 4 initial-valuef) (vector-length s5-1))
|
||||
(draw-beam (-> *part-id-table* 1013) a1-0 s5-1 #f)
|
||||
(set! (-> *part-id-table* 1013 init-specs 4 initial-valuef) f28-0)
|
||||
)
|
||||
(vector-normalize! s5-1 1.0)
|
||||
(launch-particles (-> *part-id-table* 851) s4-0)
|
||||
(launch-particles (-> *part-id-table* 852) s4-0)
|
||||
)
|
||||
(let ((s4-1 (new 'stack-no-clear 'matrix))
|
||||
(f26-0 (* 0.000027126736 f30-0))
|
||||
(f30-1 (-> *part-id-table* 1021 init-specs 3 initial-valuef))
|
||||
(f28-1 (-> *part-id-table* 1021 init-specs 4 initial-valuef))
|
||||
)
|
||||
(forward-up->inv-matrix s4-1 s5-1 *up-vector*)
|
||||
(set! (-> s4-1 trans quad) (-> gp-0 quad))
|
||||
(set! (-> *part-id-table* 1021 init-specs 3 initial-valuef) (* f26-0 f30-1))
|
||||
(set! (-> *part-id-table* 1021 init-specs 4 initial-valuef) (* f26-0 f28-1))
|
||||
(launch-particles (-> *part-id-table* 1021) s4-1 :origin-is-matrix #t)
|
||||
(set! (-> *part-id-table* 1021 init-specs 3 initial-valuef) f30-1)
|
||||
(set! (-> *part-id-table* 1021 init-specs 4 initial-valuef) f28-1)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
)
|
||||
|
||||
(defmethod projectile-method-26 ((this turret-shot))
|
||||
(let* ((gp-0 (-> this root))
|
||||
(a0-3 (vector-normalize! (vector-! (new 'stack-no-clear 'vector) (-> this tail-pos) (-> gp-0 trans)) 2048.0))
|
||||
(v1-2 (new 'stack-no-clear 'vector))
|
||||
)
|
||||
(set! (-> v1-2 quad) (-> gp-0 trans quad))
|
||||
(vector+! v1-2 v1-2 a0-3)
|
||||
(cond
|
||||
((logtest? (-> *part-group-id-table* 234 flags) (sp-group-flag sp13))
|
||||
(set! (-> *launch-matrix* trans quad) (-> v1-2 quad))
|
||||
(part-tracker-spawn part-tracker-subsampler :to *entity-pool* :group (-> *part-group-id-table* 234))
|
||||
)
|
||||
(else
|
||||
(set! (-> *launch-matrix* trans quad) (-> v1-2 quad))
|
||||
(part-tracker-spawn part-tracker :to *entity-pool* :group (-> *part-group-id-table* 234))
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod play-impact-sound ((this turret-shot) (arg0 projectile-options))
|
||||
(let ((v1-0 arg0))
|
||||
(cond
|
||||
((zero? v1-0)
|
||||
(sound-play "for-turret-fire" :position (-> this root trans))
|
||||
)
|
||||
((= v1-0 (projectile-options po0))
|
||||
(sound-play "for-turret-hit")
|
||||
)
|
||||
)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
;; WARN: Return type mismatch projectile-options vs none.
|
||||
(defmethod init-proj-settings! ((this turret-shot))
|
||||
(set! (-> this tail-pos quad) (-> this root trans quad))
|
||||
(cpad-set-buzz! (-> *cpad-list* cpads 0) 1 204 (seconds 0.1))
|
||||
(set! (-> this attack-mode) 'eco-yellow)
|
||||
(set! (-> this max-speed) 1228800.0)
|
||||
(set! (-> this move) guard-shot-move)
|
||||
(set! (-> this damage) 1.0)
|
||||
(set! (-> this vehicle-impulse-factor) 2.0)
|
||||
(logior! (-> this options) (projectile-options po13))
|
||||
(none)
|
||||
)
|
||||
|
||||
(defmethod setup-collision! ((this turret-shot))
|
||||
(let ((s5-0 (new 'process 'collide-shape-moving this (collide-list-enum hit-by-player))))
|
||||
(set! (-> s5-0 dynam) (copy *standard-dynamics* 'process))
|
||||
(set! (-> s5-0 reaction)
|
||||
(the-as (function control-info collide-query vector vector collide-status) cshape-reaction-just-move)
|
||||
)
|
||||
(set! (-> s5-0 no-reaction)
|
||||
(the-as (function collide-shape-moving collide-query vector vector object) nothing)
|
||||
)
|
||||
(set! (-> s5-0 penetrate-using) (penetrate enemy-yellow-shot))
|
||||
(let ((s4-0 (new 'process 'collide-shape-prim-group s5-0 (the-as uint 2) 0)))
|
||||
(set! (-> s5-0 total-prims) (the-as uint 3))
|
||||
(set! (-> s4-0 prim-core collide-as) (collide-spec projectile))
|
||||
(set! (-> s4-0 prim-core collide-with)
|
||||
(collide-spec
|
||||
backgnd
|
||||
jak
|
||||
bot
|
||||
crate
|
||||
civilian
|
||||
enemy
|
||||
obstacle
|
||||
vehicle-sphere
|
||||
hit-by-others-list
|
||||
player-list
|
||||
obstacle-for-jak
|
||||
)
|
||||
)
|
||||
(set! (-> s4-0 prim-core action) (collide-action solid))
|
||||
(set-vector! (-> s4-0 local-sphere) 0.0 0.0 0.0 4915.2)
|
||||
(set! (-> s5-0 root-prim) s4-0)
|
||||
)
|
||||
(let ((v1-13 (new 'process 'collide-shape-prim-sphere s5-0 (the-as uint 0))))
|
||||
(set! (-> v1-13 prim-core collide-as) (collide-spec projectile))
|
||||
(set! (-> v1-13 prim-core collide-with)
|
||||
(collide-spec
|
||||
backgnd
|
||||
jak
|
||||
bot
|
||||
crate
|
||||
civilian
|
||||
enemy
|
||||
obstacle
|
||||
vehicle-sphere
|
||||
hit-by-others-list
|
||||
player-list
|
||||
obstacle-for-jak
|
||||
)
|
||||
)
|
||||
(set! (-> v1-13 prim-core action) (collide-action solid deadly))
|
||||
(set-vector! (-> v1-13 local-sphere) 0.0 0.0 0.0 2048.0)
|
||||
)
|
||||
(let ((v1-15 (new 'process 'collide-shape-prim-sphere s5-0 (the-as uint 0))))
|
||||
(set! (-> v1-15 prim-core collide-as) (collide-spec projectile))
|
||||
(set! (-> v1-15 prim-core collide-with)
|
||||
(collide-spec jak bot crate civilian enemy vehicle-sphere hit-by-others-list player-list obstacle-for-jak)
|
||||
)
|
||||
(set! (-> v1-15 prim-core action) (collide-action deadly))
|
||||
(set-vector! (-> v1-15 local-sphere) 0.0 0.0 0.0 7372.8)
|
||||
)
|
||||
(set! (-> s5-0 nav-radius) (* 0.75 (-> s5-0 root-prim local-sphere w)))
|
||||
(let ((v1-18 (-> s5-0 root-prim)))
|
||||
(set! (-> s5-0 backup-collide-as) (-> v1-18 prim-core collide-as))
|
||||
(set! (-> s5-0 backup-collide-with) (-> v1-18 prim-core collide-with))
|
||||
)
|
||||
(set! (-> s5-0 max-iteration-count) (the-as uint 1))
|
||||
(set! (-> s5-0 event-self) 'touched)
|
||||
(set! (-> this root) s5-0)
|
||||
)
|
||||
(set! (-> this root pat-ignore-mask)
|
||||
(new 'static 'pat-surface :noentity #x1 :nojak #x1 :probe #x1 :noproj #x1 :noendlessfall #x1 :board #x1)
|
||||
)
|
||||
0
|
||||
(none)
|
||||
)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1868,7 +1868,7 @@
|
||||
(defstate target-float (target)
|
||||
:event target-generic-event-handler
|
||||
:enter (behavior ()
|
||||
(sound-play-by-spec (static-sound-spec "menu-pick" :group 1 :fo-curve 1) (new-sound-id) (the-as vector #t))
|
||||
(sound-play-by-spec (static-sound-spec "menu-pick" :group 0 :fo-curve 1) (new-sound-id) (the-as vector #t))
|
||||
(set! (-> self control additional-decaying-velocity-end-time) 0)
|
||||
(vector-reset! (-> self control additional-decaying-velocity))
|
||||
(let ((v1-3 (new-stack-vector0)))
|
||||
@@ -1894,7 +1894,7 @@
|
||||
(target-lightjak-end-mode #t)
|
||||
)
|
||||
:exit (behavior ()
|
||||
(sound-play-by-spec (static-sound-spec "menu-back" :group 1 :fo-curve 1) (new-sound-id) (the-as vector #t))
|
||||
(sound-play-by-spec (static-sound-spec "menu-back" :group 0 :fo-curve 1) (new-sound-id) (the-as vector #t))
|
||||
(set! (-> self control dynam gravity-max) (-> self control standard-dynamics gravity-max))
|
||||
(set! (-> self control dynam gravity-length) (-> self control standard-dynamics gravity-length))
|
||||
(target-exit)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user