Getting Started

From OuroDev

Server Setup

Download Files

Online Tools

Setup Local Server

  1. Install SQL Server 2017 Express Edition
  2. Choose Basic when installing and when given the option choose to install SSMS.
  3. Open up wherever you extracted the i25 Binaries folder and navigate to data\server\db
  4. Open up chat_server.cfg and account_server.cfg
    You will see something like this.
    SqlLogin "DRIVER={SQL Server Native Client 11.0};Server=NS319069\SCORE;Uid=sa;Pwd=FinallyFree!;"
    Change this to
    SqlLogin "DRIVER={SQL Server Native Client 11.0};Server=localhost\SQLEXPRESS;Uid=sa;Pwd=password;"
    • You can change the password to whatever you would like. For this example I will be just using password.
    • Now open up server.cfg and change all the ips to localhost (Note : You could also set these to your local ip if you know it.)
    At the top of the file you will see this.The IP will be set to whatever you previous set it to.
    DBServer 192.168.0.1 18717
    ShardName Bree
    AuthServer 192.168.0.1 2104
    DefaultAccessLevel 0
    NoStats 1
    • Change the ShardName to whatever you would like and add 2 slashes infront of AuthServer. And add UseFakeAuth 1 under NoStats 1
    It should now look like this
    DBServer localhost 18717
    ShardName ShardName
    //AuthServer 192.168.0.1 2104
    DefaultAccessLevel 0
    NoStats 1
    UseFakeAuth 1
  5. Okay now extract the dbschema.rar found in your i25 folder. We will be using these later.
  6. Open up SQL Server Management Studio (SSMS which you installed in the first step). Your one will look slightly different and hit Connect.
  7. Now we have to enable SQL logins so that the databases can connect. We need to enable them and the sa login so that user can login to the database.
  8. If you look to the left panel you will see the object explorer and your connection. Right click it and enter properties.
  9. When this window comes up hit Security to the left and enable sql server and windows authentication. Then click ok.
  10. In the same panel you used before navigate to Security -> Logins then right click and enter properties the sa user.
  11. In this window set the password to the same password you set back at step 4
  12. Once you are done there. Choose Status from the left panel in this same window and set login to enabled and hit ok.
  13. Okay now navigate back to your i25 folder and open the dbschema folder I previously had you extract and open up cohauc.sql in SQL Server Management Studio.
  14. You will see these 2 lines at the top of the file opened
    • ( NAME = N'cohauc', FILENAME = N'C:\mssql\MSSQL11.SCORE\MSSQL\DATA\cohauc.mdf' , SIZE = 157440KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
    • ( NAME = N'cohauc_log', FILENAME = N'C:\mssql\MSSQL11.SCORE\MSSQL\DATA\cohauc_log.ldf' , SIZE = 353216KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
  15. What you want to do is set the first part of these directory listings to where your SQL Server is located for example, I set my to D:\Program Files\Microsoft SQL Server\MSSQL14.SQLEXPRESS\MSSQL because that is where my SQL Server is. So my would become:
    • ( NAME = N'cohauc', FILENAME = N'D:\Program Files\Microsoft SQL Server\MSSQL14.SQLEXPRESS\MSSQL\DATA\cohauc.mdf' , SIZE = 157440KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
    • ( NAME = N'cohauc_log', FILENAME = N'D:\Program Files\Microsoft SQL Server\MSSQL14.SQLEXPRESS\MSSQL\DATA\cohauc_log.ldf' , SIZE = 353216KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
  16. Once done click the Execute button. And do this again for both the cohauth and cohchat.
  17. Once you have done that you can now start up your server. Navigate back to your i25 files and start up dbserver and dblauncher
    • Note : you will have to fix up these shortcuts so they point back to their intended destinations.
  18. Go to your City of Heroes folder and make a shortcut of score.exe adding
    • score.exe -db 127.0.0.1 -console -patchdir score -noversioncheck -project "coh"
  19. Login and Enjoy!

Setup Auth Server

  1. The first thing you are going to want to do is set the ips in server.cfg to your Internal/Local ip. Then you will remove the slashes from the front of authserver and putting them infront of UseFakeAuth 1 and that is nolonger necessary.
    • DBServer 192.168.0.48 18717
    • ShardName Personality
    • AuthServer 192.168.0.48 2104
    • DefaultAccessLevel 0
    • NoStats 1
    • //UseFakeAuth 1
  2. Open up ODBC Data Sources.
    • Click File DSN then click add to the right.
    • Choose ODBC Driver 17 for SQL Server. Click Next.
    • Enter AuthDB into the box and hit next then finish.
    • It will then say something like ‘Which SQL Server would you like to connect to?’
      • Type localhost\SQLEXPRESS and hit next.
    • Choose with SQL Auth enter sa into username and the password you use previously.
    • Tick choose change default database to and select cohauth and hit next.
    • After this hit finish then ‘Test Data source’ this will test the auth database connection to your main database if it successful congrats :D

Setup Auction Server

  1. Create auction_server.cfg in C:\COH\data\server\db.
    • ShardIp 127.0.0.1
    • SqlDbName cohauc
    • SqlLogin "DRIVER={SQL Server Native Client 11.0};Server=localhost\SQLEXPRESS;Uid=sa;Pwd=YOURL33TPASS;"
  2. Start AuctionServer64.exe

Setup using Virtual Server Image

  1. Download VMWare Player
  2. Add the VM to VMWare Player
  3. Once inside of Windows on the VM
    • - Start Menu -> start dbserver -> start launcher
  4. On your system, start the client from Score (Cityofheroes\score.exe -patchdir score -patchversion 2019.04.19 -db <VM IP> -noversioncheck

Setup

Port Forwards

TCP Ports
Port 11228
UDP Ports
Ports 18717 through 18817

Common Questions

How do I create an account?

  • You can use the PowerShell script in downloads or execute a query against the database manually.
  • Create NEW USER: test / password
    • INSERT INTO cohauth.dbo.user_account (account, uid, forum_id, pay_stat) VALUES ('test', 1, 1, 1014);
    • INSERT INTO cohauth.dbo.user_auth (account, password, salt, hash_type) VALUES ('test', CONVERT(BINARY(128),'46ffce3efcfe83bfa205b076d7c2084b9dcf04cdb26f9019103cde29779d26a85216b2c0f43ba1a8fb9b7fa22f05a949bf4edc314af27629e8fc23014e77a24d'), 0, 1);
    • INSERT INTO cohauth.dbo.user_data (uid, user_data) VALUES (1, 0x0080C2E000D00B0C000000000CB40058);
    • INSERT INTO cohauth.dbo.user_server_group (uid, server_group_id) VALUES (1, 1);
  • Crust First's web-based tool for generating SQL queries to create new accounts

How do I make a GM Character?

  • UPDATE [cohdb].[dbo].[Ents] SET [AccessLevel] = 10 WHERE [Name] = 'charnamehere'
  • You can also set DefaultAccessLevel to 10 in servers.cfg, but this will only work for characters made after you make this change
  • Login to the game and type /mmm to bring up an admin menu. All commands are also listed in Commands.cfg

Why does my server show offline?

  • First make sure you've added your server into the database. You can do so with the code below.
    • INSERT INTO cohauth.dbo.server (id, name, ip, inner_ip, ageLimit, pk_flag, server_group_id) VALUES (1, 'Bree', '127.0.0.1', '127.0.0.1', 0, 0, 1);

Why does my AuthServer say "Non-registered world server X.X.X.X"?

  • Make sure the server is in the cohauth
    • INSERT INTO cohauth.dbo.server (id, name, ip, inner_ip, ageLimit, pk_flag, server_group_id) VALUES (1, 'Bree', '127.0.0.1', '127.0.0.1', 0, 0, 1);