internal TransferPump(string resourceName, TypePump pumpType, TriggerButton trigger, double pumpAmount) { Resource = resourceName; PumpType = pumpType; PumpTrigger = trigger; PumpAmount = pumpAmount; }
public Credits(int anzahllevel) { this.anzahllevel = anzahllevel; buttons[0] = new Button(new Vector2(60, 370), "MainMenu", "Zurück"); trigger[0] = new TriggerButton(new Vector2(creditsPositionX, creditsPositionY), "Zurück"); trigger[1] = new TriggerButton(new Vector2(creditsPositionX + 300, creditsPositionY), "Weiter"); }
private void Awake() { if (Instance == null) { Instance = this; } else { Destroy(gameObject); } }
public Rangliste(int anzahllevel) { this.anzahlLevel = anzahllevel; buttons[0] = new Button(new Vector2(60, 370), "MainMenu", "Zurück"); int positionX = 310; int positionY = 20; trigger[0] = new TriggerButton(new Vector2(positionX, positionY), "Zurück"); trigger[1] = new TriggerButton(new Vector2(positionX + 300, positionY), "Weiter"); checkRangliste(1); }
protected override void Update() { if (Controller == null) { Debug.Log("Controller not lnitialized"); return; } TriggerButton.OnPress(Controller); GripButton.OnPress(Controller); TouchpadButton.OnPress(Controller); ApplicationMenuButton.OnPress(Controller); SystemMenuButton.OnPress(Controller); }
void Start() { //Implements Singleton if (_instance != null) { Debug.LogError("Can't initialize more than one instance of Game Manager!"); return; } _currentPlayerShips = new List <Player>(); _instance = this; _needToInitSeebrightCamera = gameObject.GetComponent <SeebrightSDK>().enabled = enableSeebright; #if UNITY_IPHONE if (!enableSeebright && !isMenu) { if (joystickLeft != null) { joystickLeft.SetActive(true); _joystickLeftAPI = joystickLeft.GetComponentInChildren <CNJoystick>(); _joystickLeftAPI.JoystickMovedEvent += _joystickAPI_JoystickMovedEvent; _joystickLeftAPI.FingerLiftedEvent += _joystickAPI_FingerLiftedEvent; joystickLeft.SetActive(invertedControls); } if (joystickRight != null) { joystickRight.SetActive(true); _joystickRightAPI = joystickRight.GetComponentInChildren <CNJoystick>(); _joystickRightAPI.JoystickMovedEvent += _joystickAPI_JoystickMovedEvent; _joystickRightAPI.FingerLiftedEvent += _joystickAPI_FingerLiftedEvent; joystickRight.SetActive(!invertedControls); } _triggerButton = GetComponent <TriggerButton>(); if (_triggerButton != null) { _triggerButton.enabled = true; } else { Debug.LogError("No trigger button for iOS build!"); } } #endif }
internal static uint GetPumpIdFromHash(string resource, Part firstPart, Part lastPart, TypePump pumpType, TriggerButton trigger) { return(firstPart.flightID + lastPart.flightID + (uint)pumpType.GetHashCode() + (uint)trigger.GetHashCode() + (uint)resource.GetHashCode()); }
public void AddExtraOverlay(TriggerButton button, FocusedOverlayContainer container) { triggerButtons.Add(button); AddInternal(container); }
internal static uint GetPumpIdFromHash(string resource, Part firstPart, Part lastPart, TypePump pumpType, TriggerButton trigger) { return firstPart.flightID + lastPart.flightID + (uint) pumpType.GetHashCode() + (uint) trigger.GetHashCode() + (uint) resource.GetHashCode(); }