|
Development Forum |
 |
| 
Geek2Nurse
 

|
4/30/2012 | |
So I develop a plant agent, and I define all this stuff for it -- attr, bhvr, perm, elas, puhl, tick, etc. Then I define a seed agent which triggers a new instance of the plant agent, and have to define all the same things again? Is there no way to put them all in a subroutine and call it from both places? Don't the referential integrity police come and take you away for stuff like this???
---
Optimist: the glass is half full.
Pessimist: the glass is half empty.
Engineer: the glass is twice as big as it needs to be. |
 Prodigal Sock
Ghosthande
    

|
4/30/2012 | |
Script with #10 (eg. "scrp 1 1 60624 10" ) is the constructor script, which automatically fires for any agent of that type when it is first created. So yes, you can dump all the characteristics you want to set when the agent is created into that script, and never worry about it again.
As far as I'm aware, though, it only works for DS, not C3. So if you're working on something that's meant to be compatible with C3 standalone, you do need to define them every time.
 |
|