mirror of
https://mirror.ghproxy.com/https://github.com/dexyfex/CodeWalker
synced 2026-05-14 16:04:49 +08:00
Collisions editing progress
This commit is contained in:
@@ -62,5 +62,17 @@ namespace CodeWalker.GameFiles
|
||||
return data;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public bool RemoveBounds(Bounds b)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
public bool RemovePoly(BoundPolygon p)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3516,7 +3516,7 @@ namespace CodeWalker.GameFiles
|
||||
}
|
||||
public void TestYbns()
|
||||
{
|
||||
bool savetest = false;
|
||||
bool savetest = true;
|
||||
var errorfiles = new List<RpfEntry>();
|
||||
foreach (RpfFile file in AllRpfs)
|
||||
{
|
||||
@@ -3674,7 +3674,8 @@ namespace CodeWalker.GameFiles
|
||||
}
|
||||
public void TestYdrs()
|
||||
{
|
||||
bool savetest = false;
|
||||
bool savetest = true;
|
||||
bool boundsonly = true;
|
||||
var errorfiles = new List<RpfEntry>();
|
||||
foreach (RpfFile file in AllRpfs)
|
||||
{
|
||||
@@ -3701,6 +3702,9 @@ namespace CodeWalker.GameFiles
|
||||
if (fentry == null)
|
||||
{ continue; } //shouldn't happen
|
||||
|
||||
if (boundsonly && (ydr.Drawable.Bound == null))
|
||||
{ continue; }
|
||||
|
||||
var bytes = ydr.Save();
|
||||
|
||||
string origlen = TextUtil.GetBytesReadable(fentry.FileSize);
|
||||
@@ -3783,7 +3787,7 @@ namespace CodeWalker.GameFiles
|
||||
}
|
||||
public void TestYfts()
|
||||
{
|
||||
bool savetest = false;
|
||||
bool savetest = true;
|
||||
var errorfiles = new List<RpfEntry>();
|
||||
foreach (RpfFile file in AllRpfs)
|
||||
{
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -648,6 +648,11 @@ namespace CodeWalker.GameFiles
|
||||
this.Unknown_140h_Pointer // offset
|
||||
);
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
|
||||
if (Unknown_70h?.data_items?.Length > 0)
|
||||
{ }
|
||||
if (Unknown_80h?.data_items?.Length > 0)
|
||||
@@ -1132,6 +1137,11 @@ namespace CodeWalker.GameFiles
|
||||
this.BoundPointer // offset
|
||||
);
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -2768,6 +2768,12 @@ namespace CodeWalker.GameFiles
|
||||
this.Bound = reader.ReadBlockAt<Bounds>(
|
||||
this.BoundPointer // offset
|
||||
);
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
|
||||
}
|
||||
catch (Exception ex) //sometimes error here for loading particles! different drawable type? base only?
|
||||
{
|
||||
|
||||
@@ -453,6 +453,11 @@ namespace CodeWalker.GameFiles
|
||||
FragMatrices = reader.ReadStructsAt<Matrix>(FragMatricesPointer, FragMatricesCount);
|
||||
Name = reader.ReadStringAt(NamePointer);
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
|
||||
if ((Count3 != Count4)&&(Count4!=1)&&(Count3!=0))
|
||||
{ }
|
||||
if (FragMatricesInds != null)
|
||||
@@ -1272,6 +1277,11 @@ namespace CodeWalker.GameFiles
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -2123,6 +2133,11 @@ namespace CodeWalker.GameFiles
|
||||
this.Bound = reader.ReadBlockAt<Bounds>(
|
||||
this.BoundPointer // offset
|
||||
);
|
||||
|
||||
if (Bound != null)
|
||||
{
|
||||
Bound.Owner = this;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -828,7 +828,7 @@ namespace CodeWalker.GameFiles
|
||||
public uint EntriesCapacity { get; private set; }
|
||||
|
||||
// reference data
|
||||
public T[] data_items { get; private set; }
|
||||
public T[] data_items { get; set; }
|
||||
|
||||
private ResourceSystemStructBlock<T> data_block;//used for saving.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user