【发布时间】:2012-05-15 02:27:06
【问题描述】:
我正在尝试通过 Meteor 更新 KineticJS 对象的位置。
看来问题出在:
Players.update({name: "Rect"}, {xpos: this.attrs.x})
流星文档是这样说的:
// Find the document with id "123", and completely replace it.
Users.update({_id: "123"}, {name: "Alice", friends: ["Bob"]});
我试图检查数据是否正在通过以下方式更新:
console.log(Players.findOne({name: "Rect"}).xpos);
这里是github:
https://github.com/randompast/randomtests/tree/master/meteorCanvasTest
【问题讨论】:
标签: javascript mongodb canvas meteor kineticjs