本文整理汇总了C#中System.IO.BinaryReader.ReadStringID方法的典型用法代码示例。如果您正苦于以下问题:C# BinaryReader.ReadStringID方法的具体用法?C# BinaryReader.ReadStringID怎么用?C# BinaryReader.ReadStringID使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.IO.BinaryReader
的用法示例。
在下文中一共展示了BinaryReader.ReadStringID方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RenderModel
public RenderModel(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.flags = (Flags)binaryReader.ReadInt16();
this.padding = binaryReader.ReadBytes(2);
this.padding0 = binaryReader.ReadBytes(4);
this.importInfo = ReadImportinfo(binaryReader);
this.compressionInfo = ReadCompressioninfo(binaryReader);
this.regions = ReadRegions(binaryReader);
this.sections = ReadSections(binaryReader);
this.invalidSectionPairBits = ReadInvalidsectionpairbits(binaryReader);
this.sectionGroups = ReadSectiongroups(binaryReader);
this.l1SectionGroupIndexSuperLow = binaryReader.ReadByte();
this.l2SectionGroupIndexLow = binaryReader.ReadByte();
this.l3SectionGroupIndexMedium = binaryReader.ReadByte();
this.l4SectionGroupIndexHigh = binaryReader.ReadByte();
this.l5SectionGroupIndexSuperHigh = binaryReader.ReadByte();
this.l6SectionGroupIndexHollywood = binaryReader.ReadByte();
this.padding1 = binaryReader.ReadBytes(2);
this.nodeListChecksum = binaryReader.ReadInt32();
this.nodes = ReadNodes(binaryReader);
this.nodeMapOLD = ReadNodemapold(binaryReader);
this.markerGroups = ReadMarkergroups(binaryReader);
this.materials = ReadMaterials(binaryReader);
this.errors = ReadErrors(binaryReader);
this.dontDrawOverCameraCosineAngleDontDrawFpModelWhenCameraThisAngleCosine11Sugg020Disables = binaryReader.ReadSingle();
this.pRTInfo = ReadPrtinfo(binaryReader);
this.sectionRenderLeaves = ReadSectionrenderleaves(binaryReader);
}
示例2: GlobalDamageSectionBlock
public GlobalDamageSectionBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.flags = (Flags)binaryReader.ReadInt32();
this.vitalityPercentage01PercentageOfTotalObjectVitality = binaryReader.ReadSingle();
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(InstantaneousDamageRepsonseBlock));
this.instantResponses = new InstantaneousDamageRepsonseBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.instantResponses[i] = new InstantaneousDamageRepsonseBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(GNullBlock));
this.gNullBlock = new GNullBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.gNullBlock[i] = new GNullBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(GNullBlock));
this.gNullBlock0 = new GNullBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.gNullBlock0[i] = new GNullBlock(binaryReader);
}
}
}
this.stunTimeSeconds = binaryReader.ReadSingle();
this.rechargeTimeSeconds = binaryReader.ReadSingle();
this.padding = binaryReader.ReadBytes(4);
this.resurrectionRestoredRegionName = binaryReader.ReadStringID();
this.padding0 = binaryReader.ReadBytes(4);
}
示例3: BinaryReader
void IDefinition.FromArray(byte[] buffer)
{
BinaryReader bin = new BinaryReader(new MemoryStream(buffer));
Name = bin.ReadStringID();
Parent_NodeIndex = bin.ReadInt16();
FirstChild_NodeIndex = bin.ReadInt16();
NextSibling_NodeIndex = bin.ReadInt16();
bin.BaseStream.Seek(sizeof(short), SeekOrigin.Current);
Position = bin.ReadVector3();
Rotation = bin.ReadQuaternion();
Scale = bin.ReadSingle();
Right = bin.ReadVector3();
Forward = bin.ReadVector3();
Up = bin.ReadVector3();
AbsolutePosition = bin.ReadVector3();
}
示例4: ScenarioInterpolatorBlock
public ScenarioInterpolatorBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.acceleratorNameInterpolator = binaryReader.ReadStringID();
this.multiplierNameInterpolator = binaryReader.ReadStringID();
this.function = new ScalarFunctionStruct(binaryReader);
this.skip = binaryReader.ReadBytes(2);
this.skip0 = binaryReader.ReadBytes(2);
}
示例5: ScenarioPlanarFogPalette
public ScenarioPlanarFogPalette(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.planarFog = binaryReader.ReadTagReference();
this.padding = binaryReader.ReadBytes(2);
this.padding0 = binaryReader.ReadBytes(2);
}
示例6: ScenarioAtmosphericFogMixerBlock
public ScenarioAtmosphericFogMixerBlock(BinaryReader binaryReader)
{
this.padding = binaryReader.ReadBytes(4);
this.atmosphericFogSourceFromScenarioAtmosphericFogPalette = binaryReader.ReadStringID();
this.interpolatorFromScenarioInterpolators = binaryReader.ReadStringID();
this.skip0 = binaryReader.ReadBytes(2);
this.skip1 = binaryReader.ReadBytes(2);
}
示例7: ScenarioCutsceneTitleBlock
public ScenarioCutsceneTitleBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.textBoundsOnScreen = binaryReader.ReadVector2();
this.justification = (Justification)binaryReader.ReadInt16();
this.font = (Font)binaryReader.ReadInt16();
this.textColor = binaryReader.ReadRGBColor();
this.shadowColor = binaryReader.ReadRGBColor();
this.fadeInTimeSeconds = binaryReader.ReadSingle();
this.upTimeSeconds = binaryReader.ReadSingle();
this.fadeOutTimeSeconds = binaryReader.ReadSingle();
this.paddingpadding = binaryReader.ReadBytes(2);
}
示例8: AiSceneRoleBlock
public AiSceneRoleBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.group = (Group)binaryReader.ReadInt16();
this.padding = binaryReader.ReadBytes(2);
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(AiSceneRoleVariantsBlock));
this.roleVariants = new AiSceneRoleVariantsBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.roleVariants[i] = new AiSceneRoleVariantsBlock(binaryReader);
}
}
}
}
示例9: RenderModelMarkerGroupBlock
public RenderModelMarkerGroupBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.markers = ReadMarkers(binaryReader);
}
示例10: HierarchyModel
//.........这里部分代码省略.........
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.newDamageInfo[i] = new GlobalDamageInfoBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(ModelTargetBlock));
this.targets = new ModelTargetBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.targets[i] = new ModelTargetBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(ModelRegionBlock));
this.modelRegionBlock = new ModelRegionBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.modelRegionBlock[i] = new ModelRegionBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(ModelNodeBlock));
this.modelNodeBlock = new ModelNodeBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.modelNodeBlock[i] = new ModelNodeBlock(binaryReader);
}
}
}
this.padding2 = binaryReader.ReadBytes(4);
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(ModelObjectDataBlock));
this.modelObjectData = new ModelObjectDataBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.modelObjectData[i] = new ModelObjectDataBlock(binaryReader);
}
}
}
this.defaultDialogueTheDefaultDialogueTagForThisModelOverridenByVariants = binaryReader.ReadTagReference();
this.uNUSED = binaryReader.ReadTagReference();
this.flags = (Flags)binaryReader.ReadInt32();
this.defaultDialogueEffectTheDefaultDialogueTagForThisModelOverridenByVariants = binaryReader.ReadStringID();
this.renderOnlyNodeFlags = new RenderOnlyNodeFlags[32];
for (int i = 0; i < 32; ++i)
{
this.renderOnlyNodeFlags[i] = new RenderOnlyNodeFlags(binaryReader);
}
this.renderOnlySectionFlags = new RenderOnlySectionFlags[32];
for (int i = 0; i < 32; ++i)
{
this.renderOnlySectionFlags[i] = new RenderOnlySectionFlags(binaryReader);
}
this.runtimeFlags = (RuntimeFlags)binaryReader.ReadInt32();
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(GlobalScenarioLoadParametersBlock));
this.scenarioLoadParameters = new GlobalScenarioLoadParametersBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.scenarioLoadParameters[i] = new GlobalScenarioLoadParametersBlock(binaryReader);
}
}
}
this.hologramShader = binaryReader.ReadTagReference();
this.hologramControlFunction = binaryReader.ReadStringID();
Initialize();
}
示例11: RenderModelNodeBlock
public RenderModelNodeBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadStringID();
this.parentNode = binaryReader.ReadShortBlockIndex1();
this.firstChildNode = binaryReader.ReadShortBlockIndex1();
this.nextSiblingNode = binaryReader.ReadShortBlockIndex1();
this.importNodeIndex = binaryReader.ReadInt16();
this.defaultTranslation = binaryReader.ReadVector3();
this.defaultRotation = binaryReader.ReadQuaternion();
this.inverseForward = binaryReader.ReadVector3();
this.inverseLeft = binaryReader.ReadVector3();
this.inverseUp = binaryReader.ReadVector3();
this.inversePosition = binaryReader.ReadVector3();
this.inverseScale = binaryReader.ReadSingle();
this.distanceFromParent = binaryReader.ReadSingle();
}
示例12: GlobalDamageInfoBlock
public GlobalDamageInfoBlock(BinaryReader binaryReader)
{
this.flags = (Flags)binaryReader.ReadInt32();
this.globalIndirectMaterialNameAbsorbesAOEOrChildDamage = binaryReader.ReadStringID();
this.indirectDamageSectionAbsorbesAOEOrChildDamage = binaryReader.ReadShortBlockIndex2();
this.padding = binaryReader.ReadBytes(2);
this.padding0 = binaryReader.ReadBytes(4);
this.collisionDamageReportingType = (CollisionDamageReportingType)binaryReader.ReadByte();
this.responseDamageReportingType = (ResponseDamageReportingType)binaryReader.ReadByte();
this.padding1 = binaryReader.ReadBytes(2);
this.padding2 = binaryReader.ReadBytes(20);
this.maximumVitality = binaryReader.ReadSingle();
this.minimumStunDamageTheMinimumDamageRequiredToStunThisObjectsHealth = binaryReader.ReadSingle();
this.stunTimeSecondsTheLengthOfTimeTheHealthStayStunnedDoNotRechargeAfterTakingDamage = binaryReader.ReadSingle();
this.rechargeTimeSecondsTheLengthOfTimeItWouldTakeForTheShieldsToFullyRechargeAfterBeingCompletelyDepleted = binaryReader.ReadSingle();
this.rechargeFraction0DefaultsTo1ToWhatMaximumLevelTheBodyHealthWillBeAllowedToRecharge = binaryReader.ReadSingle();
this.padding3 = binaryReader.ReadBytes(64);
this.shieldDamagedFirstPersonShader = binaryReader.ReadTagReference();
this.shieldDamagedShader = binaryReader.ReadTagReference();
this.maximumShieldVitalityTheDefaultInitialAndMaximumShieldVitalityOfThisObject = binaryReader.ReadSingle();
this.globalShieldMaterialName = binaryReader.ReadStringID();
this.minimumStunDamageTheMinimumDamageRequiredToStunThisObjectsShields = binaryReader.ReadSingle();
this.stunTimeSecondsTheLengthOfTimeTheShieldsStayStunnedDoNotRechargeAfterTakingDamage = binaryReader.ReadSingle();
this.rechargeTimeSecondsTheLengthOfTimeItWouldTakeForTheShieldsToFullyRechargeAfterBeingCompletelyDepleted0 = binaryReader.ReadSingle();
this.shieldDamagedThreshold = binaryReader.ReadSingle();
this.shieldDamagedEffect = binaryReader.ReadTagReference();
this.shieldDepletedEffect = binaryReader.ReadTagReference();
this.shieldRechargingEffect = binaryReader.ReadTagReference();
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(GlobalDamageSectionBlock));
this.damageSections = new GlobalDamageSectionBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.damageSections[i] = new GlobalDamageSectionBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(GlobalDamageNodesBlock));
this.nodes = new GlobalDamageNodesBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.nodes[i] = new GlobalDamageNodesBlock(binaryReader);
}
}
}
this.padding4 = binaryReader.ReadBytes(2);
this.padding5 = binaryReader.ReadBytes(2);
this.padding6 = binaryReader.ReadBytes(4);
this.padding7 = binaryReader.ReadBytes(4);
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(DamageSeatInfoBlock));
this.damageSeats = new DamageSeatInfoBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.damageSeats[i] = new DamageSeatInfoBlock(binaryReader);
}
}
}
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(DamageConstraintInfoBlock));
this.damageConstraints = new DamageConstraintInfoBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.damageConstraints[i] = new DamageConstraintInfoBlock(binaryReader);
}
}
}
this.overshieldFirstPersonShader = binaryReader.ReadTagReference();
this.overshieldShader = binaryReader.ReadTagReference();
}
示例13: DamageConstraintInfoBlock
public DamageConstraintInfoBlock(BinaryReader binaryReader)
{
this.physicsModelConstraintName = binaryReader.ReadStringID();
this.damageConstraintName = binaryReader.ReadStringID();
this.damageConstraintGroupName = binaryReader.ReadStringID();
this.groupProbabilityScale = binaryReader.ReadSingle();
this.padding = binaryReader.ReadBytes(4);
}
示例14: DamageSeatInfoBlock
public DamageSeatInfoBlock(BinaryReader binaryReader)
{
this.seatLabel = binaryReader.ReadStringID();
this.directDamageScale0NoDamage1FullDamage = binaryReader.ReadSingle();
this.damageTransferFallOffRadius = binaryReader.ReadSingle();
this.maximumTransferDamageScale = binaryReader.ReadSingle();
this.minimumTransferDamageScale = binaryReader.ReadSingle();
}
示例15: SquadsBlock
public SquadsBlock(BinaryReader binaryReader)
{
this.name = binaryReader.ReadString32();
this.flags = (Flags)binaryReader.ReadInt32();
this.team = (Team)binaryReader.ReadInt16();
this.parent = binaryReader.ReadShortBlockIndex1();
this.squadDelayTimeSeconds = binaryReader.ReadSingle();
this.normalDiffCountInitialNumberOfActorsOnNormalDifficulty = binaryReader.ReadInt16();
this.insaneDiffCountInitialNumberOfActorsOnInsaneDifficultyHardDifficultyIsMidwayBetweenNormalAndInsane = binaryReader.ReadInt16();
this.majorUpgrade = (MajorUpgrade)binaryReader.ReadInt16();
this.padding = binaryReader.ReadBytes(2);
this.vehicleType = binaryReader.ReadShortBlockIndex1();
this.characterType = binaryReader.ReadShortBlockIndex1();
this.initialZone = binaryReader.ReadShortBlockIndex1();
this.padding0 = binaryReader.ReadBytes(2);
this.initialWeapon = binaryReader.ReadShortBlockIndex1();
this.initialSecondaryWeapon = binaryReader.ReadShortBlockIndex1();
this.grenadeType = (GrenadeType)binaryReader.ReadInt16();
this.initialOrder = binaryReader.ReadShortBlockIndex1();
this.vehicleVariant = binaryReader.ReadStringID();
{
var count = binaryReader.ReadInt32();
var address = binaryReader.ReadInt32();
var elementSize = Marshal.SizeOf(typeof(ActorStartingLocationsBlock));
this.startingLocations = new ActorStartingLocationsBlock[count];
using (binaryReader.BaseStream.Pin())
{
for (int i = 0; i < count; ++i)
{
binaryReader.BaseStream.Position = address + i * elementSize;
this.startingLocations[i] = new ActorStartingLocationsBlock(binaryReader);
}
}
}
this.placementScript = binaryReader.ReadString32();
this.skip1 = binaryReader.ReadBytes(2);
this.padding2 = binaryReader.ReadBytes(2);
}