ValveSoftware / Proton

Compatibility tool for Steam Play based on Wine and additional components
Other
23.51k stars 1.03k forks source link

Age of Empires 2 (2013) (221380) #72

Open sandsmark opened 5 years ago

sandsmark commented 5 years ago

same issue as when people earlier tried to run aoe2hd with wine.

if you replace Launcher.exe with «AoK HD.exe» the game seems to launch and work perfectly.

KapiX commented 5 years ago

Launcher.exe requires mfc140u.dll to run. Dropping it in game directory fixes the issue.

dfduarte commented 5 years ago

Confirmed the "partial" solution using the mfc140u.dll. However, the following problem happens:

1- When running without the dll file, the games freezes (then closes afterwards) with no message 2- After copying the dll to the Age 2 dir, the whole install process starts, but the install crashes right after installing the DirectX seven, closing the "load screen" again. 3- When putting the AoK HD.exe in place of Launcher, I get a error regarding a image failing to load in the textures folder. The game crashes after that

My machine is:

Computer Information:
    Manufacturer:  Unknown
    Model:  Unknown
    Form Factor: Desktop
    No Touch Input Detected

Processor Information:
    CPU Vendor:  AuthenticAMD
    CPU Brand:  AMD Athlon(tm) II X2 270 Processor
    CPU Family:  0x10
    CPU Model:  0x6
    CPU Stepping:  0x3
    CPU Type:  0x0
    Speed:  3400 Mhz
    2 logical processors
    2 physical processors
    HyperThreading:  Unsupported
    FCMOV:  Supported
    SSE2:  Supported
    SSE3:  Supported
    SSSE3:  Unsupported
    SSE4a:  Supported
    SSE41:  Unsupported
    SSE42:  Unsupported
    AES:  Unsupported
    AVX:  Unsupported
    CMPXCHG16B:  Supported
    LAHF/SAHF:  Supported
    PrefetchW:  Unsupported

Operating System Version:
    Ubuntu 16.04.5 LTS (64 bit)
    Kernel Name:  Linux
    Kernel Version:  4.15.0-32-generic
    X Server Vendor:  The X.Org Foundation
    X Server Release:  11906000
    X Window Manager:  Compiz
    Steam Runtime Version:  steam-runtime-beta-release_2018-06-14

