当前位置: 首页>>代码示例>>C++>>正文


C++ serializer::Reader类代码示例

本文整理汇总了C++中serializer::Reader的典型用法代码示例。如果您正苦于以下问题:C++ Reader类的具体用法?C++ Reader怎么用?C++ Reader使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了Reader类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: Load

void ShipFlavour::Load(Serializer::Reader &rd)
{
	id = rd.String();
	price = rd.Int32();
	regid = rd.String();
	LoadLmrMaterial(rd, &primaryColor);
	LoadLmrMaterial(rd, &secondaryColor);
}
开发者ID:GizmoR13,项目名称:pioneer,代码行数:8,代码来源:ShipFlavour.cpp

示例2: Load

void Player::Load(Serializer::Reader &rd, Space *space)
{
	Pi::player = this;
	Ship::Load(rd, space);
	MarketAgent::Load(rd);
	m_killCount = rd.Int32();
	m_knownKillCount = rd.Int32();
}
开发者ID:GizmoR13,项目名称:pioneer,代码行数:8,代码来源:Player.cpp

示例3: Load

void Missile::Load(Serializer::Reader &rd)
{
	Ship::Load(rd);
	m_ownerIndex = rd.Int32();
	m_targetIndex = rd.Int32();
	m_distToTarget = rd.Double();
	m_power = rd.Int32();
}
开发者ID:Sunsetjoy,项目名称:pioneer,代码行数:8,代码来源:Missile.cpp

示例4: Load

void Projectile::Load(Serializer::Reader &rd, Space *space)
{
	Body::Load(rd, space);
	m_baseVel = rd.Vector3d();
	m_dirVel = rd.Vector3d();
	m_age = rd.Float();
	m_type = rd.Int32();
	m_parentIndex = rd.Int32();
}
开发者ID:AmesianX,项目名称:pioneer,代码行数:9,代码来源:Projectile.cpp

示例5: Load

void Player::Load(Serializer::Reader &rd)
{
	Pi::player = this;
	Ship::Load(rd);
	m_flightControlState = static_cast<FlightControlState>(rd.Int32());
	m_setSpeed = rd.Double();
	m_killCount = rd.Int32();
	m_knownKillCount = rd.Int32();
}
开发者ID:Snaar,项目名称:pioneer,代码行数:9,代码来源:Player.cpp

示例6: Load

void ModelBody::Load(Serializer::Reader &rd, Space *space)
{
	Body::Load(rd, space);
	m_isStatic = rd.Bool();
	m_colliding = rd.Bool();
	SetModel(rd.String().c_str());
	m_model->Load(rd);
	m_shields->Load(rd);
}
开发者ID:lwho,项目名称:pioneer,代码行数:9,代码来源:ModelBody.cpp

示例7: Unserialize

void Unserialize(Serializer::Reader &rd)
{
	Init();
	PersistSystemData<Sint64>::Unserialize(rd, &s_criminalRecord);
	PersistSystemData<Sint64>::Unserialize(rd, &s_outstandingFine);
	for (int i=0; i<BLOC_MAX; i++) {
		s_playerPerBlocCrimeRecord[i].record = rd.Int64();
		s_playerPerBlocCrimeRecord[i].fine = rd.Int64();
	}
}
开发者ID:jbuck,项目名称:pioneer,代码行数:10,代码来源:Polit.cpp

示例8: ScannerMode

ScannerWidget::ScannerWidget(Graphics::Renderer *r, Serializer::Reader &rd) :
	m_renderer(r)
{
	m_mode = ScannerMode(rd.Int32());
	m_currentRange = rd.Float();
	m_manualRange = rd.Float();
	m_targetRange = rd.Float();

	InitObject();
}
开发者ID:lwho,项目名称:pioneer,代码行数:10,代码来源:ShipCpanelMultiFuncDisplays.cpp

示例9: Load

void Model::Load(Serializer::Reader &rd)
{
	LoadVisitor lv(&rd);
	m_root->Accept(lv);

	for (AnimationContainer::const_iterator i = m_animations.begin(); i != m_animations.end(); ++i)
		(*i)->SetProgress(rd.Double());
	UpdateAnimations();

	SetPattern(rd.Int32());
}
开发者ID:Brooking,项目名称:pioneer,代码行数:11,代码来源:Model.cpp

