mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 18:47:35 +00:00
42 lines
No EOL
989 B
JavaScript
42 lines
No EOL
989 B
JavaScript
define([
|
|
"Game/" + GLOBALS.context + "/GameObjects/GameObject",
|
|
"Lib/Vendor/Planck"
|
|
],
|
|
|
|
function (Parent, planck) {
|
|
|
|
"use strict";
|
|
|
|
function SpectatorDoll(physicsEngine, uid, player) {
|
|
//Parent.call(this, physicsEngine, uid);
|
|
}
|
|
|
|
SpectatorDoll.prototype = Object.create(Parent.prototype);
|
|
|
|
SpectatorDoll.prototype.getBodyDef = function() {
|
|
var bodyDef = { type: 'static', position: planck.Vec2(0, 0), angle: 0 };
|
|
bodyDef.type = 'dynamic';
|
|
bodyDef.position.x = this.getPosition().x;
|
|
bodyDef.position.y = this.getPosition().y;
|
|
bodyDef.angle = 0;
|
|
|
|
return bodyDef;
|
|
};
|
|
|
|
SpectatorDoll.prototype.getPosition = function() {
|
|
return {x: 10, y: 10};
|
|
}
|
|
|
|
SpectatorDoll.prototype.getHeadPosition = function() {
|
|
return {x: 10, y: 10};
|
|
}
|
|
|
|
SpectatorDoll.prototype.update = function() {
|
|
};
|
|
|
|
SpectatorDoll.prototype.destroy = function() {
|
|
};
|
|
|
|
return SpectatorDoll;
|
|
|
|
}); |