comparison Render.h @ 194:650d96af8855

Vis overhaul; sprites can be picked by mouse
author Nomad
date Sat, 16 Feb 2013 18:32:37 +0200
parents d65528fc3bda
children 96bc024a5fed
comparison
equal deleted inserted replaced
192:1c8add70bcf9 194:650d96af8855
54 { 54 {
55 int _screenspace_x_scaler_packedfloat; 55 int _screenspace_x_scaler_packedfloat;
56 int _screenspace_y_scaler_packedfloat; 56 int _screenspace_y_scaler_packedfloat;
57 float fov_x; 57 float fov_x;
58 float fov_y; 58 float fov_y;
59 int sZValue; 59 union
60 {
61 int sZValue;
62 struct
63 {
64 unsigned __int16 object_pid;
65 signed __int16 actual_z;
66 };
67 };
60 int field_14_actor_id; 68 int field_14_actor_id;
61 unsigned __int16 uHwSpriteID; 69 unsigned __int16 uHwSpriteID;
62 __int16 uPalette; 70 __int16 uPalette;
63 __int16 uIndoorSectorID; 71 __int16 uIndoorSectorID;
64 __int16 field_1E; 72 __int16 field_1E;
71 unsigned int uTintColor; 79 unsigned int uTintColor;
72 SpriteFrame *pSpriteFrame; 80 SpriteFrame *pSpriteFrame;
73 81
74 inline float GetFloatZ() const 82 inline float GetFloatZ() const
75 { 83 {
76 return LOWORD(sZValue) / 65535.0f + (float)HIWORD(sZValue); 84 return (float)object_pid / 65535.0f + (float)actual_z;
77 } 85 }
78 }; 86 };
79 #pragma pack(pop) 87 #pragma pack(pop)
80 88
81 89