## XIDInterf
Class XIIIMenuCheatClientWindow

source: C:\XIII\XIDInterf\Classes\XIIIMenuCheatClientWindow.uc

    Core.Object
       |
       +--GUI.GUI
          |
          +--GUI.GUIComponent
             |
             +--GUI.GUIMultiComponent
                |
                +--GUI.GUIPage
                   |
                   +--XIDInterf.XIIIWindow
                      |
                      +--XIDInterf.XIIIMenuCheatClientWindow

Direct Known Subclasses:None

class XIIIMenuCheatClientWindow
extends XIDInterf.XIIIWindow

    //============================================================================
    // Special menu for cheaters
    //============================================================================

Variables
`NeuText,` | `GhostText`
`NeuButton,` | `Ghostbutton`

Function Summary
`void` | `Created()`
`bool` | `InternalOnKeyEvent(out byte, out byte, float delta)`
`void` | `Paint(Canvas C, float X, float Y)`
`void` | `ShowWindow()`

Source Code

    00001	//============================================================================
    00002	// Special menu for cheaters
    00003	//============================================================================
    00004	class XIIIMenuCheatClientWindow extends XIIIWindow;
    00005
    00006	var XIIIbutton DndButton, GodButton, FlyButton, EquipButton, NeuButton, Ghostbutton;
    00007	var localized string DndText, GodText, FlyText, EquipText, NeuText, GhostText;
    00008
    00009
    00010	function Created()
    00011	{
    00012	     Super.Created();
    00013
    00014	     GodButton = XIIIbutton(CreateControl(class'XIIIbutton', 230, 160, 200, 30));
    00015	     GodButton.Text=GodText;
    00016	     GodButton.bNoBg =true;
    00017	     FlyButton = XIIIbutton(CreateControl(class'XIIIbutton', 230, 190, 200, 30));
    00018	     FlyButton.Text = FlyText;
    00019	     FlyButton.bNoBg =true;
    00020	     EquipButton = XIIIbutton(CreateControl(class'XIIIbutton', 230, 220, 200, 30));
    00021	     EquipButton.Text=EquipText;
    00022	     EquipButton.bNoBg =true;
    00023	     DndButton = XIIIbutton(CreateControl(class'XIIIbutton', 230, 250, 200, 30));
    00024	     DndButton.Text=NeuText;
    00025	     DndButton.bNoBg =true;
    00026	     GhostButton = XIIIbutton(CreateControl(class'XIIIbutton', 230, 280, 200, 30));
    00027	     GhostButton.Text=GhostText;
    00028	     GhostButton.bNoBg =true;
    00029
    00030	    Controls[0] = GodButton; Controls[1] = FlyButton;
    00031	    Controls[2] = EquipButton; Controls[3] = DndButton; Controls[4] = GhostButton;
    00032	}
    00033
    00034
    00035	function ShowWindow()
    00036	{
    00037	     OnMenu = 0;
    00038	     Super.ShowWindow();
    00039	     bShowBCK = true; bShowSEL = true;
    00040	}
    00041
    00042
    00043	function Paint(Canvas C, float X, float Y)
    00044	{
    00045	     Super.Paint(C, X, Y);
    00046	    C.bUseBorder = true; C.DrawColor = WhiteColor;
    00047	    DrawStretchedTexture(C, 220*fRatioX, 130*fRatioY*fScaleTo, 220*fRatioX, 230*fRatioY*fScaleTo, myRoot.FondMenu);
    00048	    C.bUseBorder = false;
    00049	}
    00050
    00051
    00052	function bool InternalOnKeyEvent(out byte Key, out byte State, float delta)
    00053	{
    00054	    if (State==1)// IST_Press // to avoid auto-repeat
    00055	    {
    00056	        if ((Key==0x0D/*IK_Enter*/) || (Key==0x01))
    00057		    {
    00058	            //Controller.FocusedControl.OnClick(Self);
    00059	            switch(FindComponentIndex(FocusedControl))
    00060	            {
    00061	               case 0: GetPlayerOwner().ConsoleCommand("God");
    00062	               break;
    00063	               case 1: GetPlayerOwner().ConsoleCommand("TeleportNext");
    00064	               break;
    00065	               case 2: GetPlayerOwner().ConsoleCommand("EquipMe");
    00066	               break;
    00067	               case 3: GetPlayerOwner().ConsoleCommand("DAndD");
    00068	               break;
    00069	               case 4: GetPlayerOwner().ConsoleCommand("Ghost");
    00070	               break;
    00071	            }
    00072	            //myRoot.CloseMenu(true);
    00073	            return true;
    00074		    }
    00075		    if ((Key==0x08/*IK_Backspace*/)|| (Key==0x1B))
    00076		    {
    00077		        myRoot.CloseMenu(true);
    00078	    	    return true;
    00079		    }
    00080		    if (Key==0x26/*IK_Up*/)
    00081		    {
    00082		        PrevControl(FocusedControl);
    00083	    	    return true;
    00084		    }
    00085		    if (Key==0x28/*IK_Down*/)
    00086		    {
    00087		        NextControl(FocusedControl);
    00088	    	    return true;
    00089		    }
    00090	        //return false;
    00091	    }
    00092	    return super.InternalOnKeyEvent(Key, state, delta);
    00093	//    return false;
    00094	}
    00095
    00096
    00097
    00098
    00099
    00100	defaultproperties
    00101	{
    00102	     DndText="Deaf & Dumb"
    00103	     GodText="God"
    00104	     FlyText="Teleport"
    00105	     EquipText="EquipMe"
    00106	     NeuText="Neu neu"
    00107	     GhostText="Ghost"
    00108	     Background=None
    00109	}

End Source Code