Your probemap shows, right? I can't tell from your code below if it
would or not, but I believe you say it does. Is the problem that the
values in the probe are not being updated as the sim runs? I have done
projects like that. If that is what you want, I think the solution is
to schedule a method in your observer level that updates the tk widgets
at each step.
If you have a method that is scheduled to run every time, I think you
can just put this at the end of it:
[actionCache doTkEvents];
Or you can explicitly schedule a tk update:
[displayActions createActionTo: actionCache message:
M(doTkEvents)];
Of course, you translate over for java, but you appear to be quite good
at that, as far as I can see:)
pj
Olivier Jauze wrote:
>
> Hi,
> like in the mousetrap exemple, I have tried to create and customize an
> EmptyProbeMap.
> I would like to update this probe after I press on the start button.
> My aim is to visualize class' attributs during the simulation then I will
> know how this attributes will evolve in time.
> How can I do that ? Is it possible ?
> Thanks in advance.
>
> Here it is my code for the EmptyProbeMap:
>
> class ModelSwarmProtoProbeMap extends EmptyProbeMapImpl
> {
> private VarProbe probeVariable (String name)
> {
> return Globals.env.probeLibrary.getProbeForVariable$inClass
> ( name, ModelSwarmProto.this.getClass () );
> }
>
> private void add (String name)
> {
> addProbe (probeVariable (name));
> }
>
> public ModelSwarmProtoProbeMap (Zone _aZone, Class aClass)
> {
> super (_aZone, aClass);
> add ("nbSimu");
> add ("optionGenisse");
> add("essai");
> }
> }
--
Paul E. Johnson email: address@hidden
Dept. of Political Science http://lark.cc.ukans.edu/~pauljohn
University of Kansas Office: (785) 864-9086
Lawrence, Kansas 66045 FAX: (785) 864-5700
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.