Implemented the new class system. Class menu missing, only default classes working.

This commit is contained in:
richard
2009-04-11 01:56:22 +02:00
parent 1e99bd64f3
commit a8704cf90c
15 changed files with 557 additions and 269 deletions

View File

@@ -0,0 +1,28 @@
/*
* ============================================================================
*
* Zombie:Reloaded
*
* File: clientalpha.inc
* Description: Handles transparency on clients.
* Author: Richard Helgeby
*
* ============================================================================
*/
/**
* Updates the alpha value on a player.
*/
ClassAlphaUpdate(client)
{
new current_health = GetClientHealth(client);
new max_health = ClassGetHealth(client);
new max_damage = ClassGetAlphaDamage(client);
// Calculate if enough damage is done to change alpha.
if ((max_health - current_health) > max_damage)
{
new alpha_damaged = ClassGetAlphaDamaged(client);
SetPlayerAlpha(client, alpha_damaged);
}
}