mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-01 02:38:43 -05:00
Revert previous commit of BouncingBalls example.
This commit is contained in:
parent
357a8af6ec
commit
e898f0482c
1 changed files with 15 additions and 26 deletions
|
@ -23,7 +23,6 @@
|
|||
<script type="text/javascript" src="../../src/path/Segment.js"></script>
|
||||
<script type="text/javascript" src="../../src/path/PathItem.js"></script>
|
||||
<script type="text/javascript" src="../../src/path/Path.js"></script>
|
||||
<script type="text/javascript" src="../../src/path/CompoundPath.js"></script>
|
||||
<script type="text/javascript" src="../../src/path/Path.Constructors.js"></script>
|
||||
<script type="text/javascript" src="../../src/color/Color.js"></script>
|
||||
<script type="text/javascript" src="../../src/color/RGBColor.js"></script>
|
||||
|
@ -44,21 +43,11 @@
|
|||
|
||||
var balls = [];
|
||||
|
||||
|
||||
var circlePath = new Path.Circle([0, 0], 10);
|
||||
circlePath.fillColor = 'red';//new GradientColor(null, [0, 0], [0, 12], [0, 2]);
|
||||
//circlePath.fillColor.gradient.type = 'radial';
|
||||
circlePath.fillColor = new GradientColor(null, [0, 0], [0, 12], [0, 2]);
|
||||
circlePath.fillColor.gradient.type = 'radial';
|
||||
|
||||
var smallerPath = new Path.Circle([0, 0], 5);
|
||||
smallerPath.segments.reverse();
|
||||
for (var i = 0, l = smallerPath.segments.length; i < l; i++) {
|
||||
var segment = smallerPath.segments[i];
|
||||
smallerPath.segments[i] = segment.reverse();
|
||||
}
|
||||
smallerPath.fillColor = 'red';
|
||||
var compoundPath = new CompoundPath([circlePath, smallerPath]);
|
||||
compoundPath.strokeColor = 'black';
|
||||
var symbol = new Symbol(compoundPath);
|
||||
var symbol = new Symbol(circlePath);
|
||||
|
||||
var group = new Group();
|
||||
|
||||
|
|
Loading…
Reference in a new issue