SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > General > General Topics > PC Hardware/Software forum
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 05-04-17, 04:20 PM   #1
BarracudaUAK
Captain
 
Join Date: Apr 2016
Posts: 520
Downloads: 33
Uploads: 0


Default

I've never used Crossover (which adds to wine), however, usually in WINE, you just add the command-line parameters as you would in a Windows shortcut (or dos).


For example, lets say I want to start SH3, which runs in WINE without any issue I would type:

wine sh3

to use an argument you just add it,

wine sh3 -arguments -go -here -like -this

Adding the arguments as per the instructions from the program.

Now for Silent 3ditor, I have to have dotnet 2.0 and dx9 installed into a 32bit wine prefix, called ".wine32". So to make S3D run I would type it like this:

env WINEPREFIX=~/.wine32 wine s3d -arguments -go -here


The "~/.wine32": "~" is the users home/username directory. the ".wine32" is the wine prefix directory. So "~/.wine32" just tells WHERE the "env" (environment) is located.

default "wine" should be ".wine".

I really need to work on the WINE thread I started......

Let me know if I need to clean this up!

EDIT: As far as resolutions go, just set your game to the desktop resolution and you'll be good to go.
I remember reading somewhere that WINE used to reset your screen resolution when the game exited, but there have been several changes to "X" (which draws your desktop) so an older command (that you could put in a shortcut) doesn't work reliably anymore.
Plus Gnome has switched to Wayland. And Ubuntu was working on Mir.
Both "Wayland" and "Mir" are replacements for "X".
I can get into that in detail in another thread if you would like me to elaborate, it is off topic.


Barracuda

Last edited by BarracudaUAK; 05-04-17 at 04:44 PM.
BarracudaUAK is offline   Reply With Quote
Old 05-05-17, 08:16 AM   #2
Reece
CINC Pacific Fleet
 
Reece's Avatar
 
Join Date: Sep 2003
Location: Down Under
Posts: 34,719
Downloads: 171
Uploads: 0
Default

The game doesn't cover the desktop resolution (1920x1080), the games max size is 1280x1024.
The desktop icon for the game has no place for parameters and only points to a file called farcry2.lnk that contains whatis shown in the first post. The actual game exe file is farcry2.exe but nothing concerned with the desktop icon points to that exe file.
__________________

Sub captains go down with their ship!
Reece is online   Reply With Quote
Old 05-07-17, 12:56 AM   #3
Reece
CINC Pacific Fleet
 
Reece's Avatar
 
Join Date: Sep 2003
Location: Down Under
Posts: 34,719
Downloads: 171
Uploads: 0
Default

Did you get a chance to try it out Steve? I cannot find anywhere to place the parameters.
__________________

Sub captains go down with their ship!
Reece is online   Reply With Quote
Old 05-07-17, 03:27 AM   #4
BarracudaUAK
Captain
 
Join Date: Apr 2016
Posts: 520
Downloads: 33
Uploads: 0


Default

Quote:
#!/bin/sh
exec "/opt/cxoffice/bin/wine" --bottle "Far_Cry_2" --check --wait-children --start "C:/users/Public/Desktop/Far Cry® 2.lnk" "$@"
It is referencing a ".lnk" file, in "C:/users/Public/Desktop/..." which means that it is most likely referencing the "Windows" link in the WINE directory, which -as far as WINE is concerned- is drive "C:".


To give you an example, my primary WINE directory as viewed in WINEcfg:

drive C: is viewed as "../drive_c".

If I go into my "/home/[login-name]/.wine" directory, I see 2 sub-directories:

"dosdevices" and "drive_c"

