There is no spoon

Legacy:UT2ArenaConfig

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search

My feeble attempt at explaining the UT2003 Arena Mutator config menu script:

class UT2ArenaConfig extends GUIPage;
 
var array<class<Weapon> >	WeaponClass< SEMI >
var array<String>			WeaponDesc;
 
var moComboBox				WeaponCombo;
 
function InitComponent(GUIController MyController, GUIComponent MyOwner)
{
	Super.InitComponent(MyController, MyOwner);
 
	WeaponCombo = moComboBox(Controls[4]);
 
	// Spawn 'please wait' screen while we DLO the weapons
	if ( Controller.OpenMenu("xinterface.UT2LoadingWeaponsArena") )
		UT2LoadingWeaponsArena(Controller.TopPage()).StartLoad(self);
}
 
function bool InternalOnClick(GUIComponent Sender)
{
	class'MutArena'.default.ArenaWeaponClassName = WeaponCombo.GetExtra();
	class'MutArena'.static.StaticSaveConfig();
 
	Controller.CloseMenu(false);
 
	return true;
}
 
defaultproperties
{
     Controls(0)=GUIButton'XInterface.UT2ArenaConfig.DialogBackground'
     Controls(1)=GUIButton'XInterface.UT2ArenaConfig.OkButton'
     Controls(2)=GUILabel'XInterface.UT2ArenaConfig.DialogText'
     Controls(3)=GUILabel'XInterface.UT2ArenaConfig.DialogText2'
     Controls(4)=moComboBox'XInterface.UT2ArenaConfig.WeaponSelect'
     WinTop=0.300000     // Define where the top of the window is on screen
     WinHeight=0.400000  // Define the size of the window
}

Well I told you it was feeble ;-P

But now at least the code's here.

El Muerte TDS: you may want to use the real source code (from the source code release) rather than the exported code, you are missing the GUI Object declarations.