pylint: disable=missing-docstring, wrong-import-position

Configuration for worlds (environments and agents)

Worlds to be used are configured in this file. Two things are needed: 1. import the python file with the world 2. update the handler

There are a some examples that shows how this is done.


Change to the IP address of the server when using a public server

SERVER_ADDRESS = 'localhost'

Import the exmaples, these are found here:

import grid
import blind_dog
import random_agents
import random_mom_and_calf
import random_mom_and_calf2

Add a elif statement for each world like this:

elif message == 'blind_dog':

def handler(wss_, world, steps, seed):
    if world == 'random_agents':, steps)

    elif world == 'blind_dog':, steps)

    elif world == 'random_mom_and_calf':, steps, seed)

    elif world == 'random_mom_and_calf2':, steps, seed)

    elif world == 'grid':, steps, seed)

elif message == 'animat': (outputPath, outputDir) = animats.main.getOutputPath(), outputPath, outputDir, wss_)

        wss_.send_print_message(('unknown world "' + world +
                                 '" with param "' + str(steps) + '"'))