Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

ROInterface.ROTab_Input


00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
//=============================================================================
// ROTab_Input
//=============================================================================
// The input config tab
//=============================================================================
// Red Orchestra Source
// Copyright (C) 2005 Mathieu Mallet
//=============================================================================

class ROTab_Input extends UT2K4Tab_IForceSettings;

event InitComponent(GUIController MyController, GUIComponent MyOwner)
{
	super(Settings_Tabs).Initcomponent(MyController, MyOwner);

	RemoveComponent(ch_WeaponEffects);
	RemoveComponent(ch_PickupEffects);
	RemoveComponent(ch_DamageEffects);
	RemoveComponent(ch_GUIEffects);
	RemoveComponent(fl_DodgeTime);
	RemoveComponent(b_Controls);
	RemoveComponent(b_Speech);

	RemoveComponent(i_BG2);

    i_BG1.ManageComponent(ch_AutoSlope);
    i_BG1.ManageComponent(ch_InvertMouse);
    i_BG1.ManageComponent(ch_MouseSmoothing);
    i_BG1.ManageComponent(ch_MouseLag);
    i_BG1.ManageComponent(ch_Joystick);

    i_BG3.ManageComponent(fl_Sensitivity);
    i_BG3.ManageComponent(fl_MenuSensitivity);
    i_BG3.ManageComponent(fl_SmoothingStrength);
    i_BG3.ManageComponent(fl_MouseAccel);

    // Disable force feedback options on non-win32 platforms...  --ryan.
    if ( (!PlatformIsWindows()) || (PlatformIs64Bit()) )
    {
        ch_WeaponEffects.DisableMe();
        ch_PickupEffects.DisableMe();
        ch_DamageEffects.DisableMe();
        ch_GUIEffects.DisableMe();
    }
}

function InternalOnLoadINI(GUIComponent Sender, string s)
{
    local PlayerController player;
    player = PlayerOwner();
    switch (Sender)
	{
    	case fl_Sensitivity:
    	    if (player != none)
    	        fSens  = player.GetMouseSensitivity();
    	    else
                fSens = class'PlayerInput'.default.MouseSensitivity;
    		fl_Sensitivity.SetComponentValue(fSens,true);
    		break;

		case fl_MouseAccel:
		    if (player != none)
    		    fAccel = player.GetMouseAcceleration();
    	    else
    	        fAccel = class'PlayerInput'.Default.MouseAccelThreshold;
    		fl_MouseAccel.SetComponentValue(fAccel,true);
    		break;

    	case fl_SmoothingStrength:
    	    if (player != none)
    		    fSmoothing = player.GetMouseSmoothingStrength();
    	    else
    	        fSmoothing = class'PlayerInput'.Default.MouseSmoothingStrength;
    		fl_SmoothingStrength.SetComponentValue(fSmoothing,true);
    		break;

	    default:
	        super.InternalOnLoadINI(Sender, s);
	}
}

defaultproperties
{
     Begin Object Class=GUISectionBackground Name=InputBK1
         Caption="Options"
         WinTop=0.250000
         WinLeft=0.021641
         WinWidth=0.381328
         WinHeight=0.500000
         OnPreDraw=InputBK1.InternalPreDraw
     End Object
     i_BG1=GUISectionBackground'ROInterface.ROTab_Input.InputBK1'

     Begin Object Class=GUISectionBackground Name=InputBK3
         Caption="Fine Tuning"
         WinTop=0.300000
         WinLeft=0.451289
         WinWidth=0.527812
         WinHeight=0.400000
         OnPreDraw=InputBK3.InternalPreDraw
     End Object
     i_BG3=GUISectionBackground'ROInterface.ROTab_Input.InputBK3'

}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: Fri 13-10-2023 03:17:28.000 - Creation time: Fri 13-10-2023 03:19:07.615 - Created with UnCodeX