Video Card:
    Driver:  NVIDIA Corporation GeForce GTX 750 Ti/PCIe/SSE2
    Driver Version:  4.5.0 NVIDIA 384.130
    OpenGL Version: 4.5
    Desktop Color Depth: 24 bits per pixel
    Monitor Refresh Rate: 59 Hz
    VendorID:  0x10de
    DeviceID:  0x1380
    Revision Not Detected
    Number of Monitors:  1
    Number of Logical Video Cards:  1
    Primary Display Resolution:  1366 x 768
    Desktop Resolution: 1366 x 768
    Primary Display Size: 16.14" x 9.06" (18.50" diag)
                                            41.0cm x 23.0cm (47.0cm diag)
    Primary Bus: PCI Express 16x
    Primary VRAM: 2048 MB
    Supported MSAA Modes:  2x 4x 8x 16x 

Sound card:
    Audio device: Realtek ALC887-VD

Memory:
    RAM:  7975 Mb

Miscellaneous:
    UI Language:  English
    LANG:  en_US.UTF-8
    Total Hard Disk Space Available:  250461 Mb
    Largest Free Hard Disk Block:  40602 Mb
    VR Headset: None detected

Recent Failure Reports:
ryao commented 5 years ago

env WINEPREFIX=$HOME/.local/share/Steam/SteamApps/compatdata/221380/pfx/ WINEPATH=$HOME/.local/share/Steam/SteamApps/common/Proton\ 3.7/dist/bin/wine winetricks vcrun2015

Running this winetricks command enabled things to work, although it seems hackish. The launcher buttons are also missing text.

DrCox1911 commented 5 years ago

Works fine for me, only thing I did was renaming the "AoK HD.exe" to "Launcher.exe".

felisucoibi commented 5 years ago

This is a old knowm bug of aoe2 in wine (i was one of the bug trackers of this game in winehq.com) and yes just reanimg works. Go to the folder of the game and rename Launcer.exe to Launcher2.exe and Aoe 2.exe to Launcher.exe

BUT

There is also a bug with hdmi screen in laptop if using nvidia output, it just works perfect with intel card enabled using nvidia config, but if you run it in a laptop via hdmi with nvidia enabled it stucks.

And also there is a font flickering and a black background in writing areas problem easy to fix too.

In total are 4 BUGS, but you can play this game with the workarrounds.

legluondunet commented 5 years ago

Another bug for this game: cinematics do not play, could be related to issue #1464.

nwildner commented 5 years ago

Don't know if this adds more info to this issue but i had to replace Launcher.exe with AoK HD.exe and add the NoStartup launch parameter for the game to launch.

Didn't tested online gameplay but as far as i could get Single player modes are running great. yay! Edit: Ok, online game is working :)

Running on: Arch Linux(k4.18) + AMD FX9370 + Nvidia GTX 6050ti + Nvidia 396.54-2 driver version.

hogar1977 commented 5 years ago

@felisucoibi I also played this game via Crossover before and it worked really well, but after trying out this steam version (after renaming AoK HD.exe into Launcher.exe) I have a problem with elo - it reports that elo is out of bounds and it resets to 1600 after every game (regardless of winning or losing). Did you experience the same problem?

Also what is the workaround for black text on black background in writing areas so they become effectively invisible?

felisucoibi commented 5 years ago

Yes, same problem here... the elo reset to 1600, i didnt say anything because i dont use it and i forgot to report....

There is not workarround for the black background when writing... never has been by now.

hogar1977 commented 5 years ago

@felisucoibi

This is why I asked for workaround, I thought u were talking about that:

And also there is a font flickering and a black background in writing areas problem easy to fix too.

Cheers anyway, I hope someone will figure out the elo problem because now even my windows and Crossover installation is affected :-) Maybe I just have to reinstall everything there and it will go away, but I'm too lazy to do that...

kisak-valve commented 5 years ago

Age of Empires II: HD Edition - game works with issues

Issue transferred from https://github.com/ValveSoftware/Proton/issues/1285. @hogar1977 posted on 2018-09-06T18:27:58:

Hi there, the game works if 'AoK HD.exe' is renamed into 'Launcher.exe' and nostartup is added into launch options. Issue 1: ELO system is not behaving properly - the game 'thinks' that elo is 0:0 and reports it as out of bounds at selecting multiplayer and after every played multiplayer game it tries to add/subtract elo points to/from 0:0 values which still makes them out of bounds and elo finally gets reset to 1600 every time. The game is completely playable except for the ELO bug in multiplayer. I play this game regularly via Crossover and the elo bug is not present there - I presume because the Steam client itself is part of the wine 'bottle' and it is the windows version of Steam client that is also emulated. Since elo system is tightly interwoven with the Steam client, I guess that's where the problem lies...

Issue 2: In-game chat windows - text is black on black background, so during typing of a message it's not possible to see it. This particular bug is wine related I guess... It exists in my Crossover installation and now it's also present in the Steam for Linux via Proton variant. Haven't found any solution for it until now.

Other than this, the game runs smoothly with no crashes... For me it actually performs better than on my Windows 10 machine (there I experience at least one crash per session of gaming and is somehow slower...).

KapiX commented 5 years ago

I have also noticed that for some reason my achievements got reset. Only one awarded for finishing the tutorial is left, all I got in multiplayer are gone.

kforney commented 5 years ago

After swapping out Launcher.exe and replacing it with AoK HD.exe, the game runs perfectly on my system with the following issues:

ryad-eldajani commented 5 years ago

Replacing Launcher.exe with AoK HD.exe works for me.

I've played the first few tutorial games and it works like charm.

However, I noticed a problem when tabbing out of the game and back, the game keeps scrolling in one direction. Could only reverse this by restarting the game. It doesn't matter, whether I've set the game to window or full screen mode.

