package { import flash.display.Sprite; import jp.dip.hael.gameai.graph.searcher.*; import jp.dip.hael.gameai.tree.Tree; import jp.dip.hael.gameai.tree.TreeNode; public class TreeTest extends Sprite { public function TreeTest() { var t:Tree = new Tree(); t.idxDomino( [0, 1, [2, 3]], [1, 2, [4, 5]], [1, 3, [6, 7, 8], [2, 4, [9, 10], [2, 5, [11, 12], [3, 7, [13, 14]]]]]); trace(t.rootIndex == 0); for(var i:int = 0; i <= 8; i++){ trace(i, t.parentIndex(i), t.childNodeIndexs(i), t.hasChild(i)); } } } }