For everything I "changed", i commented out the original code and put my own incase you want to switch back
Changes:
1) Roof Spikes code was put into a for loop
2) Replaced almost all the overlap functions (killKnife, killShield etc) with a generic function
deathOne(victim, killer), and deathTwo(killer, victim)
the callback function for the overlap method basically passes two parameters (entity/item in question) and you basically call a function to kill one of them. This saves room since you can run either function over and over instead of creating a new function that does the same thing
3) put all the var declarations (var player; var playerTwo;) all in one line
For everything I "changed", i commented out the original code and put my own incase you want to switch back
Changes: 1) Roof Spikes code was put into a for loop
2) Replaced almost all the overlap functions (killKnife, killShield etc) with a generic function deathOne(victim, killer), and deathTwo(killer, victim) the callback function for the overlap method basically passes two parameters (entity/item in question) and you basically call a function to kill one of them. This saves room since you can run either function over and over instead of creating a new function that does the same thing
3) put all the var declarations (var player; var playerTwo;) all in one line