War2.ru Slogan
News: All hail our wise & benevolent admins!


Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
Welcome to the forums! We're glad to have you here! :) You can register your account here, then feel free to introduce yourself in the Server.War2.ru board & let us know who you are on the server.

War2 over Linux 3022  48

Axe Thrower Posts: 283 Karma: +18/-0 ****

Igognito

  • Axe Thrower
  • ****
  • *
  • Posts: 283
    • View Profile
War2 over Linux
« on: May 12, 2016, 09:29:37 PM »
Hi all,

for better or worst I'm using Linux. Currently I run war2 using Wine but I would like to see a native version...

Why? Because I have several problems:
First of all, if I play only single player the game is ok. I also assume if go non enhanced multiplayer it should be fine.
The moment I go to Enhanced multiplayer all hell breaks loose!
a) The graphics of battlenet enviroment are non visible
b) If I play full screen I loose the keyboard focus
c) I cant host games because of a port issue (perhaps this can be bypassed)
d) Mouse even in the slowest speed is toooo fast for my taste (this perhaps can be fixed with a linux system command)

Anyhow, I would be willing to help in order to make a linux version! Or create an extensive guide of how to make War2 play properly under linux.

Thus I'm starting this post...
First question, do you have the source code? if so, perhaps we could try to compile under linux! That would be the ideal solution.
Second question, anyone else uses linux? Do the same issues arise?
Third question, who is willing to help me for this!

Thats for now!
ps: Thank you for the great job of reviving War2! You reminded me the great times I had when I was younger!
ps2: Slowly, I will do my best to get involved with the development.
Ogre Mage Posts: 2199 Karma: +44/-2 retired, be in music section ********

easycompany

  • Ogre Mage
  • ********
  • Posts: 2199
  • retired, be in music section
    • View Profile
Re: War2 over Linux
« Reply #1 on: May 12, 2016, 10:31:03 PM »
i used fedora but i vm'ed a win2000 custom i had. idk man someone just now got it to play on win10 lol.
you would def want to look at sc1 progress at its the same as war2.

there something called playonlinux a custom wine.

ive used aqrits ddraw to fix broodwar on win7.

oracle vm make ya a custom windows of your choice xp and under ull be ok.

something like that if noone comes along :P gone back to jam and drink!
(ง︡'-'︠)ง "Bitchin!" ®©℗™ Dragon Posts: 6061 Karma: +135/-70 "It's going to be Legen-(wait for it......)-DARY!" **********

EviL~Ryu

  • (ง︡'-'︠)ง "Bitchin!" ®©℗™
  • Dragon
  • **********
  • *
  • Posts: 6061
  • "It's going to be Legen-(wait for it......)-DARY!"
    • View Profile
    • Clan EviL Official Page
Re: War2 over Linux
« Reply #2 on: May 13, 2016, 12:06:52 AM »
Didn't like wine and war2 when I tried it on Mac, online play was impossible because of lagged graphics.


Sent from my Motorola DynaTAC 8000X using Tapatalk
Administrator Ogre Posts: 1019 Karma: +98/-9 *****

iL

  • Administrator
  • Ogre
  • *****
  • *
  • Posts: 1019
    • View Profile
*

iL

Re: War2 over Linux
« Reply #3 on: May 13, 2016, 11:15:44 AM »
Hi, Igognito!

a) The graphics of battlenet enviroment are non visible
b) If I play full screen I loose the keyboard focus

Try graphics fix by aqrit. I never tried it on linux because i have no working desktop on linux, but that's quite possible it works fine.
http://forum.war2.ru/index.php/topic,1790.0.html
Try test4 (should be slow, but good with graphics). Or minimal (should be faster, but could cause crash or w/e).
Your report about ddraw fix under wine would be highly appreciated.

c) I cant host games because of a port issue (perhaps this can be bypassed)

You should forward your 6112 tcp/udp ports from your gateway to your wine to let war2 receive incoming packets incoming to your internet connection. There's no guides about that, i hope you're quite experienced linux-user to do that yourself...

d) Mouse even in the slowest speed is toooo fast for my taste (this perhaps can be fixed with a linux system command)

No ideas, should be configured somewhere in wine i hope...

Anyhow, I would be willing to help in order to make a linux version! Or create an extensive guide of how to make War2 play properly under linux.

Creating an extensive guide would be great!
If you resolve that problems with linux and make guide, we would be happy to publish it on en.war2.ru and here on the forum also.

First question, do you have the source code?

