Skip to content

Commit aecc3bf

Browse files
committed
Merge remote-tracking branch 'refs/remotes/LLK/develop' into develop
2 parents 8246282 + 8c7ca95 commit aecc3bf

31 files changed

+351
-188
lines changed

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33

44
[![Build Status](https://travis-ci.org/LLK/scratch-vm.svg?branch=develop)](https://travis-ci.org/LLK/scratch-vm)
55
[![Coverage Status](https://coveralls.io/repos/github/LLK/scratch-vm/badge.svg?branch=develop)](https://coveralls.io/github/LLK/scratch-vm?branch=develop)
6-
[![Dependency Status](https://david-dm.org/LLK/scratch-vm.svg)](https://david-dm.org/LLK/scratch-vm)
7-
[![devDependency Status](https://david-dm.org/LLK/scratch-vm/dev-status.svg)](https://david-dm.org/LLK/scratch-vm#info=devDependencies)
6+
[![Greenkeeper badge](https://badges.greenkeeper.io/LLK/scratch-vm.svg)](https://greenkeeper.io/)
87

98
## Installation
109
This requires you to have Git and Node.js installed.

package.json

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -25,27 +25,26 @@
2525
},
2626
"devDependencies": {
2727
"adm-zip": "0.4.7",
28-
"babel-eslint": "7.0.0",
29-
"copy-webpack-plugin": "3.0.1",
30-
"eslint": "3.8.1",
31-
"eslint-config-scratch": "^2.0.0",
28+
"babel-eslint": "7.1.1",
29+
"copy-webpack-plugin": "4.0.1",
30+
"eslint": "3.15.0",
31+
"eslint-config-scratch": "^3.1.0",
3232
"expose-loader": "0.7.1",
33-
"gh-pages": "0.11.0",
34-
"highlightjs": "8.7.0",
35-
"htmlparser2": "3.9.0",
33+
"gh-pages": "0.12.0",
34+
"highlightjs": "9.8.0",
35+
"htmlparser2": "3.9.2",
3636
"json": "9.0.4",
37-
"json-loader": "0.5.4",
3837
"lodash.defaultsdeep": "4.6.0",
39-
"minilog": "3.0.1",
38+
"minilog": "3.1.0",
4039
"promise": "7.1.1",
4140
"scratch-audio": "latest",
4241
"scratch-blocks": "latest",
4342
"scratch-render": "latest",
4443
"script-loader": "0.7.0",
45-
"stats.js": "0.16.0",
46-
"tap": "5.7.1",
44+
"stats.js": "0.17.0",
45+
"tap": "10.0.2",
4746
"travis-after-all": "1.4.4",
48-
"webpack": "1.13.0",
49-
"webpack-dev-server": "1.14.1"
47+
"webpack": "2.2.1",
48+
"webpack-dev-server": "1.16.3"
5049
}
5150
}

src/blocks/scratch3_control.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ var Scratch3ControlBlocks = function (runtime) {
1111

1212
/**
1313
* Retrieve the block primitives implemented by this package.
14-
* @return {Object.<string, Function>} Mapping of opcode to Function.
14+
* @return {object.<string, Function>} Mapping of opcode to Function.
1515
*/
1616
Scratch3ControlBlocks.prototype.getPrimitives = function () {
1717
return {

src/blocks/scratch3_data.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var Scratch3DataBlocks = function (runtime) {
1010

1111
/**
1212
* Retrieve the block primitives implemented by this package.
13-
* @return {Object.<string, Function>} Mapping of opcode to Function.
13+
* @return {object.<string, Function>} Mapping of opcode to Function.
1414
*/
1515
Scratch3DataBlocks.prototype.getPrimitives = function () {
1616
return {

src/blocks/scratch3_event.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var Scratch3EventBlocks = function (runtime) {
1010

1111
/**
1212
* Retrieve the block primitives implemented by this package.
13-
* @return {Object.<string, Function>} Mapping of opcode to Function.
13+
* @return {object.<string, Function>} Mapping of opcode to Function.
1414
*/
1515
Scratch3EventBlocks.prototype.getPrimitives = function () {
1616
return {

src/blocks/scratch3_looks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var Scratch3LooksBlocks = function (runtime) {
1010

1111
/**
1212
* Retrieve the block primitives implemented by this package.
13-
* @return {Object.<string, Function>} Mapping of opcode to Function.
13+
* @return {object.<string, Function>} Mapping of opcode to Function.
1414
*/
1515
Scratch3LooksBlocks.prototype.getPrimitives = function () {
1616
return {

src/blocks/scratch3_motion.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ var Scratch3MotionBlocks = function (runtime) {
1212

1313
/**
1414
* Retrieve the block primitives implemented by this package.
15-
* @return {Object.<string, Function>} Mapping of opcode to Function.
15+
* @return {object.<string, Function>} Mapping of opcode to Function.
1616
*/
1717
Scratch3MotionBlocks.prototype.getPrimitives = function () {
1818
return {

src/blocks/scratch3_operators.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
var Cast = require('../util/cast.js');
2+
var MathUtil = require('../util/math-util.js');
23

34
var Scratch3OperatorsBlocks = function (runtime) {
45
/**
@@ -10,7 +11,7 @@ var Scratch3OperatorsBlocks = function (runtime) {
1011

1112
/**
1213
* Retrieve the block primitives implemented by this package.
13-
* @return {Object.<string, Function>} Mapping of opcode to Function.
14+
* @return {object.<string, Function>} Mapping of opcode to Function.
1415
*/
1516
Scratch3OperatorsBlocks.prototype.getPrimitives = function () {
1617
return {
@@ -126,9 +127,9 @@ Scratch3OperatorsBlocks.prototype.mathop = function (args) {
126127
case 'floor': return Math.floor(n);
127128
case 'ceiling': return Math.ceil(n);
128129
case 'sqrt': return Math.sqrt(n);
129-
case 'sin': return Math.sin((Math.PI * n) / 180);
130-
case 'cos': return Math.cos((Math.PI * n) / 180);
131-
case 'tan': return Math.tan((Math.PI * n) / 180);
130+
case 'sin': return parseFloat(Math.sin((Math.PI * n) / 180).toFixed(10));
131+
case 'cos': return parseFloat(Math.cos((Math.PI * n) / 180).toFixed(10));
132+
case 'tan': return MathUtil.tan(n);
132133
case 'asin': return (Math.asin(n) * 180) / Math.PI;
133134
case 'acos': return (Math.acos(n) * 180) / Math.PI;
134135
case 'atan': return (Math.atan(n) * 180) / Math.PI;

src/blocks/scratch3_pen.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ Scratch3PenBlocks.prototype._wrapHueOrShade = function (value) {
163163

164164
/**
165165
* Retrieve the block primitives implemented by this package.
166-
* @return {Object.<string, Function>} Mapping of opcode to Function.
166+
* @return {object.<string, Function>} Mapping of opcode to Function.
167167
*/
168168
Scratch3PenBlocks.prototype.getPrimitives = function () {
169169
return {

src/blocks/scratch3_procedures.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ var Scratch3ProcedureBlocks = function (runtime) {
88

99
/**
1010
* Retrieve the block primitives implemented by this package.
11-
* @return {Object.<string, Function>} Mapping of opcode to Function.
11+
* @return {object.<string, Function>} Mapping of opcode to Function.
1212
*/
1313
Scratch3ProcedureBlocks.prototype.getPrimitives = function () {
1414
return {

0 commit comments

Comments
 (0)