MCPcopy Create free account
hub / github.com/Panzerschrek/Chasm-Reverse / MonsterBase

Method MonsterBase

PanzerChasm/server/map_save_load.cpp:424–442  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

422}
423
424MonsterBase::MonsterBase(
425 const GameResourcesConstPtr &game_resources,
426 unsigned char monster_id, LoadStream& load_stream )
427 : game_resources_(game_resources)
428 , monster_id_(monster_id)
429{
430 PC_ASSERT( game_resources_ != nullptr );
431 PC_ASSERT( monster_id_ < game_resources_->monsters_description.size() );
432
433 load_stream.ReadBool( have_left_hand_ );
434 load_stream.ReadBool( have_right_hand_ );
435 load_stream.ReadBool( have_head_ );
436 load_stream.ReadBool( fragmented_ );
437 load_stream.ReadVec3( pos_ );
438 load_stream.ReadFloat( angle_ );
439 load_stream.ReadInt32( health_ );
440 load_stream.ReadUInt32( current_animation_ );
441 load_stream.ReadUInt32( current_animation_frame_ );
442}
443
444void Monster::Save( SaveStream& save_stream )
445{

Callers

nothing calls this directly

Calls 5

ReadBoolMethod · 0.80
ReadVec3Method · 0.80
ReadFloatMethod · 0.80
ReadInt32Method · 0.80
ReadUInt32Method · 0.80

Tested by

no test coverage detected