/** * Graphics API * @param id String * @param name * @param graphicsType * @param parentEntity * @constructor */ GameLib.D3.API.Graphics = function ( parentEntity ) { GameLib.Component.call( this, GameLib.Component.COMPONENT_GRAPHICS, null, null, parentEntity ); }; GameLib.D3.API.Graphics.prototype = Object.create(GameLib.Component.prototype); GameLib.D3.API.Graphics.prototype.constructor = GameLib.D3.API.Graphics; /** * Object to GameLib.D3.API.Graphics * @param objectComponent * @constructor */ GameLib.D3.API.Graphics.FromObjectComponent = function(objectComponent) { return new GameLib.D3.API.Graphics( objectComponent.id, objectComponent.name, objectComponent.graphicsType, objectComponent.parentEntity ); };