Upload from upload_mods.ps1

This commit is contained in:
Nathaniel Cosford
2025-06-04 16:13:32 +09:30
commit 7345f42201
470 changed files with 51966 additions and 0 deletions

View File

@@ -0,0 +1,49 @@
using KFCommonUtilityLib.Scripts.Utilities;
class NetPackageFixedReload : NetPackage
{
private int entityId;
private byte actionIndex;
public NetPackageFixedReload Setup(int entityId, int actionIndex)
{
this.entityId = entityId;
this.actionIndex = (byte)actionIndex;
return this;
}
public override int GetLength()
{
return 5;
}
public override void ProcessPackage(World _world, GameManager _callbacks)
{
if (_world == null)
{
return;
}
if (!_world.IsRemote())
{
MultiActionUtils.FixedItemReloadServer(entityId, actionIndex);
}
else
{
MultiActionUtils.FixedItemReloadClient(entityId, actionIndex);
}
}
public override void read(PooledBinaryReader _reader)
{
entityId = _reader.ReadInt32();
actionIndex = _reader.ReadByte();
}
public override void write(PooledBinaryWriter _writer)
{
base.write(_writer);
_writer.Write(entityId);
_writer.Write(actionIndex);
}
}