Swap so Server is the AMP-client and Portal the AMP-server

This commit is contained in:
Griatch 2018-01-11 22:09:01 +01:00
parent 3971a08412
commit 82fd9ff698
3 changed files with 26 additions and 37 deletions

View file

@ -191,10 +191,10 @@ if AMP_ENABLED:
print(' amp (to Server): %s (internal)' % AMP_PORT)
factory = amp.AmpClientFactory(PORTAL)
amp_client = internet.TCPClient(AMP_HOST, AMP_PORT, factory)
amp_client.setName('evennia_amp')
PORTAL.services.addService(amp_client)
factory = amp.AmpServerFactory(PORTAL)
amp_service = internet.TCPServer(AMP_PORT, factory, interface=AMP_INTERFACE)
amp_service.setName("PortalAMPService")
PORTAL.services.addService(amp_service)
# We group all the various services under the same twisted app.