Posts: 3,138
Threads: 71
Joined: May 2008
Reputation:
0
We try: SetPlayerHealth(playerid, 50.15);
but in GetPlayerHealth we got 50.0
What func rounded float value without my command?
Posts: 4,885
Threads: 57
Joined: Jun 2012
Reputation:
0
That is normal because of the way that data type is changed for net play but all you really need to do is make your own damage system variable.
Posts: 913
Threads: 70
Joined: Apr 2009
Reputation:
0
class CSyncData
{
public:
WORD wUDAnalog; // 0x0076 - 0x0078
WORD wLRAnalog; // 0x0078 - 0x007A
WORD wKeys; // 0x007A - 0x007C
CVector vecPosition; // 0x007C - 0x0088
float fQuaternionAngle; // 0x0088 - 0x008C
CVector vecQuaternion; // 0x008C - 0x0098
BYTE byteHealth; // 0x0098 - 0x0099
BYTE byteArmour; // 0x0099 - 0x009A
BYTE byteWeapon; // 0x009A - 0x009B
BYTE byteSpecialAction; // 0x009B - 0x009C
CVector vecVelocity; // 0x009C - 0x00A8
CVector vecSurfing; // 0x00A8 - 0x00B4
WORD wSurfingInfo; // 0x00B4 - 0x00B6
int iAnimationId; // 0x00B6 - 0x00BA
// Size = 68
};
This is the problem..