[Commit] RRbot RicochetRecursive.java,1.2,1.3
Christian L. Platt
commit at keithp.com
Tue Jun 10 01:33:48 PDT 2003
- Previous message: [Commit] rrserver dispatch.5c,1.23,1.24 games.5c,1.20,1.21
server.5c,1.11,1.12
- Next message: [Commit]
jove ask.c,1.4,1.5 disp.c,1.3,1.4 error.c,1.2,1.3 extend.c,1.2,1.3
fmt.c,1.2,1.3 iproc-pipes.c,1.1.1.1,1.2 iproc-ptys.c,1.4,1.5
jove.c,1.5,1.6 jove.h,1.6,1.7 move.c,1.2,1.3 nproc.c,1.1.1.1,1.2
proc.c,1.2,1.3 term.c,1.4,1.5 util.c,1.3,1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Committed by: plattc
Update of /local/src/CVS/RRbot
In directory home.keithp.com:/tmp/cvs-serv20727
Modified Files:
RicochetRecursive.java
Log Message:
Did some fine tuning.
Index: RicochetRecursive.java
===================================================================
RCS file: /local/src/CVS/RRbot/RicochetRecursive.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- RicochetRecursive.java 10 Jun 2003 06:31:01 -0000 1.2
+++ RicochetRecursive.java 10 Jun 2003 07:33:45 -0000 1.3
@@ -129,8 +129,7 @@
solutionFound( newMoves );
}
//calculate h for new node
- //h = (int) (1.5 * distMatrix[robMatrixPos][goalMatrixPos]);
- h = distMatrix[robMatrixPos][goalMatrixPos];
+ h = (int) (1.3 * distMatrix[robMatrixPos][goalMatrixPos]);
if ( g + h > maxDepth ) {
@@ -167,15 +166,14 @@
, robots[i].cpos() );
continue;
}
- //if ( old != null ) {
- //removedNodes++;
- //stopT.remove(zkey);
- //} else {
+ if ( old != null ) {
+ removedNodes++;
+ stopT.remove(zkey);
+ }
- IDAstar( curDepth, maxDepth, newNode );
+ IDAstar( curDepth, maxDepth, newNode );
- stopT.put( zkey, newNode );
- //}
+ stopT.put( zkey, newNode );
// undo the move
@@ -183,8 +181,7 @@
, robots[i].cpos() );
}
}
- //Long zkey = stopT.getKey( robots );
- //stopT.put( zkey, newNode );
+
return 0;
}
- Previous message: [Commit] rrserver dispatch.5c,1.23,1.24 games.5c,1.20,1.21
server.5c,1.11,1.12
- Next message: [Commit]
jove ask.c,1.4,1.5 disp.c,1.3,1.4 error.c,1.2,1.3 extend.c,1.2,1.3
fmt.c,1.2,1.3 iproc-pipes.c,1.1.1.1,1.2 iproc-ptys.c,1.4,1.5
jove.c,1.5,1.6 jove.h,1.6,1.7 move.c,1.2,1.3 nproc.c,1.1.1.1,1.2
proc.c,1.2,1.3 term.c,1.4,1.5 util.c,1.3,1.4
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the Commit
mailing list