win32/linux: Add start up scripts and add win32 Astron binaries.
This commit is contained in:
parent
3e79bb4af6
commit
3a4dbd8304
22 changed files with 151 additions and 24 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -13,3 +13,4 @@ whitelist/
|
||||||
venv/
|
venv/
|
||||||
*.buildings
|
*.buildings
|
||||||
*.trackRecords
|
*.trackRecords
|
||||||
|
PPYTHON_PATH
|
||||||
|
|
1
PPYTHON_PATH
Normal file
1
PPYTHON_PATH
Normal file
|
@ -0,0 +1 @@
|
||||||
|
"C:\Panda3D-1.11.0-x64\python\ppython.exe"
|
1
astron/.gitignore
vendored
1
astron/.gitignore
vendored
|
@ -1 +0,0 @@
|
||||||
bin/
|
|
BIN
astron/win32/astrond.exe
Normal file
BIN
astron/win32/astrond.exe
Normal file
Binary file not shown.
BIN
astron/win32/bsoncxx.dll
Normal file
BIN
astron/win32/bsoncxx.dll
Normal file
Binary file not shown.
BIN
astron/win32/concrt140.dll
Normal file
BIN
astron/win32/concrt140.dll
Normal file
Binary file not shown.
BIN
astron/win32/libbson-1.0.dll
Normal file
BIN
astron/win32/libbson-1.0.dll
Normal file
Binary file not shown.
BIN
astron/win32/libmongoc-1.0.dll
Normal file
BIN
astron/win32/libmongoc-1.0.dll
Normal file
Binary file not shown.
BIN
astron/win32/libuv.dll
Normal file
BIN
astron/win32/libuv.dll
Normal file
Binary file not shown.
BIN
astron/win32/mongocxx.dll
Normal file
BIN
astron/win32/mongocxx.dll
Normal file
Binary file not shown.
BIN
astron/win32/msvcp140.dll
Normal file
BIN
astron/win32/msvcp140.dll
Normal file
Binary file not shown.
BIN
astron/win32/vcruntime140.dll
Normal file
BIN
astron/win32/vcruntime140.dll
Normal file
Binary file not shown.
14
linux/start-ai-server.sh
Normal file
14
linux/start-ai-server.sh
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
#!/bin/sh
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
BASE_CHANNEL=401000000
|
||||||
|
MAX_CHANNELS=999999
|
||||||
|
STATE_SERVER=4002
|
||||||
|
MESSAGE_DIRECTOR_IP="127.0.0.1:7199"
|
||||||
|
EVENT_LOGGER_IP="127.0.0.1:7197"
|
||||||
|
DISTRICT_NAME="Toon Valley"
|
||||||
|
|
||||||
|
python3 -m toontown.ai.AIStart --base-channel ${BASE_CHANNEL} \
|
||||||
|
--max-channels ${MAX_CHANNELS} --stateserver ${STATE_SERVER} \
|
||||||
|
--messagedirector-ip ${MESSAGE_DIRECTOR_IP} \
|
||||||
|
--eventlogger-ip ${EVENT_LOGGER_IP} --district-name "$DISTRICT_NAME"
|
6
linux/start-astron-server.sh
Normal file
6
linux/start-astron-server.sh
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
#!/bin/sh
|
||||||
|
cd ../astron/linux
|
||||||
|
|
||||||
|
# This assumes that your astrond build is located in the
|
||||||
|
# "astron/linux" directory.
|
||||||
|
./astrond --loglevel info ../config/astrond.yml
|
8
linux/start-game.sh
Normal file
8
linux/start-game.sh
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
#!/bin/sh
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
# TODO: Make this actually work, to change token in the meantime,
|
||||||
|
# change the fake-playtoken variable in etc/Configrc.prc.
|
||||||
|
export LOGIN_TOKEN=dev
|
||||||
|
|
||||||
|
python3 -m toontown.toonbase.ToontownStart
|
13
linux/start-uberdog-server.sh
Normal file
13
linux/start-uberdog-server.sh
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
#!/bin/sh
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
MAX_CHANNELS=999999
|
||||||
|
STATE_SERVER=4002
|
||||||
|
MESSAGE_DIRECTOR_IP="127.0.0.1:7199"
|
||||||
|
EVENT_LOGGER_IP="127.0.0.1:7197"
|
||||||
|
BASE_CHANNEL=1000000
|
||||||
|
|
||||||
|
python3 -m toontown.uberdog.UDStart --base-channel ${BASE_CHANNEL} \
|
||||||
|
--max-channels ${MAX_CHANNELS} --stateserver ${STATE_SERVER} \
|
||||||
|
--messagedirector-ip ${MESSAGE_DIRECTOR_IP} \
|
||||||
|
--eventlogger-ip ${EVENT_LOGGER_IP}
|
|
@ -1,27 +1,48 @@
|
||||||
|
from panda3d.core import *
|
||||||
import builtins
|
import builtins
|
||||||
|
|
||||||
|
import argparse
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser(description='Open Toontown - AI Server')
|
||||||
|
parser.add_argument('--base-channel', help='The base channel that the server will use.')
|
||||||
|
parser.add_argument('--max-channels', help='The number of channels that the server will be able to use.')
|
||||||
|
parser.add_argument('--stateserver', help='The control channel of this AI\'s designated State Server.')
|
||||||
|
parser.add_argument('--district-name', help='The name of the district on this AI server.')
|
||||||
|
parser.add_argument('--messagedirector-ip',
|
||||||
|
help='The IP address of the Message Director that this AI will connect to.')
|
||||||
|
parser.add_argument('--eventlogger-ip', help='The IP address of the Astron Event Logger that this AI will log to.')
|
||||||
|
parser.add_argument('config', nargs='*', default=['etc/Configrc.prc'],
|
||||||
|
help='PRC file(s) that will be loaded on this AI instance.')
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
for prc in args.config:
|
||||||
|
loadPrcFile(prc)
|
||||||
|
|
||||||
|
localConfig = ''
|
||||||
|
if args.base_channel:
|
||||||
|
localConfig += 'air-base-channel %s\n' % args.base_channel
|
||||||
|
if args.max_channels:
|
||||||
|
localConfig += 'air-channel-allocation %s\n' % args.max_channels
|
||||||
|
if args.stateserver:
|
||||||
|
localConfig += 'air-stateserver %s\n' % args.stateserver
|
||||||
|
if args.district_name:
|
||||||
|
localConfig += 'district-name %s\n' % args.district_name
|
||||||
|
if args.messagedirector_ip:
|
||||||
|
localConfig += 'air-connect %s\n' % args.messagedirector_ip
|
||||||
|
if args.eventlogger_ip:
|
||||||
|
localConfig += 'eventlog-host %s\n' % args.eventlogger_ip
|
||||||
|
|
||||||
|
loadPrcFileData('AI Args Config', localConfig)
|
||||||
|
|
||||||
class game:
|
class game:
|
||||||
name = 'toontown'
|
name = 'toontown'
|
||||||
process = 'server'
|
process = 'server'
|
||||||
|
|
||||||
builtins.game = game
|
builtins.game = game
|
||||||
|
|
||||||
from panda3d.core import *
|
|
||||||
|
|
||||||
loadPrcFile('etc/Configrc.prc')
|
|
||||||
|
|
||||||
from otp.ai.AIBaseGlobal import *
|
from otp.ai.AIBaseGlobal import *
|
||||||
from toontown.ai.ToontownAIRepository import ToontownAIRepository
|
from toontown.ai.ToontownAIRepository import ToontownAIRepository
|
||||||
|
|
||||||
aiConfig = ''
|
|
||||||
aiConfig += 'air-base-channel %s\n' % 101000000
|
|
||||||
aiConfig += 'air-channel-allocation %s\n' % 999999
|
|
||||||
aiConfig += 'air-stateserver %s\n' % 4002
|
|
||||||
aiConfig += 'district-name %s\n' % 'Toon Valley'
|
|
||||||
aiConfig += 'air-connect %s\n' % '127.0.0.1:7199'
|
|
||||||
aiConfig += 'eventlog-host %s\n' % '127.0.0.1:7197'
|
|
||||||
loadPrcFileData('AI Config', aiConfig)
|
|
||||||
|
|
||||||
simbase.air = ToontownAIRepository(config.GetInt('air-base-channel', 1000000), config.GetInt('air-stateserver', 4002), config.GetString('district-name', 'Toon Valley'))
|
simbase.air = ToontownAIRepository(config.GetInt('air-base-channel', 1000000), config.GetInt('air-stateserver', 4002), config.GetString('district-name', 'Toon Valley'))
|
||||||
|
|
||||||
host = config.GetString('air-connect', '127.0.0.1:7199')
|
host = config.GetString('air-connect', '127.0.0.1:7199')
|
||||||
|
|
|
@ -1,5 +1,35 @@
|
||||||
|
from panda3d.core import *
|
||||||
import builtins
|
import builtins
|
||||||
|
|
||||||
|
import argparse
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser(description="Open Toontown - UberDOG Server")
|
||||||
|
parser.add_argument('--base-channel', help='The base channel that the server will use.')
|
||||||
|
parser.add_argument('--max-channels', help='The number of channels that the server will be able to use.')
|
||||||
|
parser.add_argument('--stateserver', help='The control channel of this UberDOG\'s designated State Server.')
|
||||||
|
parser.add_argument('--messagedirector-ip',
|
||||||
|
help='The IP address of the Message Director that this UberDOG will connect to.')
|
||||||
|
parser.add_argument('--eventlogger-ip', help='The IP address of the Astron Event Logger that this UberDOG will log to.')
|
||||||
|
parser.add_argument('config', nargs='*', default=['etc/Configrc.prc'],
|
||||||
|
help='PRC file(s) that will be loaded on this UberDOG instance.')
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
for prc in args.config:
|
||||||
|
loadPrcFile(prc)
|
||||||
|
|
||||||
|
localConfig = ''
|
||||||
|
if args.base_channel:
|
||||||
|
localConfig += 'air-base-channel %s\n' % args.base_channel
|
||||||
|
if args.max_channels:
|
||||||
|
localConfig += 'air-channel-allocation %s\n' % args.max_channels
|
||||||
|
if args.stateserver:
|
||||||
|
localConfig += 'air-stateserver %s\n' % args.stateserver
|
||||||
|
if args.messagedirector_ip:
|
||||||
|
localConfig += 'air-connect %s\n' % args.messagedirector_ip
|
||||||
|
if args.eventlogger_ip:
|
||||||
|
localConfig += 'eventlog-host %s\n' % args.eventlogger_ip
|
||||||
|
|
||||||
|
loadPrcFileData('UberDOG Args Config', localConfig)
|
||||||
|
|
||||||
class game:
|
class game:
|
||||||
name = 'uberDog'
|
name = 'uberDog'
|
||||||
|
@ -8,21 +38,11 @@ class game:
|
||||||
|
|
||||||
builtins.game = game
|
builtins.game = game
|
||||||
|
|
||||||
from panda3d.core import *
|
|
||||||
|
|
||||||
loadPrcFile('etc/Configrc.prc')
|
loadPrcFile('etc/Configrc.prc')
|
||||||
|
|
||||||
from otp.ai.AIBaseGlobal import *
|
from otp.ai.AIBaseGlobal import *
|
||||||
from toontown.uberdog.ToontownUDRepository import ToontownUDRepository
|
from toontown.uberdog.ToontownUDRepository import ToontownUDRepository
|
||||||
|
|
||||||
udConfig = ''
|
|
||||||
udConfig += 'air-base-channel %s\n' % 1000000
|
|
||||||
udConfig += 'air-channel-allocation %s\n' % 999999
|
|
||||||
udConfig += 'air-stateserver %s\n' % 4002
|
|
||||||
udConfig += 'air-connect %s\n' % '127.0.0.1:7199'
|
|
||||||
udConfig += 'eventlog-host %s\n' % '127.0.0.1:7197'
|
|
||||||
loadPrcFileData('UberDOG Config', udConfig)
|
|
||||||
|
|
||||||
simbase.air = ToontownUDRepository(config.GetInt('air-base-channel', 1000000), config.GetInt('air-stateserver', 4002))
|
simbase.air = ToontownUDRepository(config.GetInt('air-base-channel', 1000000), config.GetInt('air-stateserver', 4002))
|
||||||
|
|
||||||
host = config.GetString('air-connect', '127.0.0.1:7199')
|
host = config.GetString('air-connect', '127.0.0.1:7199')
|
||||||
|
|
14
win32/start_ai_server.bat
Normal file
14
win32/start_ai_server.bat
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
@echo off
|
||||||
|
title Open Toontown - AI (District) Server
|
||||||
|
cd..
|
||||||
|
|
||||||
|
rem Read the contents of PPYTHON_PATH into %PPYTHON_PATH%:
|
||||||
|
set /P PPYTHON_PATH=<PPYTHON_PATH
|
||||||
|
|
||||||
|
:main
|
||||||
|
%PPYTHON_PATH% -m toontown.ai.AIStart --base-channel 401000000 ^
|
||||||
|
--max-channels 999999 --stateserver 4002 ^
|
||||||
|
--messagedirector-ip 127.0.0.1:7199 ^
|
||||||
|
--eventlogger-ip 127.0.0.1:7197 ^
|
||||||
|
--district-name "Toon Valley"
|
||||||
|
goto main
|
5
win32/start_astron_server.bat
Normal file
5
win32/start_astron_server.bat
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
@echo off
|
||||||
|
title Open Toontown - Astron Server
|
||||||
|
cd ../astron/win32
|
||||||
|
astrond --loglevel info ../config/astrond.yml
|
||||||
|
pause
|
13
win32/start_game.bat
Normal file
13
win32/start_game.bat
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
@echo off
|
||||||
|
title Open Toontown - Game Client
|
||||||
|
cd..
|
||||||
|
|
||||||
|
rem Read the contents of PPYTHON_PATH into %PPYTHON_PATH%:
|
||||||
|
set /P PPYTHON_PATH=<PPYTHON_PATH
|
||||||
|
|
||||||
|
rem TODO: Make this actually work, to change token in the meantime,
|
||||||
|
rem change the fake-playtoken variable in etc/Configrc.prc.
|
||||||
|
set LOGIN_TOKEN=dev
|
||||||
|
|
||||||
|
%PPYTHON_PATH% -m toontown.toonbase.ToontownStart
|
||||||
|
pause
|
12
win32/start_uberdog_server.bat
Normal file
12
win32/start_uberdog_server.bat
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
@echo off
|
||||||
|
title Open Toontown - UberDOG Server
|
||||||
|
cd..
|
||||||
|
|
||||||
|
rem Read the contents of PPYTHON_PATH into %PPYTHON_PATH%:
|
||||||
|
set /P PPYTHON_PATH=<PPYTHON_PATH
|
||||||
|
|
||||||
|
%PPYTHON_PATH% -m toontown.uberdog.UDStart --base-channel 1000000 ^
|
||||||
|
--max-channels 999999 --stateserver 4002 ^
|
||||||
|
--messagedirector-ip 127.0.0.1:7199 ^
|
||||||
|
--eventlogger-ip 127.0.0.1:7197
|
||||||
|
pause
|
Loading…
Reference in a new issue