
TCGreflexhammer
Joined: Jul 5, 2016
"""Quality Content"""
|
Posted: Jul 14, 2016 12:59 AM
Msg. 1 of 8
how do I get respawning to work in single player. Do I have to do some trickery with teleporting the player and such or is there an option to just turn it on?
|
|
|

MatthewDratt
Joined: Sep 11, 2010
TAKEDOWN IS OUT MattDratt.com
|
Posted: Jul 14, 2016 02:28 AM
Msg. 2 of 8
there is a script command (game_save) that'll create checkpoints, so when the player dies they'll restart there. Is this what you mean?
|
|
|

TCGreflexhammer
Joined: Jul 5, 2016
"""Quality Content"""
|
Posted: Jul 14, 2016 02:31 AM
Msg. 3 of 8
No, like in the firefight map Decent you can respawn and select a loadout. I'd like to do that minus the loadouts of course
|
|
|

Skidrow925
Joined: Mar 19, 2010
"ideological sense of respect and tact of a 5yo"
|
Posted: Jul 15, 2016 02:12 PM
Msg. 4 of 8
Is that not just a game save? Perhaps run it as multiplayer?
|
|
|

TCGreflexhammer
Joined: Jul 5, 2016
"""Quality Content"""
|
Posted: Jul 15, 2016 02:21 PM
Msg. 5 of 8
I tried building it as a multiplayer level but tool said the cache file was too big. As for the saving check points, tried using the save option in the pause menu but didn't work (or maybe its something I have to setup).
|
|
|

Skidrow925
Joined: Mar 19, 2010
"ideological sense of respect and tact of a 5yo"
|
Posted: Jul 15, 2016 02:34 PM
Msg. 6 of 8
Wonder if you could just make a script so that if the players health is low enough they are "killed" and "respawned". Kirby probably has a better method, but since its too big for MP (not entirely surprising, most SP maps are).
The save is actually done through scripting anyway, you'd have tp throw a game_save_totally_unsafe so it saves regardless of what's happening. Which is awkward in SP because you can end up in a death loop, where it saves right before you die.
My best guess though would just be to either keep checkpoints like normal SP, or try and do something fancy with fake death or whatever. Ive not played descent in forever so I cant recall how they did it but I'll take a look at that amd try amd whip up a script for you later.
|
|
|

MatthewDratt
Joined: Sep 11, 2010
TAKEDOWN IS OUT MattDratt.com
|
Posted: Jul 16, 2016 01:24 AM
Msg. 7 of 8
The system in FF:D is complicated. What happens is the player cannot die. When the players health hits so low a new dead player biped is spawned ontop of the player. The player is then moved over to a new location (away and safe). A dead-camera script is then used on this new biped (the same script that causes the camera to dead-circle around Keyes if he dies).
While the player is safe away, their health is recharged and the player is shown a new menu screen for loadouts. Using a complicated trick, the weapons from the player are removed and replaced with this new loadout. This complicated trick involves handing the player an oddball that despawns after a couple of seconds. During the oddball exchange, the player is given a blank player profile (with no weapons) to remove their current exchange of guns. The loadout then gives them a new player profile with the new guns.
FF:D comes with the scripts if you're willing to sift through them and figure it out now that you know the system.
|
|
|

Skidrow925
Joined: Mar 19, 2010
"ideological sense of respect and tact of a 5yo"
|
Posted: Jul 16, 2016 02:11 AM
Msg. 8 of 8
SO I (to my surprise) was actually basically correct. Given the lack of needing to reset weapons, that makes life far easier. The trick will just be sorting the script out. (script static void life_lost (if (= (unit_get_health (player)) 0) (begin (set give_me_cupcakes true) (cinematic_screen_effect_stop) (set dead true) (object_create_anew oh_noez) (player_enable_input 0) (set max_lives false) (player_camera_control 0) (objects_attach (unit (list_get (players) 0)) "" oh_noez "") (objects_detach (unit (list_get (players) 0)) oh_noez) (unit_kill oh_noez) (object_teleport (player) hide) (set enemyseeme false) (camera_set_dead oh_noez) (camera_control 1) (player_add_equipment (player) empty true) (object_set_shield (unit (list_get (players) 0)) 0) (object_cannot_take_damage (player)) (if (= deadlycookie false) (sleep 30) ) (if (= deadlycookie true) (begin (set deadlycookie false) (sleep 5) ) ) (if (= natural_male_enhancement false) (set lives (- lives 1)) ) (if (= lives 0) (begin (set kill_messages true) (fade_out 0 0 0 20) (music_stopper) (sleep 15) (enable_hud_help_flash false) (show_hud_help_text false) (player_enable_input 0) (show_hud 0) (sound_looping_predict sound\moooseguy\sound_looping\perilremix) (cinematic_start) (sound_looping_stop levels\a30\music\a30_03) (ai_disregard (player) true) (camera_control 1) (camera_set death1 1) (sleep 15) (object_teleport (player) cutflag) (object_destroy oh_noez) (fade_in 0 0 0 30) (sleep 20) (if (= resume_music true) (sound_looping_start sound\moooseguy\sound_looping\perilremix none 1) ) (object_create_anew deadguy) (camera_set death2 90) (sleep 30) (camera_set death3 100) (sleep 30) (camera_set death4 100) (sleep 50) (camera_set death5 100) (sleep 50) (camera_set death6 100) (sleep 30) (camera_set death7 100) (sleep 50) (camera_set death8 110) (sleep 60) (cinematic_set_title gameover) (sleep 90) (fade_out 0 0 0 30) (sleep 50) (object_destroy oh_noez) (wake credits_cutscene) ) ) (if (!= lives 0) (begin (cinematic_stop) (show_hud true) (fade_out 0 0 0 20) (sleep 20) (camera_set loadout_cam 0) (sleep 10) (fade_in 0 0 0 45) (sleep 20) (display_scenario_help 0) ) ) ) ) ) This is the important part we want to look at. There's a lot in there we don't need, mainly stuff relative to FF:D. I'll leave the sorting up to you or whoever else wants to do it, because I'm just lazy. But hey, I found it for ya.
|
|
|