% File "world.ti". % % Written by Phil Edmonds, March 97. % % This is the interface for the world. Only one instance of a world should % be created at once, because they will overlap on the screen. (a better way % would be to re-write Init so that one could specify the coordinates of the % world on the screen). See the body for more details. % %+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ unit class World implement by WorldBody in "world.tb" import Object in "object.tu", Terrain in "terrain.tu", Location in "location.tu" export Init, Fini, Simulate, Schedule, DrawWorld, DrawWorldPart, DrawAllDenizens, AddStatistic, AddDenizen, GetRandomDenizen, RandomLocation, WhatTerrain %================================================================= deferred proc Init deferred proc Fini deferred proc Simulate (maxTime : int) deferred proc Schedule (denizen : ^Object, at : int) deferred proc AddDenizen (denizen : ^Object) deferred proc AddStatistic (stat : string) deferred proc DrawWorld deferred proc DrawWorldPart (loc : ^Location, r : int) deferred proc DrawAllDenizens deferred function GetRandomDenizen : ^Object deferred function RandomLocation (frame : int) : ^Location deferred function WhatTerrain (loc : ^Location) : ^Terrain end World