How to run BF2 itself as non-admin for Steam Controller

Help and support regarding PR:BF2 installation and in-game issues
Post Reply
Michael Z Freeman
Posts: 240
Joined: 2009-03-27 18:45

How to run BF2 itself as non-admin for Steam Controller

Post by Michael Z Freeman »

Hi,

The Steam Controller behaves badly with elevated (admin) windows.

I already worked out how to start the launcher as non-elevated (not admin) ...

Code: Select all

Set ApplicationPath="C:\Installations\Project Reality BF2\mods\pr\bin\PRLauncher.exe"
cmd /min /C "set __COMPAT_LAYER=RUNASINVOKER && start "" %ApplicationPath%"
However this gives ...

Image

I can understand the launcher having to run as admin but I don't need the main game to be admin otherwise Steam Controller won't work properly.

How do I get the launcher to start the Battlefield 2/PR executable normally ? I looked at Autohotkey which has a "runas" command but the help file says that if a UAC elevated process starts Autohotkey then it makes no difference. The only other way might be if I strip the main game process of its privileges somehow once its running but I can't see a way of doing this.

BTW, I'd rather not run Steam as admin unless its absolutely necessary.

Anyone ?
Image
User avatar
Mats391
PR:BF2 Lead Developer
Posts: 7636
Joined: 2010-08-06 18:06

Re: How to run BF2 itself as non-admin for Steam Controller

Post by Mats391 »

You cant do this on your end. We would have to change the Launcher for this and it would require redoing lots of the process interaction. As such this will not be done soon.
Even if prbf2.exe was running non elevated, you would still probably need to run your controller as elevated to have Launcher recognize the buttons as well. Without that things like BUIS switching wont work.
Image

Mineral: TIL that Wire-guided missiles actually use wire
Michael Z Freeman
Posts: 240
Joined: 2009-03-27 18:45

Re: How to run BF2 itself as non-admin for Steam Controller

Post by Michael Z Freeman »

Mats391 wrote:You cant do this on your end. We would have to change the Launcher for this and it would require redoing lots of the process interaction. As such this will not be done soon.
Even if prbf2.exe was running non elevated, you would still probably need to run your controller as elevated to have Launcher recognize the buttons as well. Without that things like BUIS switching wont work.
OK, cheers. So does BUIS switching use some function that needs to be admin ? AFAIK it just needs the usual "C" camera control.

SC works fine in the launcher itself. It goes into so called "lizard" mode in an elevated (admin) window when Steam has not been started as admin. In this mode normal mouse and keyboard commands are output not gamepad controls.

I just tested ruuning PR from Steam as admin and everything works great. Apparently BF2 does recognise joystick and gamepad controls but I stuck with mouse and keyboard controls definable for the SC. After all this is what it was designed to do. However no rumble on weapon fire (feels great in The Division 2 for example). For the moment I'll make a batch script that starts Steam as admin for PR then closes Steam and restarts it normally when PR exits.

So can you add this to some list somewhere Mats ? Or should I post in Suggestions ?
Image
AlonTavor
PR:BF2 Developer
Posts: 2991
Joined: 2009-08-10 18:58

Re: How to run BF2 itself as non-admin for Steam Controller

Post by AlonTavor »

Michael Z Freeman wrote:OK, cheers. So does BUIS switching use some function that needs to be admin ? AFAIK it just needs the usual "C" camera control.
Launcher intercepts it
SemlerPDX
Posts: 530
Joined: 2011-01-16 21:49
Contact:

Re: How to run BF2 itself as non-admin for Steam Controller

Post by SemlerPDX »

One possible workaround might be to use vJoy and UJR (Universal Joystick Remapper).

I gotta do crazy things like that just to get Kerbal Space Program to recognize the xbone controller that came with my Oculus. It takes some confoobling, but you can get any control recognized by most any game this way.

First you create a virtual joytick with all the same controls as your actual controller, then you use UJR to map the real one to the virtual one. Then, in game, you set everything to use this virtual joystick since it can be configured to be 'visible' to a game when other controllers cannot.

TBF, not sure if this works for PR, but it's worth a try for sure.

http://vjoystick.sourceforge.net/site/
http://vjoystick.sourceforge.net/site/index.php/81-news/93-ujr-universal-joystick-remapper-using-vjoy
Michael Z Freeman
Posts: 240
Joined: 2009-03-27 18:45

Re: How to run BF2 itself as non-admin for Steam Controller

Post by Michael Z Freeman »

AlonTavor wrote:Launcher intercepts it
So the launcher is elevated for that, I'm not sure I understand why the main game executable has to be as well, but I don't claim to understand the PR magic going on in the background.
SemlerPDX wrote:One possible workaround might be to use vJoy and UJR (Universal Joystick Remapper).
Thanks but that would lose all the Steam config magic for the Steam Controller which comes up in the steam overlay.
Image
Post Reply

Return to “PR:BF2 Support”