本文整理汇总了C#中GameBitBuffer.WriteBool方法的典型用法代码示例。如果您正苦于以下问题:C# GameBitBuffer.WriteBool方法的具体用法?C# GameBitBuffer.WriteBool怎么用?C# GameBitBuffer.WriteBool使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GameBitBuffer
的用法示例。
在下文中一共展示了GameBitBuffer.WriteBool方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: EncodeValue
public void EncodeValue(GameBitBuffer buffer)
{
switch (Attribute.EncodingType)
{
case GameAttributeEncoding.Int:
buffer.WriteInt(Attribute.BitCount, Int);
break;
case GameAttributeEncoding.IntMinMax:
buffer.WriteInt(Attribute.BitCount, Int - Attribute.Min);
break;
case GameAttributeEncoding.Float16:
buffer.WriteFloat16(Float);
break;
case GameAttributeEncoding.Float16Or32:
if (Float >= 65536.0f || -65536.0f >= Float)
{
buffer.WriteBool(false);
buffer.WriteFloat32(Float);
}
else
{
buffer.WriteBool(true);
buffer.WriteFloat16(Float);
}
break;
default:
throw new Exception("bad voodoo");
}
}
示例2: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, snoQuest);
buffer.WriteInt(32, snoLevelArea);
buffer.WriteInt(32, Field2);
buffer.WriteBool(Field3);
buffer.WriteBool(Field4);
}
示例3: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, Field0);
Field1.Encode(buffer);
buffer.WriteBool(Field2.HasValue);
if (Field2.HasValue)
{
buffer.WriteBool(Field2.Value);
}
}
示例4: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, ActorId);
Position.Encode(buffer);
buffer.WriteFloat32(Angle);
buffer.WriteBool(Field3);
buffer.WriteInt(25, Field4);
buffer.WriteBool(Field5.HasValue);
if (Field5.HasValue)
{
buffer.WriteInt(16, Field5.Value);
}
}
示例5: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, Field0);
Field1.Encode(buffer);
buffer.WriteFloat32(Field2);
buffer.WriteBool(Field3);
buffer.WriteInt(25, Field4);
buffer.WriteBool(Field5.HasValue);
if (Field5.HasValue)
{
buffer.WriteInt(16, Field5.Value);
}
}
示例6: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteCharArray(512, Field0);
buffer.WriteBool(Field1.HasValue);
if (Field1.HasValue)
{
buffer.WriteInt(32, Field1.Value);
}
buffer.WriteBool(Field2.HasValue);
if (Field2.HasValue)
{
buffer.WriteInt(32, Field2.Value);
}
}
示例7: Encode
public void Encode(GameBitBuffer buffer)
{
buffer.WriteBool(Field0);
buffer.WriteInt(32, snoAffixStringList);
buffer.WriteInt(32, Field2);
buffer.WriteInt(32, Field3);
}
示例8: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(2, HirelingIndex);
buffer.WriteBool(Field1);
buffer.WriteInt(32, Field2);
buffer.WriteInt(7, Level);
}
示例9: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, Field0);
Field1.Encode(buffer);
buffer.WriteInt(32, Field2);
buffer.WriteInt(32, m_snoStringList);
buffer.WriteInt(32, Field4);
buffer.WriteFloat32(Field5);
buffer.WriteFloat32(Field6);
buffer.WriteFloat32(Field7);
buffer.WriteInt(32, Field8);
buffer.WriteBool(Field9);
buffer.WriteBool(Field10);
buffer.WriteBool(Field11);
buffer.WriteInt(32, Field12);
}
示例10: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(2, Field0);
buffer.WriteInt(32, Field1);
buffer.WriteInt(32, Field2);
buffer.WriteBool(Field3);
}
示例11: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteUInt(32, ActorID);
buffer.WriteUInt(32, HitDealer);
buffer.WriteInt(3, Field2 - (-1));
buffer.WriteBool(Field3);
}
示例12: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, Field0);
Field1.Encode(buffer);
buffer.WriteFloat32(Field2);
buffer.WriteBool(Field3);
buffer.WriteInt(24, Field4);
}
示例13: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteUInt(32, ChunkID);
buffer.WriteInt(32, SceneSNO);
Transform.Encode(buffer);
buffer.WriteUInt(32, WorldID);
buffer.WriteBool(MiniMapVisibility);
}
示例14: Encode
public void Encode(GameBitBuffer buffer)
{
buffer.WriteBool(Field0.HasValue);
if (Field0.HasValue)
{
buffer.WriteInt(20, Field0.Value);
}
buffer.WriteInt(10, Attribute.Id);
}
示例15: Encode
public override void Encode(GameBitBuffer buffer)
{
buffer.WriteInt(32, snoPower);
buffer.WriteBool(Field1 != null);
if (Field1 != null)
{
Field1.Encode(buffer);
}
}