@@ -1666,40 +1666,46 @@ export default {
1666
1666
};
1667
1667
1668
1668
1669
- Blockly .Blocks [' coderbot_music_note_sol ' ] = {
1669
+ Blockly .Blocks [' coderbot_music_note_basic ' ] = {
1670
1670
init : function () {
1671
1671
this .appendDummyInput ()
1672
- .appendField (new Blockly.FieldImage (" https://www.gstatic.com/codesite/ph/images/s tar_on.gif" , 30 , 30 , " 25" ));
1673
- this .appendDummyInput ()
1674
- .setAlign (Blockly .ALIGN_CENTRE )
1675
- .appendField (" SOL" );
1672
+ .appendField (new Blockly.FieldImage (" https://svgsilh.com/svg/1314943.svg" , 30 , 30 , " 25" ));
1673
+ .appendField (" DO " );
1676
1674
this .setPreviousStatement (true , null );
1677
1675
this .setNextStatement (true , null );
1678
- this .setColour (230 );
1679
- this .setTooltip (" nota SOL " );
1676
+ this .setColour (345 );
1677
+ this .setTooltip (" nota DO " );
1680
1678
this .setHelpUrl (" " );
1681
1679
}
1682
1680
};
1683
1681
1682
+ // .setAlign(Blockly.ALIGN_CENTRE)
1684
1683
1685
- Blockly .Python [' coderbot_music_note_sol' ] = {
1684
+ Blockly .Python [' coderbot_music_note_sol' ] = function ( block ) {
1686
1685
// TODO: Assemble Python into code variable.
1687
- var code = ' get_music().play_note("A2" )\n ' ;
1686
+ var code = ' get_music().play_note(A2 )\n ' ;
1688
1687
return code;
1689
1688
1690
1689
};
1691
1690
1692
- Blockly .Blocks [' coderbot_animal_verse ' ] = {
1691
+ Blockly .Blocks [' coderbot_animal_verse_basic ' ] = {
1693
1692
init : function () {
1694
1693
this .appendDummyInput ()
1695
1694
.appendField (new Blockly.FieldImage (" https://upload.wikimedia.org/wikipedia/commons/7/71/Paw_%28Animal_Rights_symbol%29.svg" , 15 , 15 , { alt: " *" , flipRtl: " FALSE" }))
1696
1695
.appendField (" Verso del" )
1697
1696
.appendField (new Blockly.FieldDropdown ([[" Gatto" ," cat" ], [" Cane" ," dog" ]]), " Verso del" );
1698
- this .setColour (345 );
1697
+ this .setColour (290 );
1699
1698
this .setTooltip (" Verso animale" );
1700
1699
this .setHelpUrl (" " );
1701
1700
}
1702
1701
};
1702
+
1703
+ Blockly .Python [' coderbot_animal_verse_basic' ] = function (block ) {
1704
+ var dropdown_verso_del = block .getFieldValue (' Verso del' );
1705
+ // TODO: Assemble Python into code variable.
1706
+ var code = ' ...\n ' ;
1707
+ return code;
1708
+ };
1703
1709
1704
1710
Blockly .Python [' coderbot_audio_listen' ] = function (block ) {
1705
1711
// Boolean values true and false.
0 commit comments