startveh.java

来自「自己用swarm开发的一个车辆跟驰的模型」· Java 代码 · 共 34 行

JAVA
34
字号
// StartSimpleBug.java// Java SimpleBug application. import swarm.Globals;import swarm.defobj.Zone;public class StartVeh{    public static void main (String[] args)    {	ModelSwarm modelSwarm;          //   Swarm initialization: all Swarm apps must call this first.        Globals.env.initSwarm ("wsj", "2.1", 			       "bug-swarm@santafe.edu", args);	// Create a top-level Swarm object and build its internal	// objects and activities.	modelSwarm = new ModelSwarm(Globals.env.globalZone);		modelSwarm.buildObjects();		modelSwarm.buildActions();	System.out.println("di");	modelSwarm.activateIn(null);	// Now activate the swarm.	(modelSwarm.getActivity()).run();	// And drop it when we are finished.	modelSwarm.drop();    }}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?