Nobody has the source code for war2. That is a very big problem, but here's our world...
Another community still tries to release wargus (opensource clone for war2), but wargus is kinda kids' toy comparing with war2.
And virtualization (i mean wine) reached sufficient progress for last years.
I think the future for war2 over linux is wine.

Second question, anyone else uses linux? Do the same issues arise?

One or two persons tried war2 under wine several years ago with similar problems (with graphics). Now we have aqrit's ddraw wrapper developed for war2 specially. I hope it should resolve the problem. At least ddraw is open-source, so can be updated for wine. I think it should be really possible to run war2 on linux.

Third question, who is willing to help me for this!

I feel war2 on linux would be important project. I have no time for such experiments, but i can try to test/help your with your project.

ps: Thank you for the great job of reviving War2! You reminded me the great times I had when I was younger!
ps2: Slowly, I will do my best to get involved with the development.

Well, let that be your project for war2 on linux. You lead it, i just try to help with my experience as i can.
ps: Which linux distribution/wm would you recommend me to install for tests? My test hardware is about 5-10 years old (amd core 2 duo, 2x3000Mhz).
Axe Thrower Posts: 283 Karma: +18/-0 ****

Igognito

  • Axe Thrower
  • ****
  • *
  • Posts: 283
    • View Profile
Re: War2 over Linux
« Reply #4 on: May 13, 2016, 05:22:25 PM »
That is great!
Thank you guys for the thumbs up, quick responses and info.

This weekend I'm busy with finishing a paper but next week I will devote sometime to get you some more feedback!

Quest Accepted: I will collect a guide with all  the details of how to make it work perfectly over linux.

I use Ubuntu, but by my experience if you get to work it on one the transition to the next linux is easy. Thus after I fix the problems on Ubuntu I will be happy to have requests for other distributions.
The main issue is fixing that damn keyboard focus that doesn't allow me to play on full screen.

Cheerios!
Ogre Mage Posts: 2199 Karma: +44/-2 retired, be in music section ********

easycompany

  • Ogre Mage
  • ********
  • Posts: 2199
  • retired, be in music section
    • View Profile
Re: War2 over Linux
« Reply #5 on: May 13, 2016, 05:25:24 PM »
Great man ! I have a reactos I was gonna try and see if I could do like a .pal to change war2s colors so its atleast more playable. react cant run aqrits.idk who would use it anyhow.
Ogre Mage Posts: 2317 Karma: +72/-1 ********

tupac

  • Ogre Mage
  • ********
  • *
  • Posts: 2317
    • View Profile
Re: War2 over Linux
« Reply #6 on: May 14, 2016, 11:14:11 AM »
You can disable the firewall:

sudo ufw disable
sudo ufw enable

You could also use iptables to open port 6112 on your interface:

"Ifconfig" to see your interface. (eth0)

iptables -A INPUT -i eth0 -p all –dport 6112 -j ACCEPT
iptables -A OUTPUT -i eth0 -p all –dport 6112 -j ACCEPT

I think easycompany said the new color fix was still broken. But would be good to hear your results.
Ogre Mage Posts: 2199 Karma: +44/-2 retired, be in music section ********

easycompany

  • Ogre Mage
  • ********
  • Posts: 2199
  • retired, be in music section
    • View Profile
Re: War2 over Linux
« Reply #7 on: May 14, 2016, 12:05:31 PM »
no lol to ReactOs, ya i did type that drinking :P. well gone from this thread.. glhf!
Axe Thrower Posts: 283 Karma: +18/-0 ****

Igognito

  • Axe Thrower
  • ****
  • *
  • Posts: 283
    • View Profile
Re: War2 over Linux
« Reply #8 on: June 02, 2016, 12:44:20 PM »
Hi all again,

I have been very busy lately so I haven't yet tried all suggestions. But I did try some stuff:

i) graphics fix by aqrit
this didn't work :-( It also made the game slower to launch!
ii) Wine doesn't really have directx but uses a lame emulator. I tried to install directx to wine but it got really complicated. In other words even if this would solve the problem it does not worth the effort.

I also tried with Starcraft and there I managed to get 1 game to run properly over Battle.net but I never managed to get a 2nd :-(
Thus the problem is for both games and it is similar!

I tried also some other small stuff with no success. (Wine Setting and Wine window management)

I'm still on it and I will keep you informed.

ps: For now I have not tried anything about the ports as the  EF_Host bot solves the problem ;-)
Ogre Mage Posts: 2317 Karma: +72/-1 ********

