Skip to content

Commit

Permalink
mostly DYNA stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
igorseabra4 committed Mar 20, 2019
1 parent d068a2d commit 86b9a6f
Show file tree
Hide file tree
Showing 60 changed files with 2,824 additions and 456 deletions.
32 changes: 11 additions & 21 deletions IndustrialPark/ArchiveEditor/ArchiveEditorFunctions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -270,21 +270,18 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.BOUL:
{
AssetBOUL newAsset = new AssetBOUL(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.BUTN:
{
AssetBUTN newAsset = new AssetBUTN(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.CAM:
{
AssetCAM newAsset = new AssetCAM(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand Down Expand Up @@ -333,21 +330,18 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.DSTR:
{
AssetDSTR newAsset = new AssetDSTR(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.DYNA:
{
AssetDYNA newAsset = new AssetDYNA(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.EGEN:
{
AssetEGEN newAsset = new AssetEGEN(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand Down Expand Up @@ -378,7 +372,6 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.HANG:
{
AssetHANG newAsset = new AssetHANG(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand Down Expand Up @@ -423,16 +416,14 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.MRKR:
{
AssetMRKR newAsset = new AssetMRKR(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.MVPT:
{
if (currentGame == Game.BFBB)
if (currentGame != Game.Scooby)
{
AssetMVPT newAsset = new AssetMVPT(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
else
Expand Down Expand Up @@ -463,7 +454,6 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.PEND:
{
AssetPEND newAsset = new AssetPEND(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand All @@ -483,21 +473,18 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.PKUP:
{
AssetPKUP newAsset = new AssetPKUP(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.PLAT:
{
AssetPLAT newAsset = new AssetPLAT(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.PLYR:
{
AssetPLYR newAsset = new AssetPLYR(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand Down Expand Up @@ -530,7 +517,6 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.SIMP:
{
AssetSIMP newAsset = new AssetSIMP(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand All @@ -542,8 +528,16 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
break;
case AssetType.SHRP:
{
AssetSHRP newAsset = new AssetSHRP(AHDR);
assetDictionary.Add(AHDR.assetID, newAsset);
if (currentGame == Game.BFBB)
{
AssetSHRP newAsset = new AssetSHRP(AHDR);
assetDictionary.Add(AHDR.assetID, newAsset);
}
else
{
Asset newAsset = new Asset(AHDR);
assetDictionary.Add(AHDR.assetID, newAsset);
}
}
break;
case AssetType.SNDI:
Expand Down Expand Up @@ -585,7 +579,6 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.TRIG:
{
AssetTRIG newAsset = new AssetTRIG(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand All @@ -598,21 +591,18 @@ private void AddAssetToDictionary(Section_AHDR AHDR, bool fast = false)
case AssetType.UI:
{
AssetUI newAsset = new AssetUI(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.UIFT:
{
AssetUIFT newAsset = new AssetUIFT(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
case AssetType.VIL:
{
AssetVIL newAsset = new AssetVIL(AHDR);
newAsset.Setup();
assetDictionary.Add(AHDR.assetID, newAsset);
}
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -474,14 +474,14 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
chuckTrigger.LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.EnterPlayer,
EventSendID = EventBFBB.DetectPlayerOn
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ExitPlayer,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -501,7 +501,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -513,14 +513,14 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
monsoonTrigger.LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.EnterPlayer,
EventSendID = EventBFBB.DetectPlayerOn
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ExitPlayer,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -545,21 +545,21 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_DOGA", AssetTemplate.ArfDog),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_DOGB", AssetTemplate.ArfDog),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_DOGC", AssetTemplate.ArfDog),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
Expand All @@ -582,14 +582,14 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_SLAVEA", AssetTemplate.TubeletSlave),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_SLAVEB", AssetTemplate.TubeletSlave),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
Expand Down Expand Up @@ -617,7 +617,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -629,14 +629,14 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
slickTrigger.LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.EnterPlayer,
EventSendID = EventBFBB.DetectPlayerOn
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.ExitPlayer,
EventSendID = EventBFBB.DetectPlayerOff
Expand All @@ -661,7 +661,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetVIL)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, template.ToString().ToUpper() + "_GROUP", AssetTemplate.Group),
EventReceiveID = EventBFBB.ScenePrepare,
EventSendID = EventBFBB.Connect_IOwnYou
Expand Down Expand Up @@ -739,7 +739,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetMVPT)asset).PositionY = position.Y;
((AssetMVPT)asset).PositionZ = position.Z;
((AssetMVPT)asset).Wt = 0x2710;
((AssetMVPT)asset).On = 0x01;
((AssetMVPT)asset).IsZone = 0x01;
((AssetMVPT)asset).BezIndex = 0x00;
((AssetMVPT)asset).Delay = 360;
((AssetMVPT)asset).ZoneRadius = 4;
Expand All @@ -750,7 +750,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetMVPT)asset).PositionY = position.Y;
((AssetMVPT)asset).PositionZ = position.Z;
((AssetMVPT)asset).Wt = 0x2710;
((AssetMVPT)asset).On = 0x01;
((AssetMVPT)asset).IsZone = 0x01;
((AssetMVPT)asset).BezIndex = 0x00;
((AssetMVPT)asset).Delay = 0;
((AssetMVPT)asset).ZoneRadius = -1;
Expand Down Expand Up @@ -783,14 +783,14 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetTRIG)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = lightsAssetID,
EventReceiveID = EventBFBB.EnterPlayer,
EventSendID = EventBFBB.Visible
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = lightsAssetID,
EventReceiveID = EventBFBB.ExitPlayer,
EventSendID = EventBFBB.Invisible
Expand Down Expand Up @@ -885,7 +885,7 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
if (template == AssetTemplate.Checkpoint)
events.Add(new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = PlaceTemplate(position, layerIndex, out success, ref assetIDs, "CHECKPOINT_TIMER", AssetTemplate.Checkpoint_Timer),
EventReceiveID = EventBFBB.EnterPlayer,
EventSendID = EventBFBB.Run
Expand All @@ -904,28 +904,28 @@ public uint PlaceTemplate(Vector3 position, int layerIndex, out bool success, re
((AssetTIMR)asset).LinksBFBB = new LinkBFBB[] {
new LinkBFBB
{
Arguments_Float = new float[] { 2, 0, 0, 0, 0, 0},
Arguments_Float = new float[] { 2, 0, 0, 0 },
TargetAssetID = checkpointSimp,
EventReceiveID = EventBFBB.Run,
EventSendID = EventBFBB.AnimPlayLoop
},
new LinkBFBB
{
Arguments_Hex = new AssetID[] { "checkpoint_text", 0, 0, 0, 0, 0},
Arguments_Hex = new AssetID[] { "checkpoint_text", 0, 0, 0 },
TargetAssetID = checkpointTalkbox,
EventReceiveID = EventBFBB.Run,
EventSendID = EventBFBB.StartConversation
},
new LinkBFBB
{
Arguments_Float = new float[] { 3, 0, 0, 0, 0, 0},
Arguments_Float = new float[] { 3, 0, 0, 0 },
TargetAssetID = checkpointSimp,
EventReceiveID = EventBFBB.Expired,
EventSendID = EventBFBB.AnimPlayLoop
},
new LinkBFBB
{
Arguments_Float = new float[6],
Arguments_Float = new float[4],
TargetAssetID = asset.AHDR.assetID,
EventReceiveID = EventBFBB.Expired,
EventSendID = EventBFBB.Disable
Expand Down
Loading

0 comments on commit 86b9a6f

Please sign in to comment.