Implement sh_announcescideath
This commit is contained in:
parent
f76b3f17b1
commit
bdafdf9db0
2 changed files with 16 additions and 10 deletions
|
@ -137,5 +137,11 @@ var int autocvar_sh_scialert = FALSE;
|
|||
/* default speed for scientists */
|
||||
var int autocvar_sh_scispeed = 40;
|
||||
|
||||
/* enable scientist obituaries */
|
||||
var int autocvar_sh_announcescideath = 1;
|
||||
|
||||
/* default kills required for insanity */
|
||||
var int autocvar_sh_insanity = 5;
|
||||
|
||||
/* an override for sh_scimax */
|
||||
var int autocvarsh_scimax_override = 0;
|
|
@ -15,8 +15,6 @@
|
|||
* OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
var int autocvar_sh_insanity = 10;
|
||||
|
||||
void
|
||||
HLGameRules::RestartRound(void)
|
||||
{
|
||||
|
@ -281,6 +279,7 @@ HLGameRules::ScientistKill(NSClientPlayer pp, entity sci)
|
|||
{
|
||||
player pl = (player)pp;
|
||||
/* obituary networking */
|
||||
if (cvar("sh_announcescideath") == 1) {
|
||||
WriteByte(MSG_MULTICAST, SVC_CGAMEPACKET);
|
||||
WriteByte(MSG_MULTICAST, EV_OBITUARY);
|
||||
WriteString(MSG_MULTICAST, pl.netname);
|
||||
|
@ -289,6 +288,7 @@ HLGameRules::ScientistKill(NSClientPlayer pp, entity sci)
|
|||
WriteByte(MSG_MULTICAST, 0);
|
||||
msg_entity = world;
|
||||
multicast([0,0,0], MULTICAST_ALL);
|
||||
}
|
||||
|
||||
/* give players a frag per scientist they kill */
|
||||
pl.frags++;
|
||||
|
|
Loading…
Reference in a new issue