{"id":696,"date":"2018-08-06T17:49:15","date_gmt":"2018-08-06T15:49:15","guid":{"rendered":"https:\/\/www.mineprogramming.org\/?p=696"},"modified":"2018-08-06T17:51:19","modified_gmt":"2018-08-06T15:51:19","slug":"item-animation","status":"publish","type":"post","link":"https:\/\/mineprogramming.org\/en\/item-animation\/","title":{"rendered":"\u0414\u0435\u043b\u0430\u0435\u043c \u0442\u0430\u0440\u0435\u043b\u043a\u0443"},"content":{"rendered":"<p>\u0410\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430<br \/>\n\u0412\u0441\u0435\u043c \u043f\u0440\u0438\u0432\u0435\u0442, \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0442\u0430\u0440\u0435\u043b\u043a\u0438 \u0438\u0437 SlePE Furniture.<br \/>\n<img loading=\"lazy\" class=\"alignnone size-medium wp-image-701\" src=\"https:\/\/www.mineprogramming.org\/wp-content\/uploads\/2018\/08\/C6Bbi6BI2LQ-300x211.jpg\" alt=\"\" width=\"300\" height=\"211\" srcset=\"https:\/\/mineprogramming.org\/wp-content\/uploads\/2018\/08\/C6Bbi6BI2LQ-300x211.jpg 300w, https:\/\/mineprogramming.org\/wp-content\/uploads\/2018\/08\/C6Bbi6BI2LQ-768x540.jpg 768w, https:\/\/mineprogramming.org\/wp-content\/uploads\/2018\/08\/C6Bbi6BI2LQ-1024x721.jpg 1024w, https:\/\/mineprogramming.org\/wp-content\/uploads\/2018\/08\/C6Bbi6BI2LQ.jpg 1080w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><br \/>\n<!--more--><br \/>\n\u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430, \u043a\u0430\u043a \u0432\u0441\u0435\u0433\u0434\u0430, \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0431\u043b\u043e\u043a \u0441 \u0440\u0435\u043d\u0434\u0435\u0440\u043e\u043c:<\/p>\n<pre lang=\"Javascript\">IDRegistry.genBlockID(\"plate\");\r\nBlock.createBlock(\"plate\", [{\r\n    name: \"Plate\",\r\n    texture: [\r\n        [\"qurtz_block\", 0]\r\n    ],\r\n    inCreative: true\r\n}]);\r\nTranslation.addTranslation(\"Plate\", {\r\n    ru: \"\u0422\u0430\u0440\u0435\u043b\u043a\u0430\"\r\n})\r\nRecipes.addShaped(\r\n    {id: BlockID.plate, count: 1, data: 0}, \r\n    [\"vvv\", \"qvq\", \"vqv\"], \r\n    [\"q\",406,0]\r\n);\r\nBlock.setShape(BlockID.plate,1\/8,0,1\/8,7\/8,1\/8,7\/8);<\/pre>\n<p>\u041c\u044b \u0441\u043e\u0437\u0434\u0430\u043b\u0438 \u0431\u043b\u043e\u043a \u0441 \u0438\u043c\u0435\u043d\u0435\u043c &#8220;Plate&#8221;, \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043b\u0438 \u0435\u043c\u0443 \u0442\u0435\u043a\u0441\u0442\u0443\u0440\u0443 \u043a\u0432\u0430\u0440\u0446\u0435\u0432\u043e\u0433\u043e \u0431\u043b\u043e\u043a\u0430, \u0434\u043e\u0431\u0430\u0432\u0438\u043b\u0438 \u043f\u0435\u0440\u0435\u0432\u043e\u0434, \u0440\u0435\u0446\u0435\u043f\u0442 \u0438\u0437 \u043a\u0443\u0441\u043e\u0447\u043a\u043e\u0432 \u043a\u0432\u0430\u0440\u0446\u0430 \u0438 \u0432\u0438\u0434\u0438\u043c\u044b\u0439 \u0440\u0435\u043d\u0434\u0435\u0440 \u0442\u0430\u0440\u0435\u043b\u043a\u0438.<br \/>\n\u0422\u0435\u043f\u0435\u0440\u044c \u044f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u044e\u0441\u044c \u043e\u0431\u044a\u044f\u0441\u043d\u0438\u0442\u044c, \u043a\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f. \u0421\u043e\u0437\u0434\u0430\u0451\u0442\u0441\u044f \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043f\u043e \u043a\u043e\u043e\u0440\u0434\u0438\u043d\u0430\u0442\u0430\u043c \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u043c \u0432 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u0445:<\/p>\n<pre lang=\"Javascript\">animation = new Animation.Item(x, y, z);<\/pre>\n<p>\u042d\u0442\u043e \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u0438 \u0438 \u0435\u0451 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0435<\/p>\n<pre lang=\"Javascript\">animation.describeItem({\r\n    id: id,\/\/\u0410\u0439\u0434\u0438 \u0430\u043d\u0438\u043c\u0438\u0440\u0438\u0443\u043c\u0435\u0433\u043e \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430, \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0440\u0430\u0432\u043d\u043e 0\r\n    count: count,\/\/\u041a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u043e\u0432\r\n    data: data,\/\/\u0414\u0430\u0442\u0430 \u0430\u043d\u0438\u043c\u0438\u0440\u0443\u0435\u043c\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430\r\n    size: 1,\/\/\u0420\u0430\u0437\u043c\u0435\u0440 \u0430\u043d\u0438\u043c\u0438\u0440\u0443\u0435\u043c\u043e\u0433\u043e \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 (\u0432 \u0431\u043b\u043e\u043a\u0430\u0445)\r\n});\r\nanimation.load();\/\/\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u0442 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e\r\n<\/pre>\n<p>\u042d\u0442\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u0442, \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u0430 \u043b\u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f<\/p>\n<pre lang=\"Javascript\">animation.isLoaded\/\/true \u0435\u0441\u043b\u0438 \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u0430, false \u0435\u0441\u043b\u0438 \u043d\u0435\u0442<\/pre>\n<p>\u0410 \u044d\u0442\u043e, \u0440\u0430\u0437\u0440\u0443\u0448\u0430\u0435\u0442 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e.<\/p>\n<pre lang=\"Javascript\">animation.destroy();<\/pre>\n<p>\u0421\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0442\u0430\u0440\u0435\u043b\u043a\u0435 Tile Entity \u0441 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 init \u2013 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 Tile Entity, tick \u2013 1 \u0440\u0430\u0437 \u0432 \u0442\u0438\u043a, click \u2013 \u043f\u0440\u0438 \u043a\u043b\u0438\u043a\u0435 \u043f\u043e \u0442\u0430\u0440\u0435\u043b\u043a\u0435, defaultValues \u2013 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0434\u043b\u044f Tile Entity \u0438 animationSet \u2013 \u0441\u0432\u043e\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0440\u0435\u043d\u0434\u0435\u0440.<br \/>\n\u0412 defaultValues \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 id \u0438 \u0434\u0430\u0442\u0430, \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0431\u0443\u0434\u0435\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u0441\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043b\u0435\u0436\u0438\u0442 \u0432 \u0442\u0430\u0440\u0435\u043b\u043a\u0435:<\/p>\n<pre lang=\"Javascript\">defaultValues: {\r\n    id:0,\r\n    data:0\r\n},<\/pre>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0441\u0430\u043c\u043e\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u0435 \u2013 \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0440\u0435\u043d\u0434\u0435\u0440\u0430.<\/p>\n<pre lang=\"Javascript\">animationSet:function(){\r\n    this.animation = this.animation||new Animation.Item(this.x+.5, this.y+2.5\/16, this.z+.5);\/\/\u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e, \u0435\u0441\u043b\u0438 \u043e\u043d\u0430 \u0435\u0449\u0451 \u043d\u0435 \u0441\u043e\u0437\u0434\u0430\u043d\u0430.\r\n    if(this.data.id>0){\/\/\u0435\u0441\u043b\u0438 \u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u043d\u0435 \u0432\u043e\u0437\u0434\u0443\u0445\r\n        this.animation.describeItem({\r\n              id: this.data.id,\r\n              count: 1,\r\n              data: this.data.data,\r\n              size: .5,\r\n        });\/\/\u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u0445\u0440\u0430\u043d\u044f\u0449\u0435\u0433\u043e\u0441\u044f \u0432 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 tile entity\r\n        if(!this.animation.isLoaded){\/\/\u0435\u0441\u043b\u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043d\u0435 \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u0430, \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u0435\u0451.\r\n              this.animation.load();\r\n        }\r\n     }else{\r\n          if(this.animation.isLoaded)this.animation.destroy();\/\/\u0435\u0441\u043b\u0438 \u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u0432\u043e\u0437\u0434\u0443\u0445 \u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u0430, \u0442\u043e \u0443\u043d\u0438\u0447\u0442\u043e\u0436\u0438\u0442\u044c \u0435\u0451.\r\n     }\r\n},<\/pre>\n<p>\u041f\u0440\u0438 \u043b\u043e\u043c\u0430\u043d\u0438\u0438 \u0442\u0430\u0440\u0435\u043b\u043a\u0438 \u0443\u0434\u0430\u043b\u044f\u0435\u043c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e, \u043d\u043e \u043f\u0435\u0440\u0435\u0434 \u044d\u0442\u0438\u043c, \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0435\u0451 \u0438 \u0435\u0441\u043b\u0438 \u043e\u043d\u0430 \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0430, \u0434\u0440\u043e\u043f\u043d\u0443\u0442\u044c \u043f\u0440\u0435\u0434\u043c\u0435\u0442:<\/p>\n<pre lang=\"Javascript\">destroy:function(){\r\n     if(this.animation.isLoaded)this.animation.destroy();\/\/\u0435\u0441\u043b\u0438 \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u0437\u0430\u0433\u0440\u0443\u0436\u0435\u043d\u0430, \u0443\u043d\u0438\u0447\u0442\u043e\u0436\u0438\u0442\u044c \u0435\u0451\r\n     if(this.data.id!=0)World.drop(this.x+.5, this.y+0.25, this.z+.5, this.data.id, 1, this.data.data);\/\/\u0435\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u0434\u0440\u043e\u043f\u043d\u0443\u0442\u044c \u0435\u0433\u043e\r\n\t},<\/pre>\n<p>\u041f\u0440\u0438 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 Tile Entity \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e, \u043f\u0440\u0438\u0441\u0432\u043e\u0438\u043c \u0435\u0451 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u0440\u0435\u043d\u0434\u0435\u0440 \u0441\u0432\u043e\u0435\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439.<\/p>\n<pre lang=\"Javascript\">init:function(){\r\n    this.animation = new Animation.Item(this.x+.5, this.y+2.5\/16, this.z+.5);\r\n    this.animationSet();\r\n},<\/pre>\n<p>\u041f\u0440\u0438 \u043a\u043b\u0438\u043a\u0435 \u043c\u044b \u0434\u0440\u043e\u043f\u043d\u0435\u043c \u043f\u0440\u0435\u0434\u043c\u0435\u0442, \u0435\u0441\u043b\u0438 \u043e\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442\u0441\u044f \u0432 \u0442\u0430\u0440\u0435\u043b\u043a\u0435, \u0435\u0441\u043b\u0438 \u0443 \u0438\u0433\u0440\u043e\u043a\u0430 \u0440\u0443\u043a\u0430 \u043d\u0435 \u043f\u0443\u0441\u0442\u0430\u044f, \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u0440\u0435\u043d\u0434\u0435\u0440\u0443\u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u0438 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u043c \u0435\u0433\u043e, \u0435\u0441\u043b\u0438 \u0440\u0443\u043a\u0430 \u043f\u0443\u0441\u0442\u0430, \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0435 \u0430\u0439\u0434\u0438 \u0438 \u0434\u0430\u0442\u0443 \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u0440\u0430\u0432\u043d\u044b\u043c\u0438 0 \u0438 \u0443\u0434\u0430\u043b\u0438\u043c \u0440\u0435\u043d\u0434\u0435\u0440, \u0435\u0441\u043b\u0438 \u043e\u043d \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442.<\/p>\n<pre lang=\"Javascript\">click:function(){\r\n    if(this.data.id!=0){\/\/\u0435\u0441\u043b\u0438 \u043f\u0440\u0435\u0434\u043c\u0435\u0442 \u0432 \u0442\u0430\u0440\u0435\u043b\u043a\u0435 \u0435\u0441\u0442\u044c, \u0434\u0440\u043e\u043f\u043d\u0443\u0442\u044c \u0435\u0433\u043e\r\n        World.drop(this.x+.5, this.y+0.25, this.z+.5, this.data.id, 1, this.data.data);\r\n    }\r\n    this.data.id=Player.getCarriedItem().id;\/\/\u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0441 \u0430\u0439\u0434\u0438 \u0438 \u0434\u0430\u0442\u043e\u0439 \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430\r\n    this.data.data=Player.getCarriedItem().data;\r\n    Player.decreaseCarriedItem(1);\/\/\u043e\u0442\u043d\u044f\u0442\u044c 1 \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0438\r\n    Game.prevent();\/\/\u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435, \u043d\u0430 \u0441\u043b\u0443\u0447\u0430\u0439 \u0435\u0441\u043b\u0438 \u0432 \u0440\u0443\u043a\u0430\u0445 \u0443 \u0438\u0433\u0440\u043e\u043a\u0430 \u0431\u043b\u043e\u043a\r\n    this.animationSet();\/\/\u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e.\r\n}<\/pre>\n<p>\u0412\u043e\u0442 \u0438 \u0432\u0441\u0451, \u0432\u0435\u0441\u044c \u043a\u043e\u0434 \u043d\u0438\u0436\u0435.<\/p>\n<pre lang=\"Javascript\">IDRegistry.genBlockID(\"plate\");\r\nBlock.createBlock(\"plate\", [{\r\n    name: \"Plate\",\r\n    texture: [\r\n        [\"qurtz_block\", 0]\r\n    ],\r\n    inCreative: true\r\n}]);\r\nTranslation.addTranslation(\"Plate\", {\r\n    ru: \"\u0422\u0430\u0440\u0435\u043b\u043a\u0430\"\r\n})\r\nRecipes.addShaped({\r\n        id: BlockID.plate,\r\n        count: 1,\r\n        data: 0\r\n    },\r\n    [\"vvv\", \"qvq\", \"vqv\"],\r\n    [\"q\", 406, 0]);\r\nBlock.setShape(BlockID.plate, 1 \/ 8, 0, 1 \/ 8, 7 \/ 8, 1 \/ 8, 7 \/ 8);\r\n\r\nvar render = new ICRender.Model();\r\nBlockRenderer.setStaticICRender(BlockID.plate, 0, render);\r\nvar model = BlockRenderer.createModel();\r\nmodel.addBox(2 \/ 8, 0, 2 \/ 8, 6 \/ 8, 1 \/ 16, 6 \/ 8, 155, 0);\r\nmodel.addBox(1 \/ 8, 1 \/ 16, 1 \/ 8, 2 \/ 8, 1 \/ 8, 7 \/ 8, 155, 0);\r\nmodel.addBox(2 \/ 8, 1 \/ 16, 1 \/ 8, 6 \/ 8, 1 \/ 8, 2 \/ 8, 155, 0);\r\nmodel.addBox(6 \/ 8, 1 \/ 16, 1 \/ 8, 7 \/ 8, 1 \/ 8, 7 \/ 8, 155, 0);\r\nmodel.addBox(2 \/ 8, 1 \/ 16, 6 \/ 8, 6 \/ 8, 1 \/ 8, 7 \/ 8, 155, 0);\r\n\r\nrender.addEntry(model);\r\nTileEntity.registerPrototype(BlockID.plate, {\r\n    defaultValues: {\r\n        id: 0,\r\n        data: 0\r\n    },\r\n    destroy: function() {\r\n        if (this.animation.isLoaded) this.animation.destroy();\r\n        if (this.data.id != 0) World.drop(this.x + .5, this.y + 0.25, this.z + .5, this.data.id, 1, this.data.data);\r\n    },\r\n    init: function() {\r\n        this.animation = new Animation.Item(this.x + .5, this.y + 2.5 \/ 16, this.z + .5);\r\n        this.animationSet();\r\n    },\r\n    animationSet: function() {\r\n        this.animation = this.animation || new Animation.Item(this.x + .5, this.y + 2.5 \/ 16, this.z + .5);\r\n        if (this.data.id > 0) {\r\n            this.animation.describeItem({\r\n                id: this.data.id,\r\n                count: 1,\r\n                data: this.data.data,\r\n                size: .5,\r\n            });\r\n            this.animation.setPos(this.x + .57, this.y + 0.20, this.z + .43);\r\n            if (!this.animation.isLoaded) {\r\n                this.animation.load();\r\n            }\r\n        } else {\r\n            if (this.animation.isLoaded) this.animation.destroy();\r\n        }\r\n    },\r\n    click: function() {\r\n        if (this.data.id != 0) {\r\n            World.drop(this.x + .5, this.y + 0.25, this.z + .5, this.data.id, 1, this.data.data);\r\n        }\r\n        this.data.id = Player.getCarriedItem().id;\r\n        this.data.data = Player.getCarriedItem().data;\r\n        Player.decreaseCarriedItem(1);\r\n        Game.prevent();\r\n        this.animationSet();\r\n    } else {\r\n        this.data.id = 0;\r\n        this.data.data = 0;\r\n        if (this.animation.isLoaded) this.animation.destroy();\r\n    }\r\n});\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u0410\u043d\u0438\u043c\u0430\u0446\u0438\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u0412\u0441\u0435\u043c \u043f\u0440\u0438\u0432\u0435\u0442, \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0430\u043d\u0438\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u043c\u0435\u0442\u0430 \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0442\u0430\u0440\u0435\u043b\u043a\u0438 \u0438\u0437 SlePE Furniture.<\/p>\n","protected":false},"author":6,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[13],"tags":[],"translation":{"provider":"WPGlobus","version":"2.6.8","language":"en","enabled_languages":["ru","en"],"languages":{"ru":{"title":true,"content":true,"excerpt":false},"en":{"title":false,"content":false,"excerpt":false}}},"_links":{"self":[{"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/posts\/696"}],"collection":[{"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/comments?post=696"}],"version-history":[{"count":8,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/posts\/696\/revisions"}],"predecessor-version":[{"id":706,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/posts\/696\/revisions\/706"}],"wp:attachment":[{"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/media?parent=696"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/categories?post=696"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mineprogramming.org\/en\/wp-json\/wp\/v2\/tags?post=696"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}