Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bloques faltantes #288

Merged
merged 2 commits into from
May 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 57 additions & 1 deletion locales/en-us/blocks.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,63 @@
"while": "Repeat until",
"chargerHere": "Is there a charger here?",
"trophyHere": "Is there a trophy here?",
"saladBowlHere": "Is there a salad bowl here?"
"saladBowlHere": "Is there a salad bowl here?",
"writeA": "Write 'A'",
"writeB": "Write 'B'",
"writeC": "Write 'C'",
"puddleHere": "Is there a puddle here?",
"write": "write",
"currentCharacter": "Is the current letter an ?'",
"takeTelescope": "Take telescope",
"turnComputerOff": "Turn the computer off",
"advance": "Move forward",
"move1Km": "Move 1 Km forward",
"putIntoTheTrashBin": "Put into the trash bin",
"countStar": "Count a star",
"countPlanet": "Count a planet",
"giveCharger": "Give charger and invite Yvoty",
"giveBall": "Give ball and take charger",
"giveTelescope": "Give telescope and take ball",
"writeLetter": "Write the letter I am touching",
"atTheSquare": "Am I in one corner?",
"atColumnEnd": "Am I at the end of the column?",
"atColumnBeginning": "Am I at the beginning of the column?",
"installGame": "Install the game",
"goInAlligator": "Go in alligator",
"kmToTravel": "Kilometers to travel",
"currentColumnLength": "Current column length",
"moveAndDrawDown": "Move down and draw",
"moveAndDrawUp": "Move up and draw",
"moveAndDrawRight": "Move right and draw",
"moveAndDrawLeft": "Move left and draw",
"moveTelescope": "Move telescope",
"lookWithFriends": "Look at the sky with friends",
"nextComputer": "next computer",
"turnComputerOn": "Turn computer on",
"bounceFootRubberBall": "Bounce with foot the rubber ball",
"pickRubberBall": "Pick the rubber ball",
"back": "Go back",
"volleyRubberBall": "Volley the rubber ball",
"jumpDown": "Jump down",
"jumpUp": "Jump up",
"jumpRight": "Jump right",
"jumpLeft": "Jump left",
"nextColumn": "Go to the next column",
"nextLine": "Go to the next line",
"moveNextTelescope": "Move to next telescope",
"pickBird": "Pick Guyrá",
"guyraHere": "Is Guyrá here?",
"atTheBeginning": "Am I at the beginning?",
"takeCan": "Tale a can",
"takePaper": "Take a paper",
"goToLeftBorder": "Go to left border",
"backToLeftBorder": "Get back to the left border",
"drawSide": "Draw a side of",
"writeAnotherText": "Write text in another cel",
"rotateGrades": "Rotate grades",
"isAVowel": "Is a vowel ?",
"repeatEmpty": "Repeat",
"JumpForward": "Jump forward"
},
"procedures": {
"definition": "Define",
Expand Down
58 changes: 57 additions & 1 deletion locales/es-ar/blocks.json
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,63 @@
"while": "Repetir hasta que",
"chargerHere": "¿Hay un cargador acá?",
"trophyHere": "¿Hay un trofeo acá?",
"saladBowlHere": "¿Hay una ensaladera acá?"
"saladBowlHere": "¿Hay una ensaladera acá?",
"writeA": "Escribir 'A'",
"writeB": "Escribir 'B'",
"writeC": "Escribir 'C'",
"puddleHere": "¿Hay un charco?",
"write": "Escribir:",
"currentCharacter": "¿La letra actual es una ?'",
"takeTelescope": "Agarrar telescopio",
"turnComputerOff": "Apagar computadora",
"advance": "Avanzar",
"move1Km": "Avanzar 1 Km",
"putIntoTheTrashBin": "Poner en el tacho",
"countStar": "Contar una estrella",
"countPlanet": "Contar un planeta",
"giveCharger": "Dar cargador e invitar a Yvoty",
"giveBall": "Dar pelota y agarrar cargador",
"giveTelescope": "Dar telescopio y agarrar pelota",
"writeLetter": "Escribir letra que estoy tocando",
"atTheSquare": "¿Estoy en una esquina?",
"atColumnEnd": "¿Estoy al final de la columna?",
"atColumnBeginning": "¿Estoy al inicio de la columna?",
"installGame": "Instalar juego",
"goInAlligator": "Irse en yacaré",
"kmToTravel": "Kilómetros a recorrer",
"currentColumnLength": "Largo de la columna actual",
"moveAndDrawDown": "Mover abajo dibujando",
"moveAndDrawUp": "Mover arriba dibujando",
"moveAndDrawRight": "Mover derecha dibujando",
"moveAndDrawLeft": "Mover izquierda dibujando",
"moveTelescope": "Mover telescopio",
"lookWithFriends": "Observar el cielo con amigos",
"nextComputer": "Próxima computadora",
"turnComputerOn": "Prender computador",
"bounceFootRubberBall": "Rebotar con el pie la pelota de goma",
"pickRubberBall": "Agarrar pelota de goma",
"back": "Retroceder",
"volleyRubberBall": "Lanzar al aire la pelota de goma",
"jumpDown": "Saltar abajo",
"jumpUp": "Saltar arriba",
"jumpRight": "Saltar derecha",
"jumpLeft": "Saltar izquierda",
"nextColumn": "Pasar a la siguiente columna",
"nextLine": "Pasar a la siguiente fila",
"moveNextTelescope": "Pasar al siguiente telescopio",
"pickBird": "Subir a Guyrá",
"guyraHere": "¿Guyrá está acá?",
"atTheBeginning": "¿Estoy al inicio?",
"takeCan": "Tomar lata",
"takePaper": "Tomar papel",
"goToLeftBorder": "Volver a borde izquierdo",
"backToLeftBorder": "Volver al borde izquierdo",
"drawSide": "Dibujar lado",
"writeAnotherText": "Escribir texto dado en otra cuadricula",
"rotateGrades": "Girar grados",
"isAVowel": "¿ Hay vocal ?",
"repeatEmpty": "Repetir",
"JumpForward": "Saltar hacia adelante"
},
"procedures": {
"definition": "Definir",
Expand Down
39 changes: 38 additions & 1 deletion locales/pt-br/blocks.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,44 @@
"while": "Repetir até que",
"chargerHere": "Há um cargador aqui?",
"trophyHere": "Há um troféu aqui?",
"saladBowlHere": "Há uma tigela de salada aqui?"
"saladBowlHere": "Há uma tigela de salada aqui?",
"drawSide": "Desenhar o lado de",
"turnComputerOff": "Apagar computador",
"advance": "Avançar",
"move1Km": "Avançar 1 Km",
"bounceFootRubberBall": "Chutar com ó pe uma bola de borracha",
"putIntoTheTrashBin": "colocar na lata de lixo",
"currentColumnLength": "Comprimento da coluna atual",
"countPlanet": "Contar um planeta",
"countStar": "Contar uma estrela",
"writeA": "Escrever 'A'",
"writeB": "Escrever 'B'",
"writeC": "Escrever 'C'",
"writeLetter": "Escrever a letra que estou tocando",
"atTheSquare": "Estou em uma esquina?",
"atTheBeginning": "Estou no começo?",
"atColumnEnd": "Estou no final da coluna?",
"atColumnBeginning": "Estou no inicio da coluna?",
"puddleHere": "Há uma poça?",
"installGame": "Instale jogo",
"nextColumn": "Ir para a linha anterior",
"nextLine": "Ir para a próxima linha",
"moveNextTelescope": "Ir para a próximo telescópio",
"volleyRubberBall": "Lançar ao ar a bola de borracha",
"moveAndDrawDown": "Mova para baixo desenhando",
"moveAndDrawRight": "Mover para a direita desenhando",
"moveAndDrawLeft": "Mover para a esquerda desenhando",
"moveAndDrawUp": "Mover para cima desenhando",
"moveTelescope": "Mover telescópio",
"pickRubberBall": "Pegar uma bola de borracha",
"lookWithFriends": "Perceber o céu com amigos",
"kmToTravel": "Quilômetros para viajar",
"jumpRight": "Saltar para a direita",
"jumpLeft": "Saltar para a esquerda",
"jumpDown": "Saltar para baixo",
"jumpUp": "Saltar para cima",
"goInAlligator": "Vai em jacaré",
"backToLeftBorder": "Voltar para a margem esquerda"
},
"procedures": {
"definition": "Definir",
Expand Down
58 changes: 58 additions & 0 deletions src/components/blockly/blockly.ts
Original file line number Diff line number Diff line change
Expand Up @@ -683,6 +683,24 @@ const createPrimitiveBlocks = (t: (key: string) => string) => {
}, 'icono.abajo.png'
);

createPrimitiveBlock('EscribirA', t("blocks.writeA"), {
'comportamiento': 'EscribirEnComputadora',
'argumentos': '{idTransicion: "escribirA"}',
}, 'icono.letter-a.svg'
);

createPrimitiveBlock('EscribirB', t("blocks.writeB"), {
'comportamiento': 'EscribirEnComputadora',
'argumentos': '{idTransicion: "escribirB"}',
}, 'icono.letter-b.svg'
);

createPrimitiveBlock('EscribirC', t("blocks.writeC"), {
'comportamiento': 'EscribirEnComputadora',
'argumentos': '{idTransicion: "escribirC"}',
}, 'icono.letter-c.svg'
);

createPrimitiveBlock('MoverA', t(`blocks.moveTo`), { 'comportamiento': '', 'argumentos': '{}' }, '',
{
message0: `${t(`blocks.moveTo`)} %1`,
Expand Down Expand Up @@ -765,6 +783,22 @@ const createPrimitiveBlocks = (t: (key: string) => string) => {
`
});

createPrimitiveBlock('EscribirTextoDadoEnOtraCuadricula', t(`blocks.write`), { 'comportamiento': '', 'argumentos': '{}' }, 'icono.DibujarLinea.png',
{
message0: `${t(`write`)}`,
colour: primitivesColor,
inputsInline: true,
previousStatement: true,
nextStatement: true,
args0: [
{
"type": "field_input",
"name": "texto",
"text": ""
}
],
code: 'hacer(actor_id, "EscribirTextoDadoEnOtraCuadricula", {texto: "texto"});'
});
}

const createSensorBlocks = (t: (key: string) => string) => {
Expand Down Expand Up @@ -986,6 +1020,30 @@ const createSensorBlocks = (t: (key: string) => string) => {
'funcionSensor': 'tocando("Trofeo")',
}, 'icono.trofeo.png'
);
createSensorBlock('HayCharco', t('blocks.puddleHere'), {
'funcionSensor': 'hayEnEscena("Charco")',
}, 'icono.charco.png'
);

createSensorBlock('HayVocalRMT', t('blocks.currentCharacter'), {
'funcionSensor': '{}',
}, 'icono.DibujarLinea.png',
{
message0: `${t(`blocks.currentCharacter`)}`,
colour: sensorsColor,
args0: [
{
"type": "field_dropdown",
"name": "letra",
"options": [
["R", "r"], ["M", "m"], ["T", "t"], ["A", "a"], ["E", "e"], ["I", "i"], ["O", "o"], ["U", "u"]
]
}
],
"output": null,
code: 'hacer(actor_id, "Rotar", {angulo: - ($grados), voltearAlIrAIzquierda: false, velocidad: 60});',
}
);
}

const createValueBlocks = (t: (key: string) => string) => {
Expand Down
Loading
Loading