{"id":822,"date":"2021-02-24T01:40:31","date_gmt":"2021-02-24T01:40:31","guid":{"rendered":"https:\/\/help.mytsi.org\/?post_type=ht_kb&amp;p=793"},"modified":"2021-02-24T01:40:31","modified_gmt":"2021-02-24T01:40:31","slug":"coblocks","status":"publish","type":"ht_kb","link":"https:\/\/help.mytsi.org\/v2\/knowledge-base\/coblocks\/","title":{"rendered":"CoBlocks"},"content":{"rendered":"<p>CoBlocks is a\u00a0<b>visual coding language\u00a0<\/b>that lets you simply drag and drop\u00a0<b>CoBlocks<\/b><\/p>\n<p>(blocks of code) to program your CoSpace.<\/p>\n<p>A CoBlock represents a snippet of code, or\u00a0<b>statement<\/b>, which tells CoSpaces Edu to do something like starting a specific action in your scene.<\/p>\n<p><img src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_102.jpg\" alt=\"image\" \/><\/p>\n<p><span class=\"p\">You can find the\u00a0<\/span><span class=\"s13\">Code<\/span><span class=\"p\">\u00a0icon in the top-right toolbar.<\/span><\/p>\n<p><span class=\"p\">To open the CoBlocks coding editor, click the\u00a0<\/span><span class=\"s13\">CoBlocks<\/span><span class=\"p\">\u00a0icon.<\/span><\/p>\n<p><img src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_103.jpg\" alt=\"image\" \/><\/p>\n<p>The empty space on the right side is the<\/p>\n<p class=\"s12\">CoBlocks workspace<span class=\"p\">.<\/span><\/p>\n<p>The list of CoBlocks on the left side is the<\/p>\n<p class=\"s12\">CoBlocks toolbox<span class=\"p\">.<\/span><\/p>\n<p><img src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_104.png\" alt=\"image\" \/><\/p>\n<p>To program an item with CoBlocks, enable its use in CoBlocks.<\/p>\n<p><span class=\"p\">To do this, select the object you would like to use in your code, click\u00a0<\/span><span class=\"s13\">Code<\/span><span class=\"p\">, and enable\u00a0<\/span><span class=\"s13\">Use in CoBlocks<\/span><span class=\"p\">.<\/span><\/p>\n<p>There are 2 main types of CoBlocks:\u00a0<b>Expression\u00a0<\/b>and\u00a0<b>Statement\u00a0<\/b>CoBlocks:<\/p>\n<h1 class=\"s10\"><strong>Statement CoBlocks<\/strong><\/h1>\n<p><span class=\"p\">Statement CoBlocks often perform a specific\u00a0<\/span><span class=\"s12\">action<\/span><span class=\"p\">. For example, you can make an item talk, using the\u00a0<\/span><span class=\"s13\">say<\/span><span class=\"p\">\u00a0CoBlock.<\/span><\/p>\n<p><img src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_105.jpg\" alt=\"image\" \/><\/p>\n<h1 class=\"s10\"><strong>Expression CoBlocks<\/strong><\/h1>\n<p>Expression CoBlocks contain\u00a0<b>values<\/b>. These values can be:<\/p>\n<p class=\"s17\">\u25cf\u00a0<span class=\"p\">Colors (red, green, blue)<\/span><\/p>\n<p class=\"s17\">\u25cf\u00a0<span class=\"p\">Numbers like 5 and 0.25<\/span><\/p>\n<p class=\"s17\">\u25cf\u00a0<span class=\"p\">Strings like &#8220;Hi there!&#8221;<\/span><\/p>\n<p class=\"s17\">\u25cf\u00a0<span class=\"p\">Other items in the scene<\/span><\/p>\n<p><img loading=\"lazy\" src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_106.png\" alt=\"image\" width=\"202\" height=\"47\" \/><\/p>\n<p>Expression CoBlocks can be recognized by their round shape and are always placed into other CoBlocks:<\/p>\n<p><img loading=\"lazy\" src=\"http:\/\/droplet.webguyzcloud.com\/cospaces\/CoSpaces-Edu-Pro-Guide_files\/Image_107.jpg\" alt=\"image\" width=\"427\" height=\"139\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>CoBlocks is a\u00a0visual coding language\u00a0that lets you simply drag and drop\u00a0CoBlocks (blocks of code) to program your CoSpace. A CoBlock represents a snippet of code, or\u00a0statement, which tells CoSpaces Edu to do something like starting a specific action in your scene. You can find the\u00a0Code\u00a0icon in the top-right toolbar. To&#8230;<\/p>\n","protected":false},"author":2,"comment_status":"open","ping_status":"closed","template":"","format":"standard","meta":[],"ht-kb-category":[192],"ht-kb-tag":[191],"_links":{"self":[{"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/ht-kb\/822"}],"collection":[{"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/ht-kb"}],"about":[{"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/types\/ht_kb"}],"author":[{"embeddable":true,"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/comments?post=822"}],"version-history":[{"count":0,"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/ht-kb\/822\/revisions"}],"wp:attachment":[{"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/media?parent=822"}],"wp:term":[{"taxonomy":"ht_kb_category","embeddable":true,"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/ht-kb-category?post=822"},{"taxonomy":"ht_kb_tag","embeddable":true,"href":"https:\/\/help.mytsi.org\/v2\/wp-json\/wp\/v2\/ht-kb-tag?post=822"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}