Tested on: Arch x64, GTX 765M @ 396.51, Proton 3.7-6 Beta.

hogar1977 commented 5 years ago

@kforney I think the ELO problem comes from the fact that game is installed in wine environment and steam client is not. Therefore the game cannot access Steam API in a proper way - the elo cannot be read nor written properly after the multiplayer match is done (game tries to assign elo to 0:0 values and it ends up being out of bounds again and reset to 1600:1600). I think the achievements issue is the same thing... I play this game over Crossover (commercial version of wine) and I never had this issue. But in Crossover, both the Steam client and the game are windows emulated versions and part of the same wine bottle, so I guess the game has no issues in accessing the Steam API properly.

@ryad-eldajani Can you try to play a few online multiplayer matches, just to confirm the ELO 1600:1600 issue? Also, regarding the tabbing issue... I had that happen to me from time to time when I played over Crossover, but rarely (as far as I know this happens in Windows too). Does it happen to you every time? Also I am not able to Alt TAB at all when playing via Steam for Linux + Proton, but I am using Gnome DE. What DE are you using on your Linux machine?

Other than these issues, the game is more stable for me in Linux then it is in Windows - almost never crashes, while in Windows 10 I experience game crash almost every time I play (1 time per session of gaming).

ryad-eldajani commented 5 years ago

@hogar1977 I noticed the tabbing issue appears, when scrolling the map using the arrow keys and afterwards tabbing out. If I scroll the map using the right click, cursor to window edge or click on mini map, it does not appear happen. I can confirm that I also have an ELO of 1600. I cannot say however whether this is correct or not since I've never played a ranked match before. I'm using Xfce 4.12.

Flaburgan commented 5 years ago

Hi everyone. Linux fan and AoE fan here. I play this game with Wine for years, first the original version, then the steam version installing steam with Wine. Everything works fine except for the black background of text.

