I should have totally seen that coming, will fix it ASAP (increase buffer sizes)
Code: Select all
void UXC_GameEngine::PerformSetCommand( const TCHAR* Str, FOutputDevice& Ar, UBOOL bNotifyObjectOfChange )
{
// Set a class default variable.
TCHAR ClassName[64], PropertyName[64], ThirdParam[256], FourthParam[256];
===================
Update, fixed.
Decided to operate directly on the TCHAR stream if possible, still don't know the actual engine command size limit. Anyone knows?
The actual function is here:
Code: Select all
void UXC_GameEngine::PerformSetCommand( const TCHAR* Str, FOutputDevice& Ar, UBOOL bNotifyObjectOfChange )
{
// Set a class default variable, names are up to 64 chars and classname can go as (Package.Class)
TCHAR ClassName[128], PropertyName[64], Number[128];
UClass* Class;
UProperty* Property;
if ( ParseToken( Str, ClassName, ARRAY_COUNT(ClassName), 1 )
&& (Class=FindObject<UClass>( ANY_PACKAGE, ClassName))!=NULL )
{
if ( ParseToken( Str, PropertyName, ARRAY_COUNT(PropertyName), 1 )
&& (Property=FindField<UProperty>( Class, PropertyName))!=NULL )
{
while ( *Str==' ')
Str++;
const TCHAR* Tester = Str;
if ( !(*Tester) ) //Nothing to do here
return;
while ( *Tester!=' ' && *Tester ) //Go ahead until i've gone thru all the token
Tester++;
while ( *Tester==' ')
Tester++;
if ( !(*Tester) ) //There was only one token, use Str directly as parameter
UObject::GlobalSetProperty( Str, Class, Property, Property->Offset, bNotifyObjectOfChange );
else if ( ParseToken( Str, Number, 64, 1) ) //Parse the parameter we just went through
{
while ( *Str==' ') //And remove spaces from main stream
Str++;
INT Idx = Clamp(appAtoi( Number), 0, Property->ArrayDim);
UObject::GlobalSetProperty( Str, Class, Property, Property->Offset + Idx * Property->ElementSize, bNotifyObjectOfChange );
}
else
debugf((EName)XC_ENGINE_XC_Engine.GetIndex(), TEXT("PerformSetCommand: SOMETHING IS NOT RIGHT!"));;
}
else
Ar.Logf( NAME_ExecWarning, TEXT("Unrecognized property %s"), PropertyName );
}
else
Ar.Logf( NAME_ExecWarning, TEXT("Unrecognized class %s"), ClassName );
}
Also, the Nexgen PreLoginHook does let the players know the ban reason upon being rejected, you just have to look into the log: