AMPTemplates icon indicating copy to clipboard operation
AMPTemplates copied to clipboard

Template Request: Marvel Heroes Omega

Open Olivierleone opened this issue 7 months ago • 145 comments

Game Information:

Game Title: Marvel Heroes Omega How to obtain: https://github.com/Crypto137/MHServerEmu How to manually host the server: https://github.com/Crypto137/MHServerEmu/blob/master/docs/Setup/ManualSetup.md Suppoted OSs: Windows/Linux in the nightly build Supports RCON/Console input: yes

I confirm:

  • [ x] that I have searched for an existing module request for this application.
  • [ ] that the server is an official server distributed by the games publishers/developers.
  • [ x] that the server is available to the general public.
  • [ ] that the server can be run headless (without a GUI).
  • [x ] I have already attempted to create a configuration myself using the configuration tool

Olivierleone avatar May 25 '25 06:05 Olivierleone

Edit: I managed to fork the repo and upload my own template. However, I’m encountering an issue where the server won’t start. The files are correctly placed within the file manager. For Linux, the setup requires Wine, which I have specified. The login uses a reverse proxy: it listens on port 443 and redirects to port 8080. The game itself runs on port 4306.I’d really appreciate it if someone could give this a try and help troubleshoot or even create a better template?

Olivierleone avatar May 26 '25 21:05 Olivierleone

Edit: server works on the backend not through amp with a reverse proxy but game cant authenticate the user (cant access the path)

Olivierleone avatar May 28 '25 01:05 Olivierleone

Given AMP already uses port 8080 wouldn't you just reverse proxy the game's setup differently?

p0t4t0sandwich avatar May 28 '25 02:05 p0t4t0sandwich

Yeah, I did it It proxies port 443 to 8090, while the game runs on another port. Port forwarding was set up, the client uses my subdomain, and the server's siteconfig.xml also has my subdomain configured. I can successfully curl into it, but it throws an error — it seems like the path to the authentication is messed up. The template I’m using was originally Windows-based, so I had to modify it to work on Linux. I was wondering if someone could try to get it working, because I’m about three-quarters of the way there: the database generates correctly, and you can create an account in the terminal, but you just can’t log in through the client.

Image

Olivierleone avatar May 28 '25 02:05 Olivierleone

Yeah, after a breif look it seems as though you change that port using their Config.ini, I also don't see anything there limiting you to using Apache with port 443 as well (other reverse proxies would most likely work).

p0t4t0sandwich avatar May 28 '25 02:05 p0t4t0sandwich

yep also forgot to add that the config.ini replace localhost with 0.0.0.0 and my subdomain everything works except that auth path. im using nginx but the devs said it works so idk im confused. might be the path to auth that is weird. im running the stable version on windows but the server only have nightly build of the server. One guy made a template for windows that works perfect

Olivierleone avatar May 28 '25 02:05 Olivierleone

Would probably be a good idea to show your Nginx config in that case, since otherwise people that could potentially help are just flying blind. Also note nobody can test your fork till you push your changes, and your fork is also really outdated since it's forked from someone else's fork.

p0t4t0sandwich avatar May 28 '25 02:05 p0t4t0sandwich

Yea true sorry for that, at this point if someone can create just the template for linux as the one for windows looks to work pretty good, then i would get to test it out properly, im only launching the server from the terminal didnt get it to work on amp.

Olivierleone avatar May 28 '25 02:05 Olivierleone

also for my nginx if anyone needs it

server { listen 443 ssl; server_name marvel.leonelab.net;

ssl_certificate 
ssl_certificate_key 


# Proxy /AuthServer/ requests to the backend
location /AuthServer/ {
    proxy_pass http://ip to my local server:8090/;  # note the trailing slash
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "upgrade";
    proxy_set_header Host $host;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header X-Forwarded-Proto $scheme;
}

# Serve static SiteConfig.xml
location = /SiteConfig.xml {
    alias /home/amp/siteconfig/SiteConfig.xml;
    add_header Cache-Control "no-cache, no-store, must-revalidate";
    add_header Pragma "no-cache";
    add_header Expires 0;
}

# Block requests to bare root
location = / {
    return 404;
}

}

Olivierleone avatar May 28 '25 02:05 Olivierleone

This is presumably your issue: App.ExecutableLinux=mhserveremu/MHServerEmu

Should be: App.ExecutableLinux=MHServerEmu

assuming the binary is in the root dir. Also need to make it executable

Greelan avatar May 28 '25 03:05 Greelan

yea I fixed that still not launching via amp, anything else i can try?

Olivierleone avatar May 28 '25 03:05 Olivierleone

Any errors, logs, whatever? You are not giving much to go on. Have you added the sip files from the client to the server?

Greelan avatar May 28 '25 03:05 Greelan

Yea sorry was busy with something, when you go to load the application it says unable to run, there's nothing in the console. "a fault is preventing the application from starting. theres some deployment logs, Waiting for AMP instance to start... 23:29:28 AMP instance Marvel01 is now running. 23:29:44 Managed remote instance Marvel01 at "http://127.0.0.1:8082/ "

Olivierleone avatar May 28 '25 03:05 Olivierleone

this is the config made with the template to run with linux: Meta.DisplayName=MHServerEMU Meta.Description=MHServerEMU server Meta.OS=Windows, Linux Meta.AarchSupport=Unknown Meta.Arch=x86_64 Meta.Author=OlivierLeone - Made with AMP Config Generator Meta.URL=https://github.com/DrunkenMonk0001/PrivateMH Meta.DisplayImageSource=url:https://images.squarespace-cdn.com/content/v1/5985346fdb29d60e9d206ab3/1503506895353-M0KQUTDJO5VVPV5DD42Q/bg-registration-omega.jpg?format=2500w Meta.EndpointURIFormat= Meta.ConfigManifest=mhserveremuconfig.json Meta.MetaConfigManifest=mhserveremumetaconfig.json Meta.ConfigRoot=mhserveremu.kvp Meta.MinAMPVersion=2.4.6.6 Meta.SpecificDockerImage= Meta.DockerRequired=False Meta.DockerBaseReadOnly=False Meta.ContainerPolicy=Supported Meta.ContainerPolicyReason= Meta.ExtraSetupStepsURI= Meta.Prerequisites=[] Meta.ExtraContainerPackages=[] Meta.ConfigReleaseState=NotSpecified Meta.NoCommercialUsage=False Meta.ConfigVersion=0.0.0.0 Meta.ReleaseNotes= Meta.BreakingReleaseNotes= Meta.AppConfigId=9edbfd3d-0707-48d6-8c2e-97ca1777176b Meta.OriginalSource=Olivierleone-AMPTemplates-mytest Meta.ImportableExtensions=[".ini"] App.DisplayName=MHServerEMU App.RootDir=./mhserveremu/ App.BaseDirectory=./mhserveremu/ App.SteamWorkshopDownloadLocation={{$FullBaseDir}}undefined App.ExecutableWin=MHServerEmu.exe App.ExecutableLinux=MHServerEmu App.WorkingDir= App.LinuxCommandLineArgs= App.WindowsCommandLineArgs= App.CommandLineArgs= App.UseLinuxIOREDIR=False App.AppSettings={"EnableLogging":"true","SynchronousMode":"false","HideSensitiveInformation":"false","EnableConsole":"true","ConsoleIncludeTimestamps":"true","ConsoleMinLevel":"0","ConsoleMaxLevel":"5","EnableFile":"true","FileMinLevel":"0","FileMaxLevel":"5","BindIP":"127.0.0.1","Port":"4306","PublicAddress":"127.0.0.1","Address":"localhost","EnableWebApi":"true","UseJsonDBManager":"false","UseMySqlDBManager":"true","AllowClientVersionMismatch":"True","SimulateQueue":"false","QueuePlaceInLine":"false","QueueNumberOfPlayersInLine":"false","NewsUrl":"","ShowNewsOnLogin":"true","MySqlIP":"127.0.0.1","MySqlDBName":"Mheroes","MySqlUsername":"MheroesSQL","MySqlPw":"password123@","MySqlPort":"3306","MotdPlayerName":"MHServerEmu","MotdText":"Welcome back to Marvel Heroes! Type !commands to see a list of available commands. Type !tower to return to Avengers Tower.","ServerVersion":"0.3.0"} App.EnvironmentVariables={"LD_LIBRARY_PATH":"{{$FullBaseDir}}linux64:{{$FullRootDir}}linux64:%LD_LIBRARY_PATH%","WINEPREFIX":"{{$FullRootDir}}.wine","WINEARCH":"win64","WINEDEBUG":"-all"} App.CommandLineParameterFormat=-{0} "{1}" App.CommandLineParameterDelimiter= App.ExitMethod=String App.ExitMethodWindows=None App.ExitTimeout=7 App.ExitString=!server shutdown App.ExitFile=app_exit.lck App.HasWriteableConsole=True App.HasReadableConsole=True App.UDPLogger=False App.SupportsLiveSettingsChanges=False App.LiveSettingChangeCommandFormat=set {0} "{1}" App.ForceIPBinding=False App.SupportsIPv6=False App.ApplicationIPBinding=0.0.0.0 App.Ports=[{"Protocol":2,"Port":4306,"Offset":0,"Range":1,"Ref":"MainGamePort","Name":"Main Game Port","Description":"Port used for main game traffic","IsDelayedOpen":false,"Hidden":false,"ChildPorts":null,"Required":false}] App.ApplicationPort1=0 App.ApplicationPort2=0 App.ApplicationPort3=0 App.RemoteAdminPort=0 App.AdminPortRef=RemoteAdminPort App.PrimaryApplicationPortRef=GamePort1 App.UniversalSleepApplicationUDPPortRef=GamePort1 App.UniversalSleepSteamQueryPortRef=SteamQueryPort App.MaxUsers=0 App.UseRandomAdminPassword=True App.PersistRandomPassword=False App.RemoteAdminPassword= App.AdminMethod=STDIO App.IgnoreSTDOUTAfterRCON=False App.AdminLoginTransform=None App.StripANSIControlCodes=True App.LoginTransformPrefix= App.RCONConnectDelaySeconds=30 App.RCONConnectRetrySeconds=15 App.RCONHeartbeatMinutes=0 App.RCONHeartbeatCommand=ping App.RCONSelectIPMethod=Default App.TelnetLoginFormat={0} App.TelnetNewLineType=Default App.TailLogFilePath=server.log App.UpdateSources=[{"UpdateStageName":"downloading zip","UpdateStageDescription":null,"UpdateSourcePlatform":1,"UpdateSource":8,"UpdateSourceArch":3,"UpdateSourceData":"cmd.exe","UpdateSourceArgs":"/C cd C:/AMPDatastore/Instances/MHServerEMU01 & gh release download -R DrunkenMonk0001/PrivateMH -p MHServerEmu.zip --clobber","UpdateSourceVersion":null,"UpdateSourceExtra":null,"UpdateSourceTarget":null,"UnzipUpdateSource":false,"OverwriteExistingFiles":false,"ForceDownloadPlatform":0,"UpdateSourceConditionSetting":null,"UpdateSourceConditionValue":null,"DeleteAfterExtract":false,"RunInBackground":false,"SkipOnFailure":false,"OneShot":false},{"UpdateStageName":"extract zip","UpdateStageDescription":null,"UpdateSourcePlatform":31,"UpdateSource":32768,"UpdateSourceArch":3,"UpdateSourceData":"MHServerEmu.zip","UpdateSourceArgs":null,"UpdateSourceVersion":null,"UpdateSourceExtra":null,"UpdateSourceTarget":"{{$FullBaseDir}}","UnzipUpdateSource":false,"OverwriteExistingFiles":true,"ForceDownloadPlatform":0,"UpdateSourceConditionSetting":null,"UpdateSourceConditionValue":null,"DeleteAfterExtract":true,"RunInBackground":false,"SkipOnFailure":false,"OneShot":false}] App.PreStartStages=[] App.UserActions=[] App.ForceUpdate=False App.ForceUpdateReason= App.Compatibility=None App.SteamUpdateAnonymousLogin=True App.SteamForceLoginPrompt=False App.RapidStartup=False App.SmartExcludeExemptions=[".cfg",".conf",".config",".ini",".json",".xml",".properties",".kvp",".yml",".yaml",".toml",".lua"] App.SmartExcludeSupported=True App.DumpFullChildProcessTree=False App.MonitorChildProcessName= App.MonitorDirectChildOnly=False App.SupportsUniversalSleep=False App.WakeupMode=Any App.ApplicationReadyMode=Immediate Console.FilterMatchRegex= Console.FilterMatchReplacement= Console.ThrowawayMessageRegex=^(WARNING|ERROR): Shader.+$ Console.AppReadyRegex=^.AuthServer is listening.$ Console.UserJoinRegex=^.([PlayerManagerService] Successful auth for client [Account=(?[a-z|A-Z|0-9]+). ((?[a-z|A-Z|0-9]+).SessionId=(?[a-z|A-Z|0-9]+)).$ Console.UserLeaveRegex=^.(Removed frontend client [Account=(?[a-z|A-Z|0-9]+). ((?[a-z|A-Z|0-9]+).SessionId=(?[a-z|A-Z|0-9]+)). from game.serverGameId=(?[a-z|A-Z|0-9]+).$ Console.UserChatRegex=^.([GroupingManagerService] [LOCAL] [(?[a-z|A-Z|0-9]+)).+: (?.)$ Console.UpdateAvailableRegex=^[\d\d:\d\d:\d\d] [INFO] A new server update is available! v[\d.]+.$ Console.PreConnectRegex= Console.ConnectIPRegex= Console.MetricsRegex= Console.ServerInfoRegex= Console.HideFromConsoleRegex= Console.SuppressLogAtStart=False Console.UserActions={} Limits.SleepMode=True Limits.SleepOnStart=False Limits.SleepDelayMinutes=5 Limits.DozeDelay=2 Limits.AutoRetryCount=5 Limits.SleepStartThresholdSeconds=25

Olivierleone avatar May 28 '25 03:05 Olivierleone

I know, I've seen it in your repo.

You haven't answered my question about the sip files.

Greelan avatar May 28 '25 03:05 Greelan

the server has the sip files in its data/game directory the two mandatory sip files, Calligraphy.sip and mu_cdata.sip. is the template potentially wrong or not properly made? had to remake it to support linux

Olivierleone avatar May 28 '25 03:05 Olivierleone

Dunno, might be some other dependency needed on Linux. I assume you are manually adding the nightly build since the update stages don't...

Greelan avatar May 28 '25 03:05 Greelan

it needs .net dependencies pretty much it. + a proxy. yee adding it manually for testing purposes. im doing nothing diffrent for running the server in the terminal compared to amp. command im using cd /home/amp/.ampdata/instances/Marvel01/mhserveremu ./MHServerEmu

Olivierleone avatar May 28 '25 03:05 Olivierleone

Are you running it manually as the amp user? Are all the files owned by amp:amp?

Greelan avatar May 28 '25 03:05 Greelan

Oh that might of been the problem, the log file was owned by root and not by amp (before was running it as root only). i can now run it as amp user but not through the web interface?

Image

Its showing that the server is listening to the ports via the status panel if i turn on the server manuall, but no confirmation through console and still says unable to run

Image Image

but through the terminal it seems to be waiting for client connection

Image

Olivierleone avatar May 28 '25 04:05 Olivierleone

This is wrong: Console.AppReadyRegex=^.AuthServer is listening.$

That's why it is not displaying as started

Should be at a minimum:

Console.AppReadyRegex=^.*AuthServer is listening.*$

Though would be better to have more specific regex

Greelan avatar May 28 '25 04:05 Greelan

Why on earth would you run some random emulator downloaded from GH as root lol?

Greelan avatar May 28 '25 04:05 Greelan

Ill try the regex fix rn, and couldn't tell you lmao i was half awake trying a bunch of stuff. the regex fix hasn't fixed it, still says unable to load . (fetched the new changes)

Olivierleone avatar May 28 '25 04:05 Olivierleone

Did you chown -R amp:amp on the whole instance datastore?

Greelan avatar May 28 '25 04:05 Greelan

yep

Image

Olivierleone avatar May 28 '25 04:05 Olivierleone

I assume you stopped the manually run server first so there is not a port conflict, right?

Greelan avatar May 28 '25 04:05 Greelan

yes,

Image

I think it might be the template? i had to modify someone windows version of this, I might of messed up somewhere? Thanks for helping me, you killing it with the help

Olivierleone avatar May 28 '25 04:05 Olivierleone

I've got a template in my dev branch. Works fine.

18:14:14
  __  __ _    _  _____                          ______                 
 |  \/  | |  | |/ ____|                        |  ____|                
 | \  / | |__| | (___   ___ _ ____   _____ _ __| |__   _ __ ___  _   _ 
 | |\/| |  __  |\___ \ / _ \ '__\ \ / / _ \ '__|  __| | '_ ` _ \| | | |
 | |  | | |  | |____) |  __/ |   \ V /  __/ |  | |____| | | | | | |_| |
 |_|  |_|_|  |_|_____/ \___|_|    \_/ \___|_|  |______|_| |_| |_|\__,_|
	Version 0.6.0 | 2025.05.28 07:30:45 UTC | Release
[2025.05.28 08:14:14.091] [ Info] [ServerApp] MHServerEmu starting...
[2025.05.28 08:14:14.093] [Fatal] [PakFileSystem] mu_cdata.sip and/or Calligraphy.sip are missing! Make sure you copied these files to /AMP/marvel-heroes/server/Data/Game.

Except for the fact of course that I don't have the sip files.

There were a lot of issues with the template files you were using. I've cleaned up most of it, but removed the regex because it was doing nothing the way it was written, and haven't really touched the config manifest except to fix the port settings. The rest of the settings probably have similar issues.

My version of the template supplies its own .NET 8 and automatically downloads the latest nightly.

Greelan avatar May 28 '25 08:05 Greelan

If you send me over the sips, I can do more testing

Greelan avatar May 28 '25 08:05 Greelan

Eyyyyy fire, how do you want me to send them? also possible to use this image tried to change the image path but didnt work.https://www.trueachievements.com/customimages/l/063464.jpg? or does it conflict with anything. Added the sip files, going to try client side now which i had trouble with yesterday. so far server runs

Image

Olivierleone avatar May 28 '25 17:05 Olivierleone