project reality header
Go Back   Project Reality Forums > PR:BF2 Mod Forums > PR:BF2 Bugs
PR Time:
Register Forum RulesDeveloper Blogs Project Reality Members List Search Today's Posts Mark Forums Read
PR:BF2 Bugs If you find a bug within Project Reality (including PRSP), please report it here.

Contact Support Team Frequently Asked Questions Register today!

Closed Thread
 
LinkBack Thread Tools Display Modes
Old 10-11-2009, 02:03 PM   #21
HTG
Default Re: Project Reality + Battlefield 2 on Steam

Encountering the same problem as described in the initial post.


When launching the pr.exe the only relevant processes displayed in my task manager is the "BF2.exe", steam .exe is running anyway. Somehow there isn't a pr.exe displayed.

the log reads:

Quote:
C:\Program Files\Steam\SteamApps\common\battlefield 2
PR command line args sent to BF2: +modPath mods/pr +menu 1


Deleting news ticker directory: Deleted C:\Users\HTG\Documents/Battlefield 2/LogoCache/www.gloryhoundz.com

Error in MovingSplashScreen: --> System.IO.FileNotFoundException: Die Datei "C:\Program Files\Steam\SteamApps\common\battlefield 2\00000000.256" konnte nicht gefunden werden.
Dateiname: "C:\Program Files\Steam\SteamApps\common\battlefield 2\00000000.256"
bei System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
bei System.IO.File.InternalCopy(String sourceFileName, String destFileName, Boolean overwrite)
bei System.IO.FileInfo.CopyTo(String destFileName, Boolean overwrite)
bei System.IO.FileInfo.CopyTo(String destFileName)
bei FileMover.CopySplashScreen()
bei Launcher.Run(String[] args)

Copy PR Splash screen 00000000.256 to main BF2 directory

Launching BF2
BF2 Exiting

PR Splash screen stored at C:\Program Files\Steam\SteamApps\common\battlefield 2/mods/pr/00000000.256 , moved copy deleted

Error in ReturningPRSplashScreen: --> System.NullReferenceException: Der Objektverweis wurde nicht auf eine Objektinstanz festgelegt.
bei System.IO.FileInfo.CopyTo(String destFileName, Boolean overwrite)
bei System.IO.FileInfo.CopyTo(String destFileName)
bei FileMover.ReturnSplashScreen()
bei Launcher.Run(String[] args)

gloryhoundz.com directory not found, deletion confirmed

Hope that helps!
Cheers
HTG is offline
Old 10-12-2009, 12:09 PM   #22
HTG
Default Re: Project Reality + Battlefield 2 on Steam

I just realized that if you create a shortcut for BF2 on your desktop via steam the two command lines read like that:

target:
"C:\Program Files\Steam\Steam.exe" -applaunch 24860
sart in:
"C:\Program Files\Steam"

any relevance?
HTG is offline
Old 10-12-2009, 04:16 PM   #23
AMT

AMT's Avatar
Default Re: Project Reality + Battlefield 2 on Steam

This is what happens for me:

pr.exe starts.
pr.exe closes.
bf2.exe starts.
You try to login and you get the "please launch via pr.exe" error.
bf2.exe closes.

A signature would go here if I had one.
AMT is offline
Old 10-12-2009, 09:17 PM   #24
chilean

chilean's Avatar
Default Re: Project Reality + Battlefield 2 on Steam

Steam sucks i really dont like it , Lags your comp, at least me.
I only use it for America Army 3
chilean is offline
Old 10-13-2009, 12:04 AM   #25
VBNight
Exclamation Re: Project Reality + Battlefield 2 on Steam

I have built a workaround to allow Steam players to get Project Reality to launch correctly. The problem is BF2.exe from Steam quits when you 1st launch it to perform some sort of Steam authentication. Steam relaunches BF2 after the authentication. This script launches PR.exe, waits for it to close when BF2 closes, then waits for BF2 to be restarted, then relaunches PR.exe so it is running with BF2. This has the side effect of PR.exe starting BF2 again which try to start but it will exit because the existing BF2 process is running.

The PR developers should be able to update the PR.exe to detect steam and wait for BF2 to relaunch instead of exiting but this will let you run the game until they do.

Please post any questions or problems here.



AUTOHOTKEY REQUIRED - FREE

You will need to have Autohotkey installed on your system to use this script.

Download Autohotkey: http://www.autohotkey.com

AUTOHOTKEY REQUIRED - FREE




To Use Script:



Copy & Paste Method
  • Paste the following code into a blank notepad.
  • Save the text file on your desktop as "LaunchPR.ahk"
  • Double click LaunchPR.ahk to start Project Reality.

Download Method
  • Download attached LaunchPR.txt file.
  • Open file in notepad and verify text matches script above. (Optional)
  • Rename file to LaunchPR.ahk
  • Double click LaunchPR.ahk to start Project Reality.

Project Reality Launcher - Steam Helper
Code:
; Project Reality Launcher - Steam Helper
;
; This workaround helps launch Project Reality for users who purchased BF2 on Steam.
;
; Run this script to start Project Reality
;
; Launches PR.exe and waits for it to exit when BF2 performs Steam authentication.
; Relaunches PR.exe after Steam restarts BF2.exe after authentication.
;
; WARNING: The 2nd launch of PR.exe attempts to start BF2 again which will try start then quit.

#NoTrayIcon 
#SingleInstance force
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.

; Get Path To Project Reality PR.EXE
EnvGet ProgramFilesX86, ProgramFiles(x86)
PREXE := ProgramFilesX86 . "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"
BF2 := ProgramFilesX86 . "\Steam\steamapps\common\battlefield 2\"

; Verify Path Correct
IfNotExist %PREXE%
{
	EnvGet ProgramFilesFolder, ProgramFiles
	PREXE := ProgramFilesFolder . "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"

	IfNotExist %PREXE%
	{
		Msgbox PR.EXE (%PREXE%) NOT FOUND, PROJECT REALITY LAUNCHER FAILED
		ExitApp 1
	}
}

; Launch PR, Wait For It To Exit
RunWait, %PREXE%, %BF2%, UseErrorLevel

; Wait For BF2 Relaunch (20 Sec Timeout)
Process, Wait, BF2.exe, 20

; Check Timeout Error
if (ErrorLevel == 0)
{
	Msgbox TIMEOUT WAITING FOR BF2 RELAUNCH, PROJECT REALITY LAUNCHER FAILED
	ExitApp
}

; Relaunch PR.EXE Again
Run, %PREXE%, %BF2%, UseErrorLevel

; Exit (Finished)
ExitApp 0
Please post any questions or problems here.
Attached Files
File Type: txt LaunchPR.txt (1.6 KB, 529 views)
VBNight is offline
Last edited by VBNight; 10-13-2009 at 03:11 PM.. Reason: Update Script For 32Bit
Old 10-13-2009, 03:05 AM   #26
HTG
Default Re: Project Reality + Battlefield 2 on Steam

Excellent!!
It seems it works perfect.
I currently don't have the time to actually play as I have to work, however the error does not occur and I can access the server list etc.!
I will give more feedback this evening!
Many thanks....
HTG is offline
Old 10-13-2009, 05:23 AM   #27
Andrea h2o
Default Re: Project Reality + Battlefield 2 on Steam

doesn't work for me.. with autohotkey i got this error

Andrea h2o is offline
Old 10-13-2009, 06:08 AM   #28
R3M
Default Re: Project Reality + Battlefield 2 on Steam

@VBNight

Great that did the trick for me, thanks.

@Andrea h2o

I had the same problem like you, because my game is not installed in the ProgramFiles folder. Just edit this script and remove/change:

Quote:
PREXE := ProgramFilesX86 . "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"
BF2 := ProgramFilesX86 . "\Steam\steamapps\common\battlefield 2\"
to

Quote:
PREXE := "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"
BF2 := "\Steam\steamapps\common\battlefield 2\"
and

Quote:
; Verify Path Correct
IfNotExist %PREXE%
{
EnvGet ProgramFiles, ProgramFiles
PREXE := ProgramFiles . "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"

IfNotExist %PREXE%
{
Msgbox PR.EXE (%PREXE%) NOT FOUND, PROJECT REALITY LAUNCHER FAILED
ExitApp 1
}
}
to

Quote:
; Verify Path Correct
IfNotExist %PREXE%
{
PREXE := "\Steam\steamapps\common\battlefield 2\mods\pr\pr.exe"

IfNotExist %PREXE%
{
Msgbox PR.EXE (%PREXE%) NOT FOUND, PROJECT REALITY LAUNCHER FAILED
ExitApp 1
}
}
R3M is offline
Old 10-13-2009, 08:48 AM   #29
PLODDITHANLEY
Supporting Member
Default Re: Project Reality + Battlefield 2 on Steam

I hate DL'ed games - disc or nothing for me (when a disc exists not in the case or PR). Seems to bring extra problems.
PLODDITHANLEY is offline
Old 10-13-2009, 02:55 PM   #30
Andrea h2o
Default Re: Project Reality + Battlefield 2 on Steam

mmmm i edited but doesn't work...

C:\Program Files\Steam\steamapps\common\battlefield 2\mods\pr
C:\Program Files\Steam\steamapps\common\battlefield 2

here where are located my files, hope to get some help :P

edit: it's work now something was wrong on editing :P
Andrea h2o is offline
Closed Thread


Tags
battlefield, project, reality, steam
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 06:16 PM.


Powered by: vBulletin. ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO.
All Content Copyright ©2004 - 2012, Project Reality.