Ainz Ooal Gown Posted November 23, 2019 Share Posted November 23, 2019 Description: This is a respawn system that I currently use in my games. It is very staright farward but allows your players to set a respawn location you put on your map.  Video: https://www.ascensiongamedev.com/resources/filehost/48a67458f15947e6130fbdb70c3acbd3.mp4  Process: Players can walk up to a respawn point and interact with it to set a respawn location and if they die it will respawn them at that point.  Issue: Event doesnt trigger fast enough, so we create a blank black map and a black image to prevent a "Map Bounce" (what I mean by this is when a player dies he will respawn back to the class set start location before the respawn event kicks in, so the class starter map will show for a split second, before the player is warped to the map set by the respawn system. It will make sense as we go on)  Build:  First we need to make a variable: Type: INTEGER, Name: Player Respawn LOC  Second we need to make a common event Spoiler Way Ive done it is so each new page is a respawn location, so you can make as many locations as you wish.  Make sure each page is TRIGGER= "On Respawn" and has a "Spawn/Execution Condition" of the player respawn location, Like so: PAGE 1 is: IF "Player Respawn LOC" = 1 RUN PAGE 2 is: IF "Player Respawn LOC" = 2 RUN  What is happening here is Show a picture, which is just a black image which is set to full screen. Show Text that player has died Warp player to the location of respawn point Hide image  Page 1 Page 2  Lastly we need to make the respawn points, which I call "Pathfinders", which is just an event on a map. Spoiler So all that is happening here is when a player interactions with the set reswpan loaction is asks do they wish to set location here, if the player hits yes, it sets variable "Player Respawn LOC" to 1  Now you have set the core build of the respawn system, but you have to do one more thing which depends on how you have your game setup. Becuase of the issue I mentioned above, with a slight delay happening on the event trigger to warp player, I have had to set a "Blank" map which I called "Eternity".  I set all my classes in game to have this map "Eternity" as a spawn point Spoiler  So this isnt good for when a new player starts the game, as they will just spawn on a blank map... so you add (which I have in all my games) is a common event "Set New Player Variables". Spoiler This is useful if you have other variables you need to set for a new player joining the game.  Create a new variable and call it "New Player Start Done", variable is a "Boolean" Make sure event "Spawn/Execution condition" is "New Player Start Done = FALSE" Make the event trigger is "Login"  First thing in the common event commands is to warp the player to your actual starting location of your game. Last thing in the common event commands is to set a boolean variable to "TRUE" (this is so event only runs once for a new player)   Complete!  Now you should have a fully working respawn location system in your game.  Enjoy Vio, EternalEssence, Uranochos and 5 others 7 1 Link to comment Share on other sites More sharing options...
AisenArvalis Posted November 23, 2019 Share Posted November 23, 2019 Very nice system AOG! It is almost the exact same system I use but I call the spawn points memory locations. Ainz Ooal Gown 1 Link to comment Share on other sites More sharing options...
Ainz Ooal Gown Posted November 23, 2019 Author Share Posted November 23, 2019 1 minute ago, AisenArvalis said: Very nice system AOG! It is almost the exact same system I use but I call the spawn points memory locations. Â Thanks. Its most simplistic way of doing it, I just thought I make a tutorial as not everyone will get how to do it Link to comment Share on other sites More sharing options...
Lyim Posted February 20, 2020 Share Posted February 20, 2020 It looks like the latest update (B6.1) breaks this. Maybe it's just me but I am pretty sure something breaks now after the sceen goes black. Â All that happens to me now after I die is just the black screen. I have to re-log and teleport to the place I wanna be. Link to comment Share on other sites More sharing options...
Ainz Ooal Gown Posted February 20, 2020 Author Share Posted February 20, 2020 15 hours ago, Mapyo said: It looks like the latest update (B6.1) breaks this. Maybe it's just me but I am pretty sure something breaks now after the sceen goes black. Â All that happens to me now after I die is just the black screen. I have to re-log and teleport to the place I wanna be. Â I will have a look but dont think anything has changed that would affect this system. Link to comment Share on other sites More sharing options...
Ainz Ooal Gown Posted February 20, 2020 Author Share Posted February 20, 2020 18 hours ago, Mapyo said: It looks like the latest update (B6.1) breaks this. Maybe it's just me but I am pretty sure something breaks now after the sceen goes black. Â All that happens to me now after I die is just the black screen. I have to re-log and teleport to the place I wanna be. Â Ive had a look and for some reason when setting and image on respawn it stops the continuation of the event... Â Removing the show image makes the system work. A work around is to hide the player, then show player instead of images. Â I believe this is a bug so I will report it and see what the devs say. Link to comment Share on other sites More sharing options...
jcsnider Posted February 20, 2020 Share Posted February 20, 2020 The picture was rendering above the event text so while it was working there was no way to continue with the event.  Fixed in 0.6.1.229. @Incubugs I think this solves everything for you as well, granted im not sure why I didn't see the issue using your gamedb. Ainz Ooal Gown 1 Link to comment Share on other sites More sharing options...
Lyim Posted February 20, 2020 Share Posted February 20, 2020 (edited) 2 hours ago, Ainz Ooal Gown said:  Ive had a look and for some reason when setting and image on respawn it stops the continuation of the event...  Removing the show image makes the system work. A work around is to hide the player, then show player instead of images.  I believe this is a bug so I will report it and see what the devs say.  54 minutes ago, jcsnider said: The picture was rendering above the event text so while it was working there was no way to continue with the event.  Fixed in 0.6.1.229. @Incubugs I think this solves everything for you as well, granted im not sure why I didn't see the issue using your gamedb.  @Ainz Ooal Gown You were right!  @jcsnider Thanks man!  EDIT: Just upgraded and im still having the problem. Edited February 20, 2020 by Mapyo Link to comment Share on other sites More sharing options...
Ainz Ooal Gown Posted February 20, 2020 Author Share Posted February 20, 2020 1 hour ago, jcsnider said: The picture was rendering above the event text so while it was working there was no way to continue with the event.  Fixed in 0.6.1.229. @Incubugs I think this solves everything for you as well, granted im not sure why I didn't see the issue using your gamedb. Thanks JC Link to comment Share on other sites More sharing options...
jcsnider Posted February 21, 2020 Share Posted February 21, 2020 @Mapyo 0.6.1.229 hasn't built yet XD Link to comment Share on other sites More sharing options...
Lyim Posted February 21, 2020 Share Posted February 21, 2020 20 hours ago, jcsnider said: @Mapyo 0.6.1.229 hasn't built yet XD Â I'm an idiot, I was high when I upgraded (its legal in canada) and completley flew over the version number haha. Minamoto Yoshitsune 1 Link to comment Share on other sites More sharing options...
nvh Posted July 8, 2021 Share Posted July 8, 2021 On 11/23/2019 at 8:48 PM, Ainz Ooal Gown said: Description: This is a respawn system that I currently use in my games. It is very staright farward but allows your players to set a respawn location you put on your map.  Video: https://www.ascensiongamedev.com/resources/filehost/48a67458f15947e6130fbdb70c3acbd3.mp4  Process: Players can walk up to a respawn point and interact with it to set a respawn location and if they die it will respawn them at that point.  Issue: Event doesnt trigger fast enough, so we create a blank black map and a black image to prevent a "Map Bounce" (what I mean by this is when a player dies he will respawn back to the class set start location before the respawn event kicks in, so the class starter map will show for a split second, before the player is warped to the map set by the respawn system. It will make sense as we go on)  Build:  First we need to make a variable: Type: INTEGER, Name: Player Respawn LOC  Second we need to make a common event  Reveal hidden contents Way Ive done it is so each new page is a respawn location, so you can make as many locations as you wish.  Make sure each page is TRIGGER= "On Respawn" and has a "Spawn/Execution Condition" of the player respawn location, Like so: PAGE 1 is: IF "Player Respawn LOC" = 1 RUN PAGE 2 is: IF "Player Respawn LOC" = 2 RUN  What is happening here is Show a picture, which is just a black image which is set to full screen. Show Text that player has died Warp player to the location of respawn point Hide image  Page 1 Page 2  Lastly we need to make the respawn points, which I call "Pathfinders", which is just an event on a map.  Reveal hidden contents So all that is happening here is when a player interactions with the set reswpan loaction is asks do they wish to set location here, if the player hits yes, it sets variable "Player Respawn LOC" to 1  Now you have set the core build of the respawn system, but you have to do one more thing which depends on how you have your game setup. Becuase of the issue I mentioned above, with a slight delay happening on the event trigger to warp player, I have had to set a "Blank" map which I called "Eternity".  I set all my classes in game to have this map "Eternity" as a spawn point  Reveal hidden contents  So this isnt good for when a new player starts the game, as they will just spawn on a blank map... so you add (which I have in all my games) is a common event "Set New Player Variables".  Reveal hidden contents This is useful if you have other variables you need to set for a new player joining the game.  Create a new variable and call it "New Player Start Done", variable is a "Boolean" Make sure event "Spawn/Execution condition" is "New Player Start Done = FALSE" Make the event trigger is "Login"  First thing in the common event commands is to warp the player to your actual starting location of your game. Last thing in the common event commands is to set a boolean variable to "TRUE" (this is so event only runs once for a new player)   Complete!  Now you should have a fully working respawn location system in your game.  Enjoy How to make option after killed (death) Can revival with money? Link to comment Share on other sites More sharing options...
Andical Posted July 8, 2021 Share Posted July 8, 2021 (edited) common event > trigger > on death -> add "SHOW options" with a few options, for example spawn in city = free, or spawn near. if they select near add a conditional branch, if player has 100 golds take 100 golds and warp him where you want or if he doesnt have money show a message instead, you need a contiditional or he will spawn even if he doesnt have gold. to change default spawn points is more complex, you have to create a player variable and call it for example "spawn1", "spawn2" etc anything you want, then an npc change this, for example you go to a city talk to an npc and he says "would you like to change spawning point here"? if you select the option yes, change the player variable you created, if it was bool set it true or false and in a common event you control where player spawn easily with a contidional branch. If player spawn point variable = "spawn1" warp him city 1, if variable is "spawn2" teleport to city 2 etc Edited July 8, 2021 by Andical EternalEssence 1 Link to comment Share on other sites More sharing options...
EternalEssence Posted August 30, 2022 Share Posted August 30, 2022 Just want to say thank you for this. I kept spawning into blocked areas. Ainz Ooal Gown 1 Link to comment Share on other sites More sharing options...
Ainz Ooal Gown Posted September 4, 2022 Author Share Posted September 4, 2022 On 8/30/2022 at 6:02 PM, EternalEssence said: Just want to say thank you for this. I kept spawning into blocked areas. Â Np glad it helped you out Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now