Revision | 936d69a1888f41341bfc89e5cce3b1f621809556 (tree) |
---|---|
Time | 2012-05-27 17:05:28 |
Author | Benjamin Berkels <torr.samaho@quan...> |
Commiter | Benjamin Berkels |
Fixed: Wound state changes weren't sent to clients. (part of Dusk's wound state / custom damagetype fix patch, but modified so that clients don't touch the wound state on their own)
@@ -228,6 +228,7 @@ | ||
228 | 228 | - - Fixed problems with the LAN broadcast under Linux. [Koromix] |
229 | 229 | - - Fixed: Console icon would stick on a player's head if the server missed the packet to remove the icon. [TIHan] |
230 | 230 | - - Fixed: Medals weren't announced on spied players. [Dusk] |
231 | +- - Fixed: Wound state changes weren't sent to clients. [Dusk, Torr Samaho] | |
231 | 232 | ! - Changed F12 to allow spectators full spying, with the exception of during LMS if it's disabled. [Eruanna] |
232 | 233 | ! - Changed F12 to allow full demo spying. [Eruanna] |
233 | 234 | ! - Players aren't forced to spectate after a "changemap" map change on a server with a join password anymore. [Torr Samaho] |
@@ -1598,12 +1598,17 @@ | ||
1598 | 1598 | } |
1599 | 1599 | |
1600 | 1600 | FState * woundstate = target->FindState(NAME_Wound, mod); |
1601 | - if (woundstate != NULL) | |
1601 | + // [BB] The server takes care of this. | |
1602 | + if ( (woundstate != NULL) && ( NETWORK_InClientMode( ) == false ) ) | |
1602 | 1603 | { |
1603 | 1604 | int woundhealth = RUNTIME_TYPE(target)->Meta.GetMetaInt (AMETA_WoundHealth, 6); |
1604 | 1605 | |
1605 | 1606 | if (target->health <= woundhealth) |
1606 | 1607 | { |
1608 | + // [Dusk] As the server, update the clients on the state | |
1609 | + if ( NETWORK_GetState( ) == NETSTATE_SERVER ) | |
1610 | + SERVERCOMMANDS_SetThingFrame( target, woundstate ); | |
1611 | + | |
1607 | 1612 | target->SetState (woundstate); |
1608 | 1613 | return; |
1609 | 1614 | } |