فهرست منبع

Merge pull request #874 from eightyeight/enable-gamepad-earlier

Enable gamepad input when the startup GUI wakes
Daniel Buckmaster 11 سال پیش
والد
کامیت
644225db92
2فایلهای تغییر یافته به همراه12 افزوده شده و 0 حذف شده
  1. 6 0
      Templates/Empty/game/scripts/gui/startupGui.cs
  2. 6 0
      Templates/Full/game/scripts/gui/startupGui.cs

+ 6 - 0
Templates/Empty/game/scripts/gui/startupGui.cs

@@ -45,6 +45,12 @@ function loadStartup()
    //SFXPlayOnce(AudioGui, "art/sound/gui/startup");//SFXPlay(startsnd);
 }
 
+function StartupGui::onWake(%this)
+{
+   $enableDirectInput = "1";
+   activateDirectInput();
+}
+
 function StartupGui::click(%this)
 {
    %this.done = true;

+ 6 - 0
Templates/Full/game/scripts/gui/startupGui.cs

@@ -45,6 +45,12 @@ function loadStartup()
    //SFXPlayOnce(AudioGui, "art/sound/gui/startup");//SFXPlay(startsnd);
 }
 
+function StartupGui::onWake(%this)
+{
+   $enableDirectInput = "1";
+   activateDirectInput();
+}
+
 function StartupGui::click(%this)
 {
    %this.done = true;