示例10: Load

void HyperspaceCloud::Load(Serializer::Reader &rd, Space *space)
{
	Body::Load(rd, space);
	m_vel = rd.Vector3d();
	m_birthdate = rd.Double();
	m_due = rd.Double();
	m_isArrival = rd.Bool();
	if (rd.Bool()) {
		m_ship = static_cast<Ship*>(Body::Unserialize(rd, space));
	}
}
开发者ID:AmesianX,项目名称:pioneer,代码行数:11,代码来源:HyperspaceCloud.cpp

示例11: Load

void NavLights::Load(Serializer::Reader &rd)
{
	m_time    = rd.Float();
	m_enabled = rd.Bool();

	RefCountedPtr<Graphics::Material> mat;
	for (LightIterator it = m_lights.begin(); it != m_lights.end(); ++it) {
		Uint8 c = rd.Byte();
		it->billboard->SetMaterial(get_material(c));
	}
}
开发者ID:Faiva78,项目名称:pioneer,代码行数:11,代码来源:NavLights.cpp

示例12: Load

void ModelSkin::Load(Serializer::Reader &rd)
{
    for (unsigned int i = 0; i < 3; i++) {
        m_colors[i].r = rd.Byte();
        m_colors[i].g = rd.Byte();
        m_colors[i].b = rd.Byte();
    }
    for (unsigned int i = 0; i < MAX_DECAL_MATERIALS; i++)
        m_decals[i] = rd.String();
    m_label = rd.String();
}
开发者ID:christiank,项目名称:pioneer,代码行数:11,代码来源:ModelSkin.cpp

示例13: Unserialize

void Unserialize(Serializer::Reader &rd)
{
	Init();
	PersistSystemData<Sint64>::Unserialize(rd, &s_criminalRecord);
	PersistSystemData<Sint64>::Unserialize(rd, &s_outstandingFine);
	const Uint32 numFactions = rd.Int32();
	assert(s_playerPerBlocCrimeRecord.size() == numFactions);
	for (Uint32 i=0; i < numFactions; i++) {
		s_playerPerBlocCrimeRecord[i].record = rd.Int64();
		s_playerPerBlocCrimeRecord[i].fine = rd.Int64();
	}
}
开发者ID:tnicoll,项目名称:pioneer,代码行数:12,代码来源:Polit.cpp

示例14: Unserialize

void Pi::Unserialize(Serializer::Reader &rd)
{
	Serializer::Reader section;
	
	SetTimeAccel(0);
	requestedTimeAccelIdx = 0;
	Space::Clear();
	if (Pi::player) {
		Pi::player->MarkDead();
		Space::bodies.remove(Pi::player);
		delete Pi::player;
		Pi::player = 0;
	}

	section = rd.RdSection("PiMisc");
	gameTime = section.Double();
	selectedSystem = StarSystem::Unserialize(section);
	currentSystem = StarSystem::Unserialize(section);

	section = rd.RdSection("Space");
	Space::Unserialize(section);
	
	section = rd.RdSection("Polit");
	Polit::Unserialize(section);

	section = rd.RdSection("SectorView");
	sectorView->Load(section);

	section = rd.RdSection("WorldView");
	worldView->Load(section);

	section = rd.RdSection("LuaModules");
	PiLuaModules::Unserialize(section);
}
开发者ID:Snaar,项目名称:pioneer,代码行数:34,代码来源:Pi.cpp

示例15: Load

void CollMesh::Load(Serializer::Reader &rd)
{
	m_aabb.max = rd.Vector3d();
	m_aabb.min = rd.Vector3d();
	m_aabb.radius = rd.Double();

	m_geomTree = new GeomTree(rd);

	const Uint32 numDynGeomTrees = rd.Int32();
	m_dynGeomTrees.reserve(numDynGeomTrees);
	for (Uint32 it = 0; it < numDynGeomTrees; ++it) {
		m_dynGeomTrees.push_back(new GeomTree(rd));
	}

	m_totalTris = rd.Int32();
}
开发者ID:emptyhead,项目名称:pioneer,代码行数:16,代码来源:CollMesh.cpp


注:本文中的serializer::Reader类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。