So, I just installed AoE with Proton, I had to rename AoK to Launcher.exe (something I never did when installing the game AND steam under wine) and... BAM, all my achievements and my ELO score are lost :( I played a multiplayer game, and the error (score is 0:0) is still there. Now, I accessed steam from the website and can see my achievements definitely are lost. It's not that bad honestly but I mainly play online and see my ELO score to 1600 is very sad knowing how many games I won :p

Flaburgan commented 5 years ago

(Also, I found the trick of renaming AoK to Launcher on this video: https://www.youtube.com/watch?v=TF1wPFRF_FI if someone with a Google Account can comment there to warn everyone about loosing all progress and ELO score in the game, that would be nice. I would definitely not have done that if I knew)

hogar1977 commented 5 years ago

@Flaburgan I hope more linux aoe2 fans will decide to comment here, maybe we actually get someone assigned to deal with the issue. Because, the Steam client behaves better and more stable in this way then when it's emulated with wine... I also played this game via Crossover for a relatively long time, but if it would work with Steam for Linux it would be perfect. Before installing I read only about losing achievements, not elo. I guess if I knew about ELO loss as a certainty I would not have installed the game like this either. Other than the achievement and ELO loss the game could essentially be whitelisted...

hogar1977 commented 5 years ago

@kisak-valve hi there, I noticed you moved my discussion into this thread... Do you have any relation to the valve proton dev team? Or just trying to moderate the Issues forum? This game has basically only one minor issue that needs resolving before it can be whitelisted... Any hope someone gets assigned to look into it?

Flaburgan commented 5 years ago

@hogar1977 well in the last 24h AoE is the 49th game the most played over thousands of steam games. So it definitely is popular. I don't know how we can point that to valve's devs though.

hogar1977 commented 5 years ago

@Flaburgan as usual the devil lies in the details... It might be 49th most played game, but how many of those are Linux users :/ ? I'm afraid not that many :( I just hope someone sees my rant and decides to do something about it tho :)

kisak-valve commented 5 years ago

Hello @hogar1977, hi there, I noticed you moved my discussion into this thread... Do you have any relation to the valve proton dev team? No, I am not a Valve dev.

Or just trying to moderate the Issues forum? Yes, I am a moderator for Valve's Github issue trackers.

This game has basically only one minor issue that needs resolving before it can be whitelisted... Any hope someone gets assigned to look into it? The proton devs are actively listening to feedback and prioritizing what they consider most important, however, I will not single out any individual Proton dev or impose a priority system.

kforney commented 5 years ago

I went to collect a log file to try to see what was really happening, and noticed that my version of Proton was one too far back for the PROTON_LOG option to work. Updating Proton to the 3.7-6 Beta through Steam's options so I could get the log file had the side effect of resolving the issue. My achievements and ELO no longer reset every time I click "Multiplayer" in 3.7-6 Beta.

hogar1977 commented 5 years ago

@kforney @Flaburgan @kisak-valve @ryad-eldajani

I can confirm that using Proton beta version fixes the ELO and achievement issue!!! Oh man I'm so happy with this. Now, if someone only was able to figure out the black text on black background (and I believe this is strictly wine issue that exists since forever) that would be perfect :) But this thing alone makes this game able to be whitelisted in my opinion. I don't know their criteria, but this game is perfectly playable right now. Crossover wine AoE2 HD bottle bye bye...

Flaburgan commented 5 years ago

I can confirm after playing an online game that with proton 3.7.6beta the elo bug is gone. However, I still had to do the hack of renaming AoK to launcher

ryao commented 5 years ago

There is an option to bypass the launcher when starting Age of Mythology: Extended Edition. It would be nice if Valve added an option to bypass the launcher on Age of Empires II: HD Edition. The two are related.

kforney commented 5 years ago

Unfortunately, Valve has no control over that. That's an option that would have to be added by the developer...

sandsmark commented 5 years ago

so the problems with the launcher is that some functions from mfc140u.dll are not (fully) implemented in wine/proton? does anyone have a log indicating what is missing?

and the issue with input fields sounds like aoe2 is doing something weird with IME.

sandsmark commented 5 years ago

ok, never mind me, wine doesn't have any MFC implementation, so it will have to be shipped with the game.

edit; .. and it already installs the necessary runtime (so the dll is available in ~/.local/share/Steam/steamapps/compatdata/221380/pfx/drive_c/windows/system32/mfc140u.dll), but I guess wine needs to be told to look for the native version.

legluondunet commented 5 years ago

I just tested, if I install vcrun2015 (thanks to @KapiX ) and some msxml, the launcher "launched" normally, you can see the web page but not the different menu buttons at the left. The buttons are active, the first on the left starts the game.

capture d ecran de 2018-09-23 11-51-31

legluondunet commented 5 years ago

the wine log, I posted only the launcher log: https://pastebin.com/nP7eZyjS

sandsmark commented 5 years ago

the issue with the next in the launcher is maybe just a missing font? I've seen that before with wine, at least, missing fonts leads to text completely missing.

what I mean with IME stuff was in-game (you can see in your log that a lot of the imm stuff is stubs only). but that's just a guess.

as for the mfc140u.dll; the game ships with the runtime installer, but maybe it fails to run? https://bugs.winehq.org/show_bug.cgi?id=37781

just running ps while the runtime is installing seems to indicate it is running the x86_64 msvc runtime installer, though, so maybe the problem is that it should run the x86 one.

edit: tried running Age2HD/_CommonRedist/vcredist/2015/vc_redist.x86.exe with proton manually, and it fails with the «service not running» error. but the options I got when starting it was also repair or uninstall, so I'm a bit confused.

Flaburgan commented 5 years ago

FYI I play AoE with Windows steam installed with wine-staging for a while now and the launcher works with font correctly displayed in the left menu. So wine-staging should have the patches needed for it to work correctly.

legluondunet commented 5 years ago

@Flaburgan I just tested with wine-staging, it simply doesn't show the different buttons menu, you should try again from a new and clean wine prefix.

felisucoibi commented 5 years ago

Before proton, i played steam windows binary and then aoe launcher out of the box, and I had the same result as @legluondunet , so is more than probably that is just some missing libraries that can be aded with winetricks. or 32 bits libs... the bug of text missing was also there before proton in the menu, and as they say just click on first option. imagen

Flaburgan commented 5 years ago

@legluondunet I think I was using a 32bits prefix, but I'm sure it worked well with wine staging 3.13 and probably before.

sandsmark commented 5 years ago

as I said, I'm fairly certain the missing text is very probably because you're missing a font. Flaburgan probably has that font.

ryao commented 5 years ago

@Flaburgan Would you find out which fonts are being used with opensnoop for the rest of us?

https://github.com/brendangregg/perf-tools/blob/master/opensnoop

aljelly commented 5 years ago

If anyone wants a quick way of getting mfc140u.dll without trying to run the installer through Proton's Wine (this one will only work for Aoe2HD, the file version at the end of this post will work for other games):

  1. Open the terminal and install cabextract from your package manager (e.g. sudo apt install cabextract).
  2. Install the game if you haven't already.
  3. Copy paste and run the following in the terminal:
    cd "/home/$USER/.local/share/Steam/steamapps/common/Age2HD/_CommonRedist/vcredist/2015" &&
    cabextract vc_redist.x86.exe --filter a11 &&
    cabextract a11 --filter mfc140u.dll &&
    mv mfc140u.dll "../../../" &&
    rm a11

Run the game, it should now work.


Here's the file version if anyone wants to automate this, put in the game's folder (for other games this script assumes the binary that needs mfc140u.dll is in the game's root folder):

#!/usr/bin/env bash

pwd=$PWD

redist_dir="_CommonRedist/vcredist/2015"
shared_dir="../Steamworks Shared/"

if [ -d "$redist_dir" ]; then
    mfcdir=$redist_dir
elif [ -d "$shared_dir/$redist_dir" ]; then
    mfcdir="$shared_dir/$redist_dir"
else
    echo "Couldn't find Redist dir"
    exit 1
fi

cd "$mfcdir" &&
cabextract vc_redist.x86.exe --filter a11 &&
cabextract a11 --filter mfc140u.dll &&
mv mfc140u.dll $pwd &&
rm a11
liberodark commented 5 years ago

Solution is : https://github.com/simons-public/protonfixes/

felisucoibi commented 5 years ago

For me i had to modify the script in ubuntu 18.10 @aljelly

cd "/home/$USER/.steam/steam/steamapps/common/Age2HD/_CommonRedist/vcredist/2015" && cabextract vc_redist.x86.exe --filter a11 && cabextract a11 --filter mfc140u.dll && mv mfc140u.dll "../../../" && rm a11

So the launcher works, but the font are mising, is the first option of the menu.

aljelly commented 5 years ago

The problem that was causing the VC2015 installer to not launch was fixed in Wine 3.19 (thanks to @nsivov)! Once Proton's version of Wine is updated to 3.19, VC2015 will install and this game probably won't need any more workarounds to launch it.

nsivov commented 5 years ago

Fix is included in 3.16-4, mfc140u.dll should now be installed correctly.

felisucoibi commented 5 years ago

Fonts in launcher fixed too with 3.15-4!!!!

felisucoibi commented 5 years ago

By now the only missing bug to be fixed, is the text input area when playing multiplayer games in the room of a created match, that writing is black so you can't see what you wrote, because the font is black, and the background is black too, but the launcher is working, and the fonts are fixed. imagen

nsivov commented 5 years ago

@felisucoibi could you report this as a new issue? (assuming it works correctly on Windows)

felisucoibi commented 5 years ago

@felisucoibi could you report this as a new issue? (assuming it works correctly on Windows)

Don't understad what do you mean as a new issue, is not only one issues page for every game? (i updted with a photo the comment)

I edit myslef, somehow this is not anymore a age of empries bug but a proton bug, seems you moved this thread... sorry i'll create a new issue...

nsivov commented 5 years ago

My point was that it's not about launcher anymore. Thanks for the new report. Can we close this one as resolved?

felisucoibi commented 5 years ago

yes, in my tests