swarm-support
[Top][All Lists]
Advanced

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

[Swarm-Support] Button Problem


From: luo pi
Subject: [Swarm-Support] Button Problem
Date: Wed, 9 Apr 2003 01:06:35 -0700 (PDT)

Hi! 
With Swarm, I want to carry out the following problem:
there are three kinds of individual---red, yellow and
green, each 50, scattering uniformly in the space at
the beginning.  In the simulation process, the number
of red individual decreases, yellow one increases, and
each kind individual will aggregate together.

First, I let three individuals live in a world, and
use the same worldRaster, but I find that the
increased yellow one can not be seen in worldRaster,
whereas in the yellowList, the number of yellow one
increased. However, red one is normal. 

Then I let them live in three worlds, and also use the
same worldRaster, the above problem can be solved, but
I get a new trouble, looking at the following source
code:

individualredDisplay = [Object2dDisplay createBegin:
self];
  [individualredDisplay setDisplayWidget:
worldRaster];
  …         
  individualredDisplay = [inindividual1Display
createEnd];
 
[worldRaster setButton: ButtonRight
               Client: individualredDisplay
Message: M(makeProbeAtX:Y:)]; 

individualyellowDisplay = [Object2dDisplay
createBegin: self];
  [individualyellowDisplay setDisplayWidget:
worldRaster];
  …         
  individualyellowDisplay = [inindividualyellowDisplay
createEnd];
           
  [worldRaster setButton: ButtonRight
               Client: individualyellowDisplay
Message: M(makeProbeAtX:Y:)];
…
I find that with mouse right button in the
worldRaster, only the information of individualyellow
can be gotten, but individual1 can not. If delete the
setButton command of individualyellow, individualred
can. 

Some persons tell me a few days ago, let them use the
different wolrdRaster. I try it, it is okey! Whereas I
can see three worldRasters in the screen, which
possess their own individual. However, I hope them
stay in the same worldRster.

This problem bothers me a lot. Maybe someone can give
me a whole solution or some advices. 

Thank you very much!
                                                      
                         Patrick.L 


__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online, calculators, forms, and more
http://tax.yahoo.com


reply via email to

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