swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Support] Problems with ObserverSwarm


From: Steve Railsback
Subject: Re: [Swarm-Support] Problems with ObserverSwarm
Date: Tue, 04 Oct 2005 09:31:43 -0700
User-agent: Mozilla Thunderbird 1.0.2 (Windows/20050317)

Crile Doscher wrote:
putValue method was used to set the value in cell objects. I based my ObserverSwarm/Build Objects on Heatbugs, specifically the setDiscrete2dToDisplay method:

[elevDisplay setDiscrete2dToDisplay: [modelSwarm getElevSpace]];

SO, my question is, is there an better syntax to get ObserverSwarm to pull in the correct values? I've played around with something like:

[elevDisplay setDiscrete2dToDisplay: [[modelSwarm getElevSpace]] getCellAtX: Y:] getElevLevel];

This will not work because setDiscrete2dToDisplay expects just the grid space object.

The code for actually selecting the color has to be in the cell's drawSelfOn method.

Off-list I will send you some code from an example which is simple- we draw water depth (for submerged cells) and elevation (for cells above water).

Steve

--
Lang Railsback & Assoc.
250 California Ave.
Arcata, California 95521
(707) 822-0453


reply via email to

[Prev in Thread] Current Thread [Next in Thread]