Skip to content

Commit

Permalink
Merge pull request #49009 from code-dot-org/dts_candidate_2022-11-04
Browse files Browse the repository at this point in the history
DTS (Levelbuilder > Staging) [robo-dts]
  • Loading branch information
deploy-code-org committed Nov 4, 2022
2 parents 74cc67b + e05d05f commit 1e4c704
Show file tree
Hide file tree
Showing 170 changed files with 26,583 additions and 5,434 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addEightBlock() {
input = input + 8;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addEightBlock",
"blockText": "addEight",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addFiveBlock() {
input = input + 5;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addFiveBlock",
"blockText": "addFive",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addFourBlock() {
input = input + 4;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addFourBlock",
"blockText": "addFour",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addNineBlock() {
input = input + 9;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addNineBlock",
"blockText": "addNine",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addOneBlock() {
input = input + 1;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addOneBlock",
"blockText": "addOne",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addSevenBlock() {
input = input + 7;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addSevenBlock",
"blockText": "addSeven",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addSixBlock() {
input = input + 6;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addSixBlock",
"blockText": "addSix",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addThreeBlock() {
input = input + 3;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addThreeBlock",
"blockText": "addThree",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
function addTwoBlock() {
input = input + 2;
output = input;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"category": "Experimental",
"config": {
"color": [
120,
0.6,
0.6
],
"func": "addTwoBlock",
"blockText": "addTwo",
"args": [

],
"eventBlock": false
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,30 @@ function representManipulative(var1, s1costume, behavior) {
//For ideal behavior: original sprites should be 40x40
//to create 10x10 grid for students

//destroy(({costume: s1costume}));
var spriteIds = getSpriteIdsInUse();
for(var i = 0; i < spriteIds.length; i++) {
var val = getProp(({id: spriteIds[i]}), "isManipulative");
if(val == 47) {
destroy(({id: spriteIds[i]}));
}
}


var x = 20;
var y = 400-20;
for (counter_i = 0; counter_i < var1; counter_i++) {
createNewSprite({name: "manipulative" + counter_i}, s1costume, {"x": x, "y": y});
var spriteId = createNewSprite({name: "manipulative" + counter_i}, s1costume, {"x": x, "y": y});
setProp(({id: spriteId}), "isManipulative", 47);
//makeNewSpriteAnon(s1costume, {"x": x, "y": y});
console.log();
x += 40;
if(x >= 400) {
x = 20;
y += 40;
}
addBehaviorSimple(({id: spriteId}), new Behavior(northAndStop, []));
}
addBehaviorSimple(({costume: s1costume}), new Behavior(northAndStop, []));
}

function northAndStop(this_sprite) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,30 @@ function representManipulative_test(var1, s1costume, behavior) {
//For ideal behavior: original sprites should be 40x40
//to create 10x10 grid for students

//destroy(({costume: s1costume}));
var spriteIds = getSpriteIdsInUse();
for(var i = 0; i < spriteIds.length; i++) {
var val = getProp(({id: spriteIds[i]}), "isManipulative");
if(val == 47) {
destroy(({id: spriteIds[i]}));
}
}


var x = 20;
var y = 400-20;
for (counter_i = 0; counter_i < var1; counter_i++) {
createNewSprite({name: "manipulative" + counter_i}, s1costume, {"x": x, "y": y});
var spriteId = createNewSprite({name: "manipulative" + counter_i}, s1costume, {"x": x, "y": y});
setProp(({id: spriteId}), "isManipulative", 47);
//makeNewSpriteAnon(s1costume, {"x": x, "y": y});
console.log();
x += 40;
if(x >= 400) {
x = 20;
y += 40;
}
addBehaviorSimple(({id: spriteId}), new Behavior(northAndStop, []));
}
addBehaviorSimple(({costume: s1costume}), new Behavior(northAndStop, []));
}

function northAndStop(this_sprite) {
Expand Down

0 comments on commit 1e4c704

Please sign in to comment.