diff src/alice/test/topology/aquarium/AutoIncrement.java @ 178:1b532146b355 working

minor change
author e095732
date Sun, 03 Feb 2013 18:20:46 +0900
parents 88cc33eeafa6
children b5daccf36104
line wrap: on
line diff
--- a/src/alice/test/topology/aquarium/AutoIncrement.java	Tue Jan 29 15:25:22 2013 +0900
+++ b/src/alice/test/topology/aquarium/AutoIncrement.java	Sun Feb 03 18:20:46 2013 +0900
@@ -8,14 +8,12 @@
 	
 	private Receiver position = ids.create(CommandType.PEEK);
 	private Receiver number = ids.create(CommandType.PEEK);
-	private String key;
 	private float min = -1.3f;
 	private float max;
 	
 	public AutoIncrement(String key,int index){
-		this.key = key;
-		this.number.setKey("local","maxsize");
-		this.position.setKey("local", key,index);
+		this.number.setKey("local", "maxsize");
+		this.position.setKey("local", key, index);
 	}
 
 	@Override
@@ -31,7 +29,7 @@
 			fp.setXYZ(fp.getX()+0.01f, fp.getY(), fp.getZ());
 		}
 		
-		ods.update("local", key, fp);
+		ods.update("local", position.key, fp);
 		synchronized(this){
 			try {
 				// TODO
@@ -44,7 +42,7 @@
 			}
 		}
 		
-		new AutoIncrement(this.key,this.position.index);
+		new AutoIncrement(this.position.key, this.position.index);
 	}
 	
 }