swarm-support
[Top][All Lists]
Advanced

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

Re: Fine grained actions


From: Benedikt Stefansson
Subject: Re: Fine grained actions
Date: Wed, 03 May 2000 11:15:46 -0600

address@hidden wrote:

>   for (instant=0;instant<10;instant++)
>     [simulationSchedule at: instant createActionTo:
>                       [agentsList atOffset: instant]  message:
> M(evalSignals)];

<snip>

>
> ***event raised for error: AlreadyAtEnd
> ***function: _i_ListIndex__linked_next(), file:
> /src/Swarm/swarm/src/collections/List_GEN.m, line: 332
> *** execution terminating due to error
> /src/Swarm/swarm/src/defobj/Symbol.m :173 -[Error(c) _raiseEvent:]
>      0 [sig] sim 1391 stackdump: Dumping stack trace to sim.exe.stackdump

Subsitute "for(instant = 0; instant < [agentList getCount]; instant++)" in loop
above.

> Any hint?
> I was also wondering if the List of agents that is conventionally used in
> all Swarm simulations could be replaced by an Array object (if the number
> of agents remains unchanged during the simulation)and if this can increase
> speed.

Most certainly you can and should. And it does.

Benedikt

--
Benedikt Stefansson      | address@hidden
CASA, Inc.               | Ph : (505) 988-8807 x101
Santa Fe, NM 87501       | Fax: (505) 988-3440




                  ==================================
   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.



reply via email to

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