if I go to the directories specified in your link I quoted above on my PC (C:\users/Public\Desktop...", I have:

Steam.lnk
(and a few others)

That is most likely where you would need to edit the parameters.

Now you COULD (#1) add a shortcut to your Ubuntu desktop and edit it to launch Far Cry that way (basically a "shortcut" of what you would type into the terminal, not a "Linux shortcut to the Windows .lnk file")

I did find this if you want to (#2) try editing the "Windows .lnk" file in your WINE

https://askubuntu.com/questions/4336...e-wine-desktop

IF you want to add a Linux shortcut (#1 above) this is a "generic" shortcut based one of mine. I did try building a shortcut for SH3 "from scratch" using this one, and it worked.

You just need to make sure you have your directories in the shortcut correctly (capitalization!) and it should work. RR should be able to clarify any Ubuntu specific tweaks needed.

You should be able to right click the desktop and select "create shortcut" (or something similar). Then just edit the fields in the box that opens..

On the "Command" line put:
Quote:
env WINEPREFIX="/home/[login-name]/.wine" /usr/bin/wine C:\\windows\\command\\start.exe [game].exe
On the "Work Path" line:
Quote:
~/path/to/game/folder/
I'm still getting my System back up to 100%, I'm trying to get my VM software installed so I can get the Ubuntu VM I've still got here working again so I won't have to "translate" across distros, I can just "do it" and let you know.

Barracuda
BarracudaUAK is offline   Reply With Quote
Old 05-08-17, 01:20 AM   #5
Reece
CINC Pacific Fleet
 
Reece's Avatar
 
Join Date: Sep 2003
Location: Down Under
Posts: 34,719
Downloads: 171
Uploads: 0
Default

If only things were that easy in Ubuntu 16.04!!
There is no way to create a shortcut from the desktop of from the file, checking online I get this:
https://askubuntu.com/questions/8543...sktop-shortcut
I'm not sure what the best method is.

Since there is a shortcut on the desktop already I could just copy that and edit it. That seemed to work, the editable boxes are:
Name Far Cry 2
Description
Command (I have entered the path and exe here)
Comment
There is no place for 'work path'??
There is also a tab for Permissions that has the 'Program is executable" ticked.
Where would I place the parameters, I assume at the end of the command?
I haven't tried it yet, there is no place to say run windowed.
__________________

Sub captains go down with their ship!

Last edited by Reece; 05-08-17 at 01:52 AM.
Reece is online   Reply With Quote
Old 05-08-17, 10:50 AM   #6
Rockin Robbins
Navy Seal
 
Join Date: Mar 2007
Location: DeLand, FL
Posts: 8,900
Downloads: 135
Uploads: 52


Default

Okay, all your answers should be at https://appdb.winehq.org/objectManag...ation&iId=8522

The maintainer there has Far Cry 2 working perfectly at a platinum level.
Rockin Robbins is offline   Reply With Quote
Old 05-08-17, 04:21 PM   #7
BarracudaUAK
Captain
 
Join Date: Apr 2016
Posts: 520
Downloads: 33
Uploads: 0


Default

Quote:
Originally Posted by Reece View Post
If only things were that easy in Ubuntu 16.04!!
There is no way to create a shortcut from the desktop of from the file, checking online I get this:
https://askubuntu.com/questions/8543...sktop-shortcut
I'm not sure what the best method is.

Since there is a shortcut on the desktop already I could just copy that and edit it. That seemed to work, the editable boxes are:
Name Far Cry 2
Description
Command (I have entered the path and exe here)
Comment
There is no place for 'work path'??
There is also a tab for Permissions that has the 'Program is executable" ticked.
Where would I place the parameters, I assume at the end of the command?
I haven't tried it yet, there is no place to say run windowed.

Yes, place any command line parameters/arguments after the .exe
Sorry I forgot to mention that!

"Work Path" is you changing to the directory before you enter the command to start the game.
Example:
Quote:
cd windows
Quote:
notepad.exe
Entering everything in the "Command" field is same as being at the "C:\" prompt and typing
Quote:
C:\windows\notepad.exe
You may have to set Windowed mode in the game...

The main differences in the way the shortcut works is due to the differences in the Desktops, some have more "options" than others. I have ignored the "Work Path" in KDE and had the program run fine.


One last thing as I forgot which one you have, Which version of WINE is installed?

wine --version

or starting Winecfg from the menu, should tell you.

Barracuda
BarracudaUAK is offline   Reply With Quote
Old 05-09-17, 02:15 AM   #8
Reece
CINC Pacific Fleet
 
Reece's Avatar
 
Join Date: Sep 2003
Location: Down Under
Posts: 34,719
Downloads: 171
Uploads: 0
Default

I have Wine version 2.7.

I tried to run the game using this shortcut: (some shortcut)

env WINEPREFIX="/home/Reece/.wine" /usr/bin/wine C:\\windows\\command\\start.exe /home/reece/.cxoffice/Far_Cry_2/drive_c/Program Files/Ubisoft/Far Cry 2/bin/farcry2.exe -GameProfile_SkipIntroMovies 1

I am not surprised it doesn't work!!!

Is start.exe supposed to be there?
__________________

Sub captains go down with their ship!

Last edited by Reece; 05-09-17 at 06:24 AM.
Reece is online   Reply With Quote
Reply

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

Forum Jump


All times are GMT -5. The time now is 07:16 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 1995- 2025 Subsim®
"Subsim" is a registered trademark, all rights reserved.