Simple MVM Revive Marker v3
A simple way to spawn revive markers outside of MVM
This is a short script to spawn functional revive markers from MVM at will, without needing MVM logic in your map.
Setup:
Setup:
- Add "IncludeScript("reviveMarker.nut")" to the script file you plan to call this script from
- Add an instance of the reviveMarker class to your script file (e.g. local cReviveMarker = reviveMarker())
- Call "spawnReviveMarker(player, respawnHealth)". "player" is the handle for the player you want to create a revive marker for, and "respawnHealth" is an optional parameter (you can leave it out or set it to -1 if you don't want to overwrite it) which lets you set the amount of health needed to revive a player.
- Thats it!
- This DOES NOT automatically spawn one of these on death, I leave that up to you (in case you want it to only spawn under specific circumstances)
- The revive marker model does not have skins for the blue team, which will make this very confusing if used in PVP gamemodes (hopefully in the future me or someone else will make a variant of the model with a blue version)
- Revive time increases with each revive per ROUND, this is vanilla behavior, but its important to know because most gamemodes have longer rounds than your average MVM wave. You can manually set the health needed to revive yourself, so it could be worthwhile to make your own variable for how many times a player has been revived and then reset it at your discretion.
- Add-on to the above, you can calculate the health needed to revive by taking the max health of the player, dividing it by 2, and then adding 10 * the number of revives to it. (e.g. local reviveHealth = (maxHealth / 2) + (10 * numRevives))
- In this version, the "cancel" button does nothing, I'm working on that though!
- License
- Free to use and modify. Credit is appreciated but not required.