MCPcopy Create free account
hub / github.com/demoth/jake2 / read

Method read

game/src/main/java/jake2/game/gclient_t.java:213–325  ·  view source on GitHub ↗

Reads a game client from the file.

(QuakeFile f, edict_t[] edicts, GameExportsImpl gameExports)

Source from the content-addressed store, hash-verified

211
212 /** Reads a game client from the file. */
213 public void read(QuakeFile f, edict_t[] edicts, GameExportsImpl gameExports) throws IOException
214 {
215
216 getPlayerState().load(f);
217
218 setPing(f.readInt());
219
220 pers.read(f, gameExports);
221 resp.read(f, gameExports);
222
223 old_pmove.load(f);
224
225 showscores = f.readInt() != 0;
226 showinventory = f.readInt() != 0;
227 showhelp = f.readInt() != 0;
228 showhelpicon = f.readInt() != 0;
229 ammo_index = f.readInt();
230
231 buttons = f.readInt();
232 oldbuttons = f.readInt();
233 latched_buttons = f.readInt();
234
235 weapon_thunk=f.readInt()!=0;
236
237 newweapon= GameItems.readItem(f, gameExports);
238
239
240 damage_armor = f.readInt();
241 damage_parmor = f.readInt();
242 damage_blood = f.readInt();
243 damage_knockback = f.readInt();
244
245 damage_from[0] = f.readFloat();
246 damage_from[1] = f.readFloat();
247 damage_from[2] = f.readFloat();
248
249 killer_yaw = f.readFloat();
250
251 weaponstate = WeaponStates.fromInt(f.readInt());
252
253 kick_angles[0] = f.readFloat();
254 kick_angles[1] = f.readFloat();
255 kick_angles[2] = f.readFloat();
256
257 kick_origin[0] = f.readFloat();
258 kick_origin[1] = f.readFloat();
259 kick_origin[2] = f.readFloat();
260
261 v_dmg_roll = f.readFloat();
262 v_dmg_pitch = f.readFloat();
263 v_dmg_time = f.readFloat();
264 fall_time = f.readFloat();
265 fall_value = f.readFloat();
266 damage_alpha = f.readFloat();
267 bonus_alpha = f.readFloat();
268
269 damage_blend[0] = f.readFloat();
270 damage_blend[1] = f.readFloat();

Callers 4

readGameLocalsMethod · 0.45
ReadLevelMethod · 0.45
initMethod · 0.45
CopyFileMethod · 0.45

Calls 9

getPlayerStateMethod · 0.95
setPingMethod · 0.95
readItemMethod · 0.95
fromIntMethod · 0.95
getIndexMethod · 0.95
readIntMethod · 0.80
readFloatMethod · 0.80
readEdictRefMethod · 0.80
loadMethod · 0.45

Tested by

no test coverage detected