Compare commits
26 Commits
Author | SHA1 | Date | |
---|---|---|---|
94a4368842 | |||
22862616c0 | |||
6c3d9f094e | |||
8c3ed68acb | |||
89c7eccb6f | |||
f7d86b4492 | |||
c25366d207 | |||
f9b70d8066 | |||
95871b2f89 | |||
11768dfbc2 | |||
cc55913e5a | |||
a87f5bf697 | |||
eb33a6e1ff | |||
25e9d96b44 | |||
2d2975b7ed | |||
247eef02aa | |||
a00d80918f | |||
5e4086c861 | |||
f92bea7114 | |||
029b6fa144 | |||
52507a24fd | |||
cb19485ea2 | |||
e07e98020b | |||
3e4187efd4 | |||
21b3d3aa0d | |||
8b6e1243ce |
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
*.psd
|
||||
/ignore
|
@ -1,7 +1,7 @@
|
||||
class CTI extends Info
|
||||
config(CTI);
|
||||
|
||||
const LatestVersion = 2;
|
||||
const LatestVersion = 3;
|
||||
|
||||
const CfgRemoveItems = class'RemoveItems';
|
||||
const CfgAddItems = class'AddItems';
|
||||
@ -94,6 +94,8 @@ private function PreInit()
|
||||
case 1:
|
||||
bOfficialWeaponsList = false;
|
||||
|
||||
case 2:
|
||||
|
||||
case MaxInt:
|
||||
`Log_Info("Config updated to version" @ LatestVersion);
|
||||
break;
|
||||
@ -180,7 +182,14 @@ private function PostInit()
|
||||
Preload(AddItems);
|
||||
}
|
||||
|
||||
Trader.static.ModifyTrader(KFGRI, RemoveItems, AddItems, CfgRemoveItems.default.bAll, LogLevel);
|
||||
Trader.static.ModifyTrader(
|
||||
KFGRI,
|
||||
RemoveItems,
|
||||
AddItems,
|
||||
CfgRemoveItems.default.bAll,
|
||||
CfgRemoveItems.default.bHRG,
|
||||
CfgRemoveItems.default.bDLC,
|
||||
LogLevel);
|
||||
|
||||
ReadyToSync = true;
|
||||
|
||||
@ -243,7 +252,10 @@ public function NotifyLogin(Controller C)
|
||||
{
|
||||
`Log_Trace();
|
||||
|
||||
CreateRepInfo(C);
|
||||
if (!CreateRepInfo(C))
|
||||
{
|
||||
`Log_Error("Can't create RepInfo for:" @ C);
|
||||
}
|
||||
}
|
||||
|
||||
public function NotifyLogout(Controller C)
|
||||
@ -270,7 +282,9 @@ public function bool CreateRepInfo(Controller C)
|
||||
LogLevel,
|
||||
RemoveItems,
|
||||
AddItems,
|
||||
CfgRemoveItems.default.bAll);
|
||||
CfgRemoveItems.default.bAll,
|
||||
CfgRemoveItems.default.bHRG,
|
||||
CfgRemoveItems.default.bDLC);
|
||||
|
||||
RepInfos.AddItem(RepInfo);
|
||||
|
||||
@ -298,8 +312,8 @@ public function bool DestroyRepInfo(Controller C)
|
||||
{
|
||||
if (RepInfo.Owner == C)
|
||||
{
|
||||
RepInfo.SafeDestroy();
|
||||
RepInfos.RemoveItem(RepInfo);
|
||||
RepInfo.SafeDestroy();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -15,19 +15,17 @@ public event PreBeginPlay()
|
||||
|
||||
foreach WorldInfo.DynamicActors(class'CTI', CTI)
|
||||
{
|
||||
`Log_Base("Found 'CTI'");
|
||||
break;
|
||||
}
|
||||
|
||||
if (CTI == None)
|
||||
{
|
||||
`Log_Base("Spawn 'CTI'");
|
||||
CTI = WorldInfo.Spawn(class'CTI');
|
||||
}
|
||||
|
||||
if (CTI == None)
|
||||
{
|
||||
`Log_Base("Can't Spawn 'CTI', Destroy...");
|
||||
`Log_Base("FATAL: Can't Spawn 'CTI'");
|
||||
SafeDestroy();
|
||||
}
|
||||
}
|
||||
@ -44,16 +42,16 @@ public function AddMutator(Mutator Mut)
|
||||
|
||||
public function NotifyLogin(Controller C)
|
||||
{
|
||||
Super.NotifyLogin(C);
|
||||
|
||||
CTI.NotifyLogin(C);
|
||||
|
||||
Super.NotifyLogin(C);
|
||||
}
|
||||
|
||||
public function NotifyLogout(Controller C)
|
||||
{
|
||||
Super.NotifyLogout(C);
|
||||
|
||||
CTI.NotifyLogout(C);
|
||||
|
||||
Super.NotifyLogout(C);
|
||||
}
|
||||
|
||||
DefaultProperties
|
||||
|
73
CTI/Classes/CTI_LocalMessage.uc
Normal file
73
CTI/Classes/CTI_LocalMessage.uc
Normal file
@ -0,0 +1,73 @@
|
||||
class CTI_LocalMessage extends Object
|
||||
abstract;
|
||||
|
||||
var const String SyncItemsDefault;
|
||||
var private localized String SyncItems;
|
||||
|
||||
var const String SyncFinishedDefault;
|
||||
var private localized String SyncFinished;
|
||||
|
||||
var const String WaitingGRIDefault;
|
||||
var private localized String WaitingGRI;
|
||||
|
||||
var const String IncompatibleGRIDefault;
|
||||
var private localized String IncompatibleGRI;
|
||||
|
||||
var const String DisconnectDefault;
|
||||
var private localized String Disconnect;
|
||||
|
||||
var const String SecondsShortDefault;
|
||||
var private localized String SecondsShort;
|
||||
|
||||
enum E_CTI_LocalMessageType
|
||||
{
|
||||
CTI_SyncItems,
|
||||
CTI_SyncFinished,
|
||||
CTI_WaitingGRI,
|
||||
CTI_IncompatibleGRI,
|
||||
CTI_Disconnect,
|
||||
CTI_SecondsShort
|
||||
};
|
||||
|
||||
public static function String GetLocalizedString(
|
||||
E_LogLevel LogLevel,
|
||||
E_CTI_LocalMessageType LMT,
|
||||
optional String String1,
|
||||
optional String String2,
|
||||
optional String String3)
|
||||
{
|
||||
`Log_TraceStatic();
|
||||
|
||||
switch (LMT)
|
||||
{
|
||||
case CTI_SyncItems:
|
||||
return (default.SyncItems != "" ? default.SyncItems : default.SyncItemsDefault);
|
||||
|
||||
case CTI_SyncFinished:
|
||||
return (default.SyncFinished != "" ? default.SyncFinished : default.SyncFinishedDefault);
|
||||
|
||||
case CTI_WaitingGRI:
|
||||
return (default.WaitingGRI != "" ? default.WaitingGRI : default.WaitingGRIDefault);
|
||||
|
||||
case CTI_IncompatibleGRI:
|
||||
return (default.IncompatibleGRI != "" ? default.IncompatibleGRI : default.IncompatibleGRIDefault);
|
||||
|
||||
case CTI_Disconnect:
|
||||
return (default.Disconnect != "" ? default.Disconnect : default.DisconnectDefault);
|
||||
|
||||
case CTI_SecondsShort:
|
||||
return (default.SecondsShort != "" ? default.SecondsShort : default.SecondsShortDefault);
|
||||
}
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
SyncItemsDefault = "Sync items:"
|
||||
SyncFinishedDefault = "Sync finished."
|
||||
WaitingGRIDefault = "Waiting GRI..."
|
||||
IncompatibleGRIDefault = "Incompatible GRI:"
|
||||
DisconnectDefault = "Disconnect..."
|
||||
SecondsShortDefault = "s"
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
class CTI_RepInfo extends ReplicationInfo;
|
||||
|
||||
const Trader = class'Trader';
|
||||
const Trader = class'Trader';
|
||||
const LocalMessage = class'CTI_LocalMessage';
|
||||
|
||||
var public bool PendingSync;
|
||||
|
||||
@ -9,6 +10,8 @@ var private E_LogLevel LogLevel;
|
||||
var private Array<class<KFWeaponDefinition> > RemoveItems;
|
||||
var private Array<class<KFWeaponDefinition> > AddItems;
|
||||
var private bool ReplaceMode;
|
||||
var private bool RemoveHRG;
|
||||
var private bool RemoveDLC;
|
||||
var private bool PreloadContent;
|
||||
|
||||
var private int Recieved;
|
||||
@ -28,7 +31,7 @@ var private int WaitingGRI;
|
||||
replication
|
||||
{
|
||||
if (bNetInitial && Role == ROLE_Authority)
|
||||
LogLevel, ReplaceMode, SyncSize;
|
||||
LogLevel, ReplaceMode, RemoveHRG, RemoveDLC, SyncSize;
|
||||
}
|
||||
|
||||
public simulated function bool SafeDestroy()
|
||||
@ -43,7 +46,9 @@ public function PrepareSync(
|
||||
E_LogLevel _LogLevel,
|
||||
Array<class<KFWeaponDefinition> > _RemoveItems,
|
||||
Array<class<KFWeaponDefinition> > _AddItems,
|
||||
bool _ReplaceMode)
|
||||
bool _ReplaceMode,
|
||||
bool _RemoveHRG,
|
||||
bool _RemoveDLC)
|
||||
{
|
||||
`Log_Trace();
|
||||
|
||||
@ -52,6 +57,8 @@ public function PrepareSync(
|
||||
RemoveItems = _RemoveItems;
|
||||
AddItems = _AddItems;
|
||||
ReplaceMode = _ReplaceMode;
|
||||
RemoveHRG = _RemoveHRG;
|
||||
RemoveDLC = _RemoveDLC;
|
||||
SyncSize = RemoveItems.Length + AddItems.Length;
|
||||
}
|
||||
|
||||
@ -119,7 +126,7 @@ private simulated function ShowReadyButton()
|
||||
}
|
||||
}
|
||||
|
||||
private simulated function UpdateNotification(String Title, String Downloading, String Remainig, int Percent)
|
||||
private simulated function UpdateNotification(String Title, String Left, String Right, int Percent)
|
||||
{
|
||||
`Log_Trace();
|
||||
|
||||
@ -128,8 +135,8 @@ private simulated function UpdateNotification(String Title, String Downloading,
|
||||
Notification.SetString("itemName", Title);
|
||||
Notification.SetFloat("percent", Percent);
|
||||
Notification.SetInt("queue", 0);
|
||||
Notification.SetString("downLoading", Downloading);
|
||||
Notification.SetString("remaining", Remainig);
|
||||
Notification.SetString("downLoading", Left);
|
||||
Notification.SetString("remaining", Right);
|
||||
Notification.SetObject("notificationInfo", Notification);
|
||||
Notification.SetVisible(true);
|
||||
}
|
||||
@ -164,8 +171,9 @@ private reliable client function ClientSync(class<KFWeaponDefinition> WeapDef, o
|
||||
|
||||
Recieved = RemoveItems.Length + AddItems.Length;
|
||||
|
||||
NotificationLeftText = WeapDef.static.GetItemName();
|
||||
NotificationRightText = Recieved @ "/" @ SyncSize @ "(" $ (Remove ? "remove" : "add") $ ")";
|
||||
NotificationHeaderText = (Remove ? "-" : "+") @ WeapDef.static.GetItemName();
|
||||
NotificationLeftText = LocalMessage.static.GetLocalizedString(LogLevel, CTI_SyncItems);
|
||||
NotificationRightText = Recieved @ "/" @ SyncSize;
|
||||
if (SyncSize != 0)
|
||||
{
|
||||
NotificationPercent = (float(Recieved) / float(SyncSize)) * 100;
|
||||
@ -199,8 +207,8 @@ private simulated reliable client function ClientSyncFinished()
|
||||
if (WorldInfo.GRI == None)
|
||||
{
|
||||
`Log_Debug("ClientSyncFinished: Waiting GRI");
|
||||
NotificationHeaderText = "Waiting for GameReplicationInfo...";
|
||||
NotificationLeftText = String(++WaitingGRI) $ "s";
|
||||
NotificationHeaderText = LocalMessage.static.GetLocalizedString(LogLevel, CTI_WaitingGRI);
|
||||
NotificationLeftText = String(++WaitingGRI) $ LocalMessage.static.GetLocalizedString(LogLevel, CTI_SecondsShort);
|
||||
NotificationRightText = "";
|
||||
SetTimer(1.0f, false, nameof(ClientSyncFinished));
|
||||
return;
|
||||
@ -212,20 +220,20 @@ private simulated reliable client function ClientSyncFinished()
|
||||
`Log_Fatal("Incompatible Replication info:" @ String(WorldInfo.GRI));
|
||||
ClearTimer(nameof(KeepNotification));
|
||||
UpdateNotification(
|
||||
"Incompatible GRI:" @ String(WorldInfo.GRI),
|
||||
"Disconnect...", "", 0);
|
||||
LocalMessage.static.GetLocalizedString(LogLevel, CTI_IncompatibleGRI) @ String(WorldInfo.GRI),
|
||||
LocalMessage.static.GetLocalizedString(LogLevel, CTI_Disconnect), "", 0);
|
||||
Cleanup();
|
||||
ConsoleCommand("Disconnect");
|
||||
SafeDestroy();
|
||||
return;
|
||||
}
|
||||
|
||||
NotificationHeaderText = "Sync finished";
|
||||
NotificationHeaderText = LocalMessage.static.GetLocalizedString(LogLevel, CTI_SyncFinished);
|
||||
NotificationLeftText = "";
|
||||
NotificationRightText = "";
|
||||
NotificationPercent = 0;
|
||||
|
||||
Trader.static.ModifyTrader(KFGRI, RemoveItems, AddItems, ReplaceMode, LogLevel);
|
||||
Trader.static.ModifyTrader(KFGRI, RemoveItems, AddItems, ReplaceMode, RemoveHRG, RemoveDLC, LogLevel);
|
||||
`Log_Debug("ClientSyncFinished: Trader.static.ModifyTrader");
|
||||
|
||||
ClearTimer(nameof(KeepNotification));
|
||||
@ -285,7 +293,6 @@ defaultproperties
|
||||
PendingSync = false
|
||||
Recieved = 0
|
||||
|
||||
NotificationHeaderText = "Sync trader items, please wait..."
|
||||
NotificationPercent = 0
|
||||
WaitingGRI = 0
|
||||
}
|
||||
|
7
CTI/Classes/CTI_WeapDef_G36C.uc
Normal file
7
CTI/Classes/CTI_WeapDef_G36C.uc
Normal file
@ -0,0 +1,7 @@
|
||||
class CTI_WeapDef_G36C extends KFWeapDef_G36C
|
||||
abstract;
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
SharedUnlockId = SCU_None
|
||||
}
|
7
CTI/Classes/CTI_WeapDef_HVStormCannon.uc
Normal file
7
CTI/Classes/CTI_WeapDef_HVStormCannon.uc
Normal file
@ -0,0 +1,7 @@
|
||||
class CTI_WeapDef_HVStormCannon extends KFWeapDef_HVStormCannon
|
||||
abstract;
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
SharedUnlockId = SCU_None
|
||||
}
|
7
CTI/Classes/CTI_WeapDef_Scythe.uc
Normal file
7
CTI/Classes/CTI_WeapDef_Scythe.uc
Normal file
@ -0,0 +1,7 @@
|
||||
class CTI_WeapDef_Scythe extends KFWeapDef_Scythe
|
||||
abstract;
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
SharedUnlockId = SCU_None
|
||||
}
|
7
CTI/Classes/CTI_WeapDef_ZedMKIII.uc
Normal file
7
CTI/Classes/CTI_WeapDef_ZedMKIII.uc
Normal file
@ -0,0 +1,7 @@
|
||||
class CTI_WeapDef_ZedMKIII extends KFWeapDef_ZedMKIII
|
||||
abstract;
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
SharedUnlockId = SCU_None
|
||||
}
|
@ -3,6 +3,8 @@ class RemoveItems extends Object
|
||||
config(CTI);
|
||||
|
||||
var public config bool bAll;
|
||||
var public config bool bHRG;
|
||||
var public config bool bDLC;
|
||||
var private config Array<String> Item;
|
||||
|
||||
public static function InitConfig(int Version, int LatestVersion)
|
||||
@ -12,6 +14,10 @@ public static function InitConfig(int Version, int LatestVersion)
|
||||
case `NO_CONFIG:
|
||||
ApplyDefault();
|
||||
|
||||
case 2:
|
||||
default.bHRG = false;
|
||||
default.bDLC = false;
|
||||
|
||||
default: break;
|
||||
}
|
||||
|
||||
@ -24,6 +30,8 @@ public static function InitConfig(int Version, int LatestVersion)
|
||||
private static function ApplyDefault()
|
||||
{
|
||||
default.bAll = false;
|
||||
default.bHRG = false;
|
||||
default.bDLC = false;
|
||||
default.Item.Length = 0;
|
||||
default.Item.AddItem("KFGame.KFWeapDef_9mmDual");
|
||||
}
|
||||
@ -43,6 +51,15 @@ public static function Array<class<KFWeaponDefinition> > Load(E_LogLevel LogLeve
|
||||
}
|
||||
else
|
||||
{
|
||||
if (default.bHRG)
|
||||
{
|
||||
`Log_Info("Remove all HRG items");
|
||||
}
|
||||
if (default.bDLC)
|
||||
{
|
||||
`Log_Info("Remove all DLC items");
|
||||
}
|
||||
|
||||
foreach default.Item(ItemRaw, Line)
|
||||
{
|
||||
ItemWeapDef = class<KFWeaponDefinition>(DynamicLoadObject(ItemRaw, class'Class'));
|
||||
|
@ -91,6 +91,8 @@ public static simulated function ModifyTrader(
|
||||
Array<class<KFWeaponDefinition> > RemoveItems,
|
||||
Array<class<KFWeaponDefinition> > AddItems,
|
||||
bool ReplaceMode,
|
||||
bool RemoveHRG,
|
||||
bool RemoveDLC,
|
||||
E_LogLevel LogLevel)
|
||||
{
|
||||
local KFGFxObject_TraderItems TraderItems;
|
||||
@ -110,6 +112,8 @@ public static simulated function ModifyTrader(
|
||||
{
|
||||
if (Item.WeaponDef != None
|
||||
&& RemoveItems.Find(Item.WeaponDef) == INDEX_NONE
|
||||
&& (!RemoveHRG || (RemoveHRG && InStr(Item.WeaponDef, "_HRG", true) == INDEX_NONE))
|
||||
&& (!RemoveDLC || (RemoveDLC && Item.WeaponDef.default.SharedUnlockId == SCU_None))
|
||||
&& WeaponClassIsUnique(Item.WeaponDef.default.WeaponClassPath, AddItems, LogLevel))
|
||||
{
|
||||
WeapDefs.AddItem(Item.WeaponDef);
|
||||
|
@ -169,27 +169,31 @@ private static function bool ReplaceFilter(KFGameInfo KFGI, E_LogLevel LogLevel)
|
||||
|
||||
defaultproperties
|
||||
{
|
||||
WeapDefDLCReplacements(0) = class'CTI_WeapDef_AutoTurret'
|
||||
WeapDefDLCReplacements(1) = class'CTI_WeapDef_BladedPistol'
|
||||
WeapDefDLCReplacements(2) = class'CTI_WeapDef_Blunderbuss'
|
||||
WeapDefDLCReplacements(3) = class'CTI_WeapDef_ChainBat'
|
||||
WeapDefDLCReplacements(4) = class'CTI_WeapDef_ChiappaRhino'
|
||||
WeapDefDLCReplacements(5) = class'CTI_WeapDef_ChiappaRhinoDual'
|
||||
WeapDefDLCReplacements(6) = class'CTI_WeapDef_CompoundBow'
|
||||
WeapDefDLCReplacements(7) = class'CTI_WeapDef_Doshinegun'
|
||||
WeapDefDLCReplacements(8) = class'CTI_WeapDef_DualBladed'
|
||||
WeapDefDLCReplacements(9) = class'CTI_WeapDef_FAMAS'
|
||||
WeapDefDLCReplacements(10) = class'CTI_WeapDef_G18'
|
||||
WeapDefDLCReplacements(11) = class'CTI_WeapDef_GravityImploder'
|
||||
WeapDefDLCReplacements(12) = class'CTI_WeapDef_IonThruster'
|
||||
WeapDefDLCReplacements(13) = class'CTI_WeapDef_Mine_Reconstructor'
|
||||
WeapDefDLCReplacements(14) = class'CTI_WeapDef_Minigun'
|
||||
WeapDefDLCReplacements(15) = class'CTI_WeapDef_MosinNagant'
|
||||
WeapDefDLCReplacements(16) = class'CTI_WeapDef_ParasiteImplanter'
|
||||
WeapDefDLCReplacements(17) = class'CTI_WeapDef_Pistol_DualG18'
|
||||
WeapDefDLCReplacements(18) = class'CTI_WeapDef_Pistol_G18C'
|
||||
WeapDefDLCReplacements(19) = class'CTI_WeapDef_Rifle_FrostShotgunAxe'
|
||||
WeapDefDLCReplacements(20) = class'CTI_WeapDef_ShrinkRayGun'
|
||||
WeapDefDLCReplacements(21) = class'CTI_WeapDef_ThermiteBore'
|
||||
WeapDefDLCReplacements(22) = class'CTI_WeapDef_Zweihander'
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_AutoTurret')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_BladedPistol')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Blunderbuss')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ChainBat')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ChiappaRhino')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ChiappaRhinoDual')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_CompoundBow')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Doshinegun')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_DualBladed')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_FAMAS')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_G18')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_G36C')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_GravityImploder')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_HVStormCannon')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_IonThruster')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Mine_Reconstructor')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Minigun')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_MosinNagant')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ParasiteImplanter')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Pistol_DualG18')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Pistol_G18C')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Rifle_FrostShotgunAxe')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Scythe')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ShrinkRayGun')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ThermiteBore')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_ZedMKIII')
|
||||
WeapDefDLCReplacements.Add(class'CTI_WeapDef_Zweihander')
|
||||
}
|
||||
|
@ -4,6 +4,7 @@ class _Logger extends Object
|
||||
enum E_LogLevel
|
||||
{
|
||||
LL_WrongLevel,
|
||||
LL_None,
|
||||
LL_Fatal,
|
||||
LL_Error,
|
||||
LL_Warning,
|
||||
|
BIN
Localization/INT/CTI.int
Normal file
BIN
Localization/INT/CTI.int
Normal file
Binary file not shown.
BIN
Localization/RUS/CTI.rus
Normal file
BIN
Localization/RUS/CTI.rus
Normal file
Binary file not shown.
@ -1,4 +1,4 @@
|
||||
[img]https://img.shields.io/static/v1?logo=GitHub&labelColor=gray&color=blue&logoColor=white&label=&message=Open Source[/img] [img]https://img.shields.io/github/license/GenZmeY/KF2-CustomTraderInventory[/img] [img]https://img.shields.io/steam/subscriptions/2830826239[/img] [img]https://img.shields.io/steam/favorites/2830826239[/img] [img]https://img.shields.io/steam/update-date/2830826239[/img] [url=https://steamcommunity.com/sharedfiles/filedetails/changelog/2830826239][img]https://img.shields.io/github/v/tag/GenZmeY/KF2-CustomTraderInventory[/img][/url]
|
||||
[img]https://img.shields.io/static/v1?logo=GitHub&labelColor=gray&color=blue&logoColor=white&label=&message=Open Source[/img] [img]https://img.shields.io/github/license/GenZmeY/KF2-CustomTraderInventory[/img] [img]https://img.shields.io/steam/downloads/2830826239[/img] [img]https://img.shields.io/steam/favorites/2830826239[/img] [img]https://img.shields.io/steam/update-date/2830826239[/img] [url=https://steamcommunity.com/sharedfiles/filedetails/changelog/2830826239][img]https://img.shields.io/github/v/tag/GenZmeY/KF2-CustomTraderInventory[/img][/url]
|
||||
|
||||
[h1]Features[/h1]
|
||||
[list]
|
||||
@ -16,7 +16,7 @@ No. This mod is not whitelisted and will de-rank your server. Any XP gained will
|
||||
[olist]
|
||||
[*]Subscribe to this mutator;
|
||||
[*]Start KF2;
|
||||
[*]Open console (`) and input:
|
||||
[*]Open console (~) and input:
|
||||
[b]open KF-BioticsLab?Mutator=CTI.CTIMut[/b]
|
||||
(replace the map and add the parameters you need)
|
||||
[*]<Enter>.
|
||||
@ -34,27 +34,51 @@ No. This mod is not whitelisted and will de-rank your server. Any XP gained will
|
||||
[*]Add mutator to server start parameters: [b]?Mutator=CTI.CTIMut[/b] and restart the server.
|
||||
[/olist]
|
||||
|
||||
[h1]Important setup information[/h1]
|
||||
The config should be created on first start, but now the game contains a bug that initializes the config values randomly if they are not explicitly set. Thus, the config may have incorrect values or not be created at all.
|
||||
So if you are using this mutator for the first time, I highly recommend doing the following:
|
||||
[olist]
|
||||
[*]Create (modify) [b]KFCTI.ini[/b] manually. Put the following content there:
|
||||
[b][CTI.CTI]
|
||||
Version=0[/b]
|
||||
[*]Start the game/server with CTI to generate the contents of the config.
|
||||
[*]Close the game/server.
|
||||
[/olist]
|
||||
[b]Right now this is the only way to correctly create the default config.[/b]
|
||||
Unfortunately I can't do anything about it because it's a game problem (not mutator). I hope TWI fixes this someday.
|
||||
|
||||
[h1]Setup (KFCTI.ini)[/h1]
|
||||
Config will be created at the first start.
|
||||
[list]
|
||||
[*]Set [b]bPreloadContent=True[/b] to load weapon models in advance and have no lags during the game.
|
||||
|
||||
[*]Set [b]bOfficialWeaponsList=True[/b] to have an auto-updated list of all official weapons in the config (for a convenient copy-paste).
|
||||
|
||||
[*]Set [b]UnlockDLC[/b] to customize DLC weapon unlocks. Here are the possible values:
|
||||
[b]False[/b] - disable DLC unlock.
|
||||
[b]ReplaceFilter[/b] - changes the trader filter allowing you to buy original DLC weapons without restrictions, unlocks future DLCs as well (no need to update this mutator). However, it replaces the [b]KFGFxMoviePlayer_Manager[/b] class so it may not be compatible with mods that also replace it.
|
||||
[b]ReplaceWeapons[/b] - replaces DLC weapons with their unlocked variants. Compatible with any mods, but may require a CTI update after the release of new DLC weapons.
|
||||
[b]True[/b] or [b]Auto[/b] - selects the most appropriate option automatically. Recommend putting CTIMut last in the mutator load queue if you use this.
|
||||
[*]Use [b][CTI.RemoveItems][/b] to remove items from the trader inventory.
|
||||
For example: [b]Item=KFGame.KFWeapDef_Mac10[/b] will remove MAC10 from sale.
|
||||
[*]Set [b]bAll=True[/b] if you want to remove all items (can be useful if you want to set the entire sale list in the [b][CTI.AddItems][/b] section yourself).
|
||||
[*]Use [b][CTI.AddItems][/b] to add items to the trader inventory.
|
||||
For example: [b]Item=WeaponPack.KFWeapDef_XM25[/b] will add [url=https://steamcommunity.com/sharedfiles/filedetails/?id=1147408497]XM25[/url] to sale.
|
||||
[list]
|
||||
[*][b]False[/b] - disable DLC unlock.
|
||||
[*][b]ReplaceFilter[/b] - changes the trader filter allowing you to buy original DLC weapons without restrictions, unlocks future DLCs as well (no need to update this mutator). However, it replaces the - [b]KFGFxMoviePlayer_Manager[/b] class so it may not be compatible with mods that also replace it.
|
||||
[*][b]ReplaceWeapons[/b] - replaces DLC weapons with their unlocked variants. Compatible with any mods, but may require a CTI update after the release of new DLC weapons.
|
||||
[*][b]True[/b] or [b]Auto[/b] - selects the most appropriate option automatically. Recommend putting CTIMut last in the mutator load queue if you use this.
|
||||
[/list]
|
||||
[h1]🔗 [url=https://steamcommunity.com/workshop/filedetails/discussion/2830826239/3409804177172972154]Weapon Packs Items[/url][/h1]
|
||||
|
||||
[*]Use [b][CTI.RemoveItems][/b] to remove items from the trader inventory.
|
||||
example: [b]Item=KFGame.KFWeapDef_Mac10[/b] will remove MAC10 from sale.
|
||||
|
||||
[*]Set [b]bAll=True[/b] if you want to remove all items (can be useful if you want to set the entire sale list in the [b][CTI.AddItems][/b] section yourself).
|
||||
[*]Set [b]bHRG=True[/b] to remove HRG items.
|
||||
[*]Set [b]bDLC=True[/b] to remove DLC items.
|
||||
|
||||
[*]Use [b][CTI.AddItems][/b] to add items to the trader inventory.
|
||||
example: [b]Item=WeaponPack.KFWeapDef_XM25[/b] will add [url=https://steamcommunity.com/sharedfiles/filedetails/?id=1147408497]XM25[/url] to sale.
|
||||
[/list]
|
||||
|
||||
❗️ Note that if you need an empty list anywhere (for example, you don't want to delete some of the traders's weapons), leave at least one line there:
|
||||
[b]Item=""[/b]
|
||||
This is necessary to explicitly initialize the list (because of the bug I wrote about above) to avoid initialization with random values.
|
||||
|
||||
[h1]Notes[/h1]
|
||||
📌 Mutator does not contain custom weapons. You must have the required weapon packs in your subscriptions to be able to add them to the trader.
|
||||
📌 If you are using this mutator to add weapons, you should [b]not[/b] use mutators from weapon packs (just having them in subscriptions is enough).
|
||||
|
||||
[h1]Sources[/h1]
|
||||
[url=https://github.com/GenZmeY/KF2-CustomTraderInventory]https://github.com/GenZmeY/KF2-CustomTraderInventory[/url] [b](GNU GPLv3)[/b]
|
||||
[url=https://github.com/GenZmeY/KF2-CustomTraderInventory]https://github.com/GenZmeY/KF2-CustomTraderInventory[/url] [b](GNU GPLv3)[/b]
|
||||
|
@ -1,7 +1,7 @@
|
||||
# Custom Trader Inventory
|
||||
|
||||
[](https://steamcommunity.com/sharedfiles/filedetails/?id=2830826239)
|
||||
[](https://steamcommunity.com/sharedfiles/filedetails/?id=2830826239)
|
||||
[](https://steamcommunity.com/sharedfiles/filedetails/?id=2830826239)
|
||||
[](https://steamcommunity.com/sharedfiles/filedetails/?id=2830826239)
|
||||
[](https://steamcommunity.com/sharedfiles/filedetails/?id=2830826239)
|
||||
[](https://github.com/GenZmeY/KF2-CustomTraderInventory/tags)
|
||||
|
11
builder.cfg
11
builder.cfg
@ -11,6 +11,15 @@ StripSource="True"
|
||||
PackageBuildOrder="CTI"
|
||||
|
||||
|
||||
### Brew parameters ###
|
||||
|
||||
# Packages you want to brew using @peelz's patched KFEditor.
|
||||
# Useful for cases where regular brew doesn't put *.upk inside the package.
|
||||
# Specify them with a space as a separator,
|
||||
# The order doesn't matter
|
||||
PackagePeelzBrew=""
|
||||
|
||||
|
||||
### Steam Workshop upload parameters ###
|
||||
|
||||
# Mutators that will be uploaded to the workshop
|
||||
@ -30,7 +39,7 @@ Map="KF-Nuked"
|
||||
# Endless: KFGameContent.KFGameInfo_Endless
|
||||
# Objective: KFGameContent.KFGameInfo_Objective
|
||||
# Versus: KFGameContent.KFGameInfo_VersusSurvival
|
||||
Game="KFGameContent.KFGameInfo_Endless"
|
||||
Game="KFGameContent.KFGameInfo_Survival"
|
||||
|
||||
# Difficulty:
|
||||
# Normal: 0
|
||||
|
2
tools
2
tools
Submodule tools updated: 2f173aad7a...d830a5ea16
Reference in New Issue
Block a user