Blaze The Cat
Member
The old ringhealth.lua has been included for legacy purposes.
How it works
This concept is very simple; your rings instead become your health. When shot, you lose rings. To compensate, all shields will instead give you 25 rings. In addition, you begin with 25 rings (or, 26 health)
The damage table is as follows:
When you do damage, you get points equivalent to the damage you've dealt. Killing a player awards a 100-point bonus.
If you are in your super form, you can hurt players when you touch them, and take half the damage you normally would. Rails still take out a quarter of your health, so be careful.
While you can have as many as 9999 rings, ring-hoarding is both a safety and a liability, as having a lot of rings can result in an opponent scoring a large number of points off of you with a rail.
Modifications
As of 1.1, you may also include your own damage values.
To input an entry to the table, you call the globalized function G_AddToDamageTable.
ringhealth.G_AddToDamageTable(fixed_t knockback, string killmsg, function logic, [boolean swapnames])
knockback: This tells the script how much to kick the player if they get shot by this weapon.
killmsg: Should include two %s variables. The first one is replaced by the attacker, the second one is replaced by the victim. If swapnames is true, this will switch these two variables around.
logic: This is a function you supply to the script to check for the projectile or damage you want to add to the table. It will need to accept a mobj_t and an integer, for the hazardous mobj and the damaged player's health, respectively. Your function then returns the damage value output. If the logic comes out false, return 0.
swapnames: This swaps the player's names in the death message, in case you want the victim's name first. This parameter is optional.
Example:
Commands/Variables
rh_knockback <on/off> will determine if players take knockback from being shot. By default, this is on.
rh_friendlypushing <on/off> will determine if players on the same team can kick each other around. By default, this is on.
rh_debug <on/off> will allow you to see what entries in the damage table are activating, and how much damage they do. This will also disable any damage taken from shots to allow you to use players as test dummies. By default, this is off.
painsound <number/sfx_name> allows you to set the sound your character plays when getting hurt. By default, this is set to 5, the first pain sound. It can be one of the following:
How it works
This concept is very simple; your rings instead become your health. When shot, you lose rings. To compensate, all shields will instead give you 25 rings. In addition, you begin with 25 rings (or, 26 health)
The damage table is as follows:
- Red Ring - Your basic weapon. Does 4 damage.
- Automatic Ring - Rapid fire. Does 3 damage.
- Bounce Ring - Can bounce off multiple enemies. 5 damage.
- Scatter Ring - Each piece does 4 damage. Land all five for a whopping 20 damage, which is the highest damage for a weapon.
- Explosion Ring - Does 12 damage, and hits everyone in the explosion vicinity.
- Grenade Ring - Does 15 damage, and acts as a proximity mine. Hits only once per ring, and does the highest damage of any single weapon.
- Rail Ring - The tactical weapon. Cuts down health by 1/2, rounded up.
- Infinity Ring - Shooting doesn't consume rings. 4 damage.
When you do damage, you get points equivalent to the damage you've dealt. Killing a player awards a 100-point bonus.
If you are in your super form, you can hurt players when you touch them, and take half the damage you normally would. Rails still take out a quarter of your health, so be careful.
While you can have as many as 9999 rings, ring-hoarding is both a safety and a liability, as having a lot of rings can result in an opponent scoring a large number of points off of you with a rail.
Modifications
As of 1.1, you may also include your own damage values.
To input an entry to the table, you call the globalized function G_AddToDamageTable.
ringhealth.G_AddToDamageTable(fixed_t knockback, string killmsg, function logic, [boolean swapnames])
knockback: This tells the script how much to kick the player if they get shot by this weapon.
killmsg: Should include two %s variables. The first one is replaced by the attacker, the second one is replaced by the victim. If swapnames is true, this will switch these two variables around.
logic: This is a function you supply to the script to check for the projectile or damage you want to add to the table. It will need to accept a mobj_t and an integer, for the hazardous mobj and the damaged player's health, respectively. Your function then returns the damage value output. If the logic comes out false, return 0.
swapnames: This swaps the player's names in the death message, in case you want the victim's name first. This parameter is optional.
Example:
Code:
function G_BigBomb (mobj, victimhealth)
if mobj.type == MT_BIGFATREALLYREALLYBIGBOMB
return 100
else
return 0
end
end
ringhealth.G_AddToDamageTable(64*FRACUNIT, "Wow, %s really DID have a Honkey-Donkey Super-Sonic Big Fat Really Really Big bomb, %s!", G_BigBomb)
Commands/Variables
rh_knockback <on/off> will determine if players take knockback from being shot. By default, this is on.
rh_friendlypushing <on/off> will determine if players on the same team can kick each other around. By default, this is on.
rh_debug <on/off> will allow you to see what entries in the damage table are activating, and how much damage they do. This will also disable any damage taken from shots to allow you to use players as test dummies. By default, this is off.
painsound <number/sfx_name> allows you to set the sound your character plays when getting hurt. By default, this is set to 5, the first pain sound. It can be one of the following:
- A soundtest number
- A sfx_name
- A DSLUMP name.
Attachments
Last edited: