![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
|
Wine This is the place for questions about using Windows programs under Linux using Wine, including productivity software, games, and anything else. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
First Cup of Ubuntu
![]() Join Date: Jun 2008
Beans: 8
|
if any of you have ever tried running StarCraft on a widescreen display, you'll know what I'm talking about. Either you can run Starcraft in windowed mode, and be forced to squint at the 640x480 display, or you can try and play in fullscreen mode, without the bottom third of your screen.
Here I show the ordinary user how to play StarCraft the way it was meant to be played. The secret to having StarCraft play in fullscreen mode, is X. If you start StarCraft in a custom XServer with its own resolution, you can get it to display the full screen. Open /etc/X11/xorg.conf in your favorite editor, and add the follow lines: Code:
Section "ServerLayout"
Identifier "SCLayout"
Screen 0 "StarCraft Screen"
InputDevice "Keyboard0" "CoreKeyboard"
InputDevice "Mouse0" "CorePointer"
EndSection
Section "Screen"
Identifier "StarCraft Screen"
Device "Device0"
Monitor "StarCraft Monitor"
DefaultDepth 24
SubSection "Display"
Virtual 640 480
Depth 24
Modes "640x480@60" "1280x800@50"
EndSubSection
EndSection
Section "Monitor"
Identifier "StarCraft Monitor"
VendorName "Plug 'n' Play"
ModelName "Plug 'n' Play"
Gamma 1
ModeLine "640x480@60" 25.2 640 656 752 800 480 490 492 525 -hsync -vsync
EndSection
Next, we must change a line of /etc/X11/Xwrapper.config: change the line Code:
allowed_users=console Code:
allowed_users=anybody Next, create a text file called scstart. Paste the following in: Code:
#!/bin/sh X :1 -layout SCLayout -ac & XPID=$! sleep 2 DISPLAY=:1 wine $HOME/.wine/drive_c/\ Program/Files/Starcraft/StarCraft.exe -- /usr/bin/X :1 -layout SCLayout sleep 1 kill $XPID If you want to switch back to your desktop in the midst of a zerg rush, you can press Ctrl + Alt + F7. To switch back, press Ctrl + Alt + F8. This is a pretty basic launcher. You'll notice on glaring problem when using this, though. You can't change the volume. The program that handles you pushing the volume buttons is a part of Gnome, and we didn't launch that. Fortunately there is a way around the problem. install the xbindkeys package: Code:
sudo apt-get install xbindkeys Start by creating a default config file. Code:
xbindkeys --defaults > .scbind Now we have to determine what the key codes for the volume keys are. Gnome sometimes messes with the keycodes, especially for volume control, so to be extra safe, we are going to find our keycodes from a recovery console. Logout, change the session type to recovery console, and log back in. You will be presented with a console in the lower righthand corner. To type in it, your mouse must be over the terminal. Type in: Code:
xbindkeys -f $HOME/.scbind -mk Code:
Press combination of keys or/and click under the window.
You can use one of the two lines after "NoCommand"
in $HOME/.xbindkeysrc to bind a key.
--- Press "q" to stop. ---
"(Scheme function)"
m:0x0 + c:160
Code:
"amixer set Master toggle" (mute/unmute keycode) "amixer set Master 6+" (volume up keycode) "amixer set Master 6-" (volume down keycode) Now add the following line to scstart under "sleep 2": Code:
xbindkeys --display :1 -f $HOME/.scbind So long and thanks for all the fish! |
|
|
|
| Bookmarks |
| Tags |
| starcraft, wine |
| Thread Tools | |
| Display Modes | |
|
|