VampireArena
Started by themuffinator
avatar
themuffinator Rep. 1044
#1   17 Apr 2012
For anyone who's interested in vampire mode, here's my own little mod that you might enjoy:

www.mediafire.com/

And for those who don't know what vampire mode is: your health drains over time and you can replenish it by damaging or killing your opponents. All health items are removed from the arena, regeneration regenerates armor instead. You won't survive if you camp. Maximum health and armor is by default 300 and 250 respectively.

There's a few cvars added for customising it, but the standard settings offer a pretty balanced and challenging game.

avatar
CZghost Rep. 1681
#2   18 Apr 2012
Played vampire mode on single player challenges, funny...
avatar
Tig Rep. 1662
#3   18 Apr 2012
This mod is very cool! It plays heaps better than I thought it would as well. The max health and armor levels work very well and (seem) to prevent domination.

The readme mentions a minor issue with floats and low values. Could this be from a multiplication of an int and a float? If so, check the int is converted to a float first, then convert the answer back to an int (if that is what you are after).

avatar
themuffinator Rep. 1044
#4   19 Apr 2012
@Tig: Yep it took a bit of meddling with to get it like that. It should be quite a challenge to get near to 300 health which is how it should be.

You're right about it being about multiplying ints and floats, although I'm not quite sure whether I understand your advice though. The issue is the game rounding down the values and losing decimals that can make quite a difference, but I decided to rather round up the values now and it seems alright. It was especially an issue when your target has armor - one MG bullet would only give you a 1 health bonus. Now it gives 2, which is acceptable since the exact amount should be 1.7325 if you didn't frag your opponent.

I've also capped the health bonuses to your target's health now, so if your target has 10 health and no armor, then a railgun shot will base your bonus on 10 damage given, not 100.

Now I just need to figure out the high-health glowing effect. Still not 100% sure how to get it to work - I'm basically trying to do it using a new powerup entry to the powerup_t struct, applying it to clients when they're within 10% from the max health, and drawing it client-side in the same way as with actual power-ups in cg_players.c.

avatar
Tig Rep. 1662
#5   19 Apr 2012
I really like the idea of only taking the health the victim has, that sounds like it is the right way to go.

As to the (int float) issue, if you convert the int to a float, then do the math (so you have float float), you should get a 'closer to correct' answer. In javascript or java this is a common issue which can be solved with (parseFloat(int) * float). However the rounding up is a good solution too.

avatar
KommissarReb (SW12) Rep. 2362
#6   19 May 2012
You ought to make the mod more customizable. Give the player the option of advanced settings.

Like whether or not your health is slowly reduced automatically, how much health you have, what weapons you have/start with etc.

Do this and you have got one hot mod.

avatar
themuffinator Rep. 1044
#7   24 May 2012
"Like whether or not your health is slowly reduced automatically"
"how much health you have"

There are cvars that control those. Here's from the readme:


In addition to the vampire toggle option added to the start server screen, The following cvars have been added:

gm_vampire 0/1 (default: 1)
Enables vampire mode.

gm_vampire_expireRate <rate> (default: 1)
Integral increment by which players' health are decreased per second

gm_vampire_killFactor <factor> (default: 1.0)
Floating factor of damage dealt resulting in a frag which is added to own health

gm_vampire_stealFactor <factor> (default: 0.75)
Floating factor of damage dealt not resulting in a frag which is added to own health

gm_vampire_startArmor <amount> (default: 100)
Amount of armor given to players upon spawning

gm_vampire_startHealth <amount> (default: 60)
Amount of health given to players upon spawning

gm_vampire_maxArmor <amount> (default: 250)
Maximum amount of armor a player can hold

gm_vampire_maxHealth <amount> (default: 300)
Maximum amount of health a player can have

"what weapons you have/start with"

I could add a pretty comprehensive set of options for starting weapons straight from my main mod, but I'm looking to keep this as simple/minimalistic as possible. I might add just a basic option for the next version though, which will be released when I figure out how to implement a high-health player glow... right now everyone glows lol.

Only registered members can post a reply.
Already registered? Sign in.

uberkill
Clear