Skip to content

Commit f59d7e3

Browse files
committed
Working through Graphics class updates.
1 parent 5f820bd commit f59d7e3

3 files changed

Lines changed: 98 additions & 212 deletions

File tree

src/gameobjects/Graphics.js

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -79,22 +79,6 @@ Phaser.Graphics.prototype.destroy = function(destroyChildren) {
7979

8080
};
8181

82-
/*
83-
* Draws a circle.
84-
*
85-
* @method Phaser.Graphics.prototype.drawCircle
86-
* @param {Number} x - The X coordinate of the center of the circle.
87-
* @param {Number} y - The Y coordinate of the center of the circle.
88-
* @param {Number} diameter - The diameter of the circle.
89-
* @return {Phaser.Graphics} This Graphics object.
90-
*/
91-
Phaser.Graphics.prototype.drawCircle = function(x, y, diameter)
92-
{
93-
this.drawShape(new Phaser.Circle(x, y, diameter));
94-
95-
return this;
96-
};
97-
9882
/*
9983
* Draws a single {Phaser.Polygon} triangle from a {Phaser.Point} array
10084
*

src/pixi/Pixi.js

Lines changed: 10 additions & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ var PIXI = PIXI || {};
2424
* @static
2525
*/
2626
PIXI.WEBGL_RENDERER = 0;
27+
2728
/**
2829
* @property {Number} CANVAS_RENDERER
2930
* @protected
@@ -36,72 +37,12 @@ PIXI.CANVAS_RENDERER = 1;
3637
* @property {String} VERSION
3738
* @static
3839
*/
39-
PIXI.VERSION = "v2.2.1c";
40-
41-
/**
42-
* Various blend modes supported by pixi. IMPORTANT - The WebGL renderer only supports the NORMAL, ADD, MULTIPLY and SCREEN blend modes.
43-
* @property {Object} blendModes
44-
* @property {Number} blendModes.NORMAL
45-
* @property {Number} blendModes.ADD
46-
* @property {Number} blendModes.MULTIPLY
47-
* @property {Number} blendModes.SCREEN
48-
* @property {Number} blendModes.OVERLAY
49-
* @property {Number} blendModes.DARKEN
50-
* @property {Number} blendModes.LIGHTEN
51-
* @property {Number} blendModes.COLOR_DODGE
52-
* @property {Number} blendModes.COLOR_BURN
53-
* @property {Number} blendModes.HARD_LIGHT
54-
* @property {Number} blendModes.SOFT_LIGHT
55-
* @property {Number} blendModes.DIFFERENCE
56-
* @property {Number} blendModes.EXCLUSION
57-
* @property {Number} blendModes.HUE
58-
* @property {Number} blendModes.SATURATION
59-
* @property {Number} blendModes.COLOR
60-
* @property {Number} blendModes.LUMINOSITY
61-
* @static
62-
*/
63-
PIXI.blendModes = {
64-
NORMAL:0,
65-
ADD:1,
66-
MULTIPLY:2,
67-
SCREEN:3,
68-
OVERLAY:4,
69-
DARKEN:5,
70-
LIGHTEN:6,
71-
COLOR_DODGE:7,
72-
COLOR_BURN:8,
73-
HARD_LIGHT:9,
74-
SOFT_LIGHT:10,
75-
DIFFERENCE:11,
76-
EXCLUSION:12,
77-
HUE:13,
78-
SATURATION:14,
79-
COLOR:15,
80-
LUMINOSITY:16
81-
};
82-
83-
/**
84-
* The scale modes that are supported by pixi.
85-
*
86-
* The DEFAULT scale mode affects the default scaling mode of future operations.
87-
* It can be re-assigned to either LINEAR or NEAREST, depending upon suitability.
88-
*
89-
* @property {Object} scaleModes
90-
* @property {Number} scaleModes.DEFAULT=LINEAR
91-
* @property {Number} scaleModes.LINEAR Smooth scaling
92-
* @property {Number} scaleModes.NEAREST Pixelating scaling
93-
* @static
94-
*/
95-
PIXI.scaleModes = {
96-
DEFAULT:0,
97-
LINEAR:0,
98-
NEAREST:1
99-
};
40+
PIXI.VERSION = "v2.2.5c";
10041

10142
// used to create uids for various pixi objects..
10243
PIXI._UID = 0;
10344

104-
if(typeof(Float32Array) != 'undefined')
45+
if (typeof(Float32Array) != 'undefined')
10546
{
10647
PIXI.Float32Array = Float32Array;
10748
PIXI.Uint16Array = Uint16Array;
@@ -120,10 +61,6 @@ else
12061
PIXI.Uint16Array = Array;
12162
}
12263

123-
// interaction frequency
124-
PIXI.INTERACTION_FREQUENCY = 30;
125-
PIXI.AUTO_PREVENT_DEFAULT = true;
126-
12764
/**
12865
* @property {Number} PI_2
12966
* @static
@@ -148,16 +85,6 @@ PIXI.DEG_TO_RAD = Math.PI / 180;
14885
* @static
14986
*/
15087
PIXI.RETINA_PREFIX = "@2x";
151-
//PIXI.SCALE_PREFIX "@x%%";
152-
153-
/**
154-
* If true the default pixi startup (console) banner message will be suppressed.
155-
*
156-
* @property {Boolean} dontSayHello
157-
* @default false
158-
* @static
159-
*/
160-
PIXI.dontSayHello = false;
16188

16289
/**
16390
* The default render options if none are supplied to
@@ -174,40 +101,11 @@ PIXI.dontSayHello = false;
174101
* @static
175102
*/
176103
PIXI.defaultRenderOptions = {
177-
view:null,
178-
transparent:false,
179-
antialias:false,
180-
preserveDrawingBuffer:false,
181-
resolution:1,
182-
clearBeforeRender:true,
183-
autoResize:false
184-
}
185-
186-
PIXI.sayHello = function (type)
187-
{
188-
if(PIXI.dontSayHello)return;
189-
190-
if ( navigator.userAgent.toLowerCase().indexOf('chrome') > -1 )
191-
{
192-
var args = [
193-
'%c %c %c Pixi.js ' + PIXI.VERSION + ' - ' + type + ' %c ' + ' %c ' + ' http://www.pixijs.com/ %c %c ♥%c♥%c♥ ',
194-
'background: #ff66a5',
195-
'background: #ff66a5',
196-
'color: #ff66a5; background: #030307;',
197-
'background: #ff66a5',
198-
'background: #ffc3dc',
199-
'background: #ff66a5',
200-
'color: #ff2424; background: #fff',
201-
'color: #ff2424; background: #fff',
202-
'color: #ff2424; background: #fff'
203-
];
204-
205-
console.log.apply(console, args);
206-
}
207-
else if (window['console'])
208-
{
209-
console.log('Pixi.js ' + PIXI.VERSION + ' - http://www.pixijs.com/');
210-
}
211-
212-
PIXI.dontSayHello = true;
104+
view: null,
105+
transparent: false,
106+
antialias: false,
107+
preserveDrawingBuffer: false,
108+
resolution: 1,
109+
clearBeforeRender: true,
110+
autoResize: false
213111
};

0 commit comments

Comments
 (0)