tupac

  • Ogre Mage
  • ********
  • *
  • Posts: 2317
    • View Profile
Re: War2 over Linux
« Reply #9 on: June 02, 2016, 01:45:15 PM »
Hi all again,

I have been very busy lately so I haven't yet tried all suggestions. But I did try some stuff:

i) graphics fix by aqrit
this didn't work :-( It also made the game slower to launch!
ii) Wine doesn't really have directx but uses a lame emulator. I tried to install directx to wine but it got really complicated. In other words even if this would solve the problem it does not worth the effort.

I also tried with Starcraft and there I managed to get 1 game to run properly over Battle.net but I never managed to get a 2nd :-(
Thus the problem is for both games and it is similar!

I tried also some other small stuff with no success. (Wine Setting and Wine window management)

I'm still on it and I will keep you informed.

ps: For now I have not tried anything about the ports as the  EF_Host bot solves the problem ;-)
There are many versions for the newest color fix. Was the battle.net interface still messed up? I'll will try to install war2 on a Debian system.
Ogre Mage Posts: 2199 Karma: +44/-2 retired, be in music section ********

easycompany

  • Ogre Mage
  • ********
  • Posts: 2199
  • retired, be in music section
    • View Profile
Re: War2 over Linux
« Reply #10 on: June 03, 2016, 02:28:49 PM »
Axe Thrower Posts: 283 Karma: +18/-0 ****

Igognito

  • Axe Thrower
  • ****
  • *
  • Posts: 283
    • View Profile
Re: War2 over Linux
« Reply #11 on: June 09, 2016, 01:30:33 PM »
I have already tried that :-(
Wine and Play on Linux function fine as long as you do not connect to battle.net!
I can have perfect LAN games or perfect single player games. The moment I go to Battle.net the problems start.

I'm sure I will find a solution eventually, especially now that I found out that starcraft has the same problem. I'm sure there is a guide to fix it :-) for starcraft as it is more popular :-(

Cheers
Ogre Mage Posts: 2317 Karma: +72/-1 ********

tupac

  • Ogre Mage
  • ********
  • *
  • Posts: 2317
    • View Profile
Re: War2 over Linux
« Reply #12 on: June 09, 2016, 04:12:31 PM »
I have already tried that :-(
Wine and Play on Linux function fine as long as you do not connect to battle.net!
I can have perfect LAN games or perfect single player games. The moment I go to Battle.net the problems start.

I'm sure I will find a solution eventually, especially now that I found out that starcraft has the same problem. I'm sure there is a guide to fix it :-) for starcraft as it is more popular :-(

Cheers
You can follow the wine community and see its been the same way for years now. Maybe one day someone will fix it.
Axe Thrower Posts: 283 Karma: +18/-0 ****

Igognito

  • Axe Thrower
  • ****
  • *
  • Posts: 283
    • View Profile
Re: War2 over Linux
« Reply #13 on: June 09, 2016, 07:10:57 PM »
Great News!!!!

I have solved the most important problem for now! (Indeed by searching for Starcraft!)

Keyboard focus: SOLVED
Solution is pretty complicated though:

Everywhere you need to replace: $USERNAME$ with your username :-P

First we need a shell command that will setup and execute war2:

war2.sh

xinput set-prop 10 "Device Enabled" 0 # This disables my touchpad because I'm on a laptop
xrandr -s 640x480 # This is important you will need to set the screen resolution to 640x480 (do not worry this is temporary only for this script)

# The following are needed for WINE
env WINEPREFIX="/home/$USERNAME$/.wine"
wine C:\\windows\\command\\start.exe /Unix /home/$USERNAME$/.wine/dosdevices/c:/users/Public/Start\ Menu/Programs/Warcraft\ 2\ Combat\ Edition/Activated\ War2Combat.lnk


STEP 2:

You need to add your user to the audio driver!

sudo adduser $USERNAME$ audio

and restart your pc

STEP 3:

Create a War2 Screen

open a terminal and type:
xinit -- :1

that will give you a new screen where we will run war2

now you execute your script!

This solution works for multiple games!
Ogre Mage Posts: 2199 Karma: +44/-2 retired, be in music section ********

easycompany

  • Ogre Mage
  • ********
  • Posts: 2199
  • retired, be in music section
    • View Profile
Re: War2 over Linux
« Reply #14 on: June 09, 2016, 07:31:20 PM »
gj! 8)