Translations:Modding:Adding Block Behavior/14/ru: Difference between revisions

From Vintage Story Wiki
(Created page with "// Можем ли мы разместить блок там? if (world.BlockAccessor.GetBlock(pos).IsReplacableBy(block)) { // Remove the block at the cur...")
 
(No difference)

Latest revision as of 12:36, 14 May 2020

// Можем ли мы разместить блок там? if (world.BlockAccessor.GetBlock(pos).IsReplacableBy(block))

       {
           // Remove the block at the current position and place it at the target position
           world.BlockAccessor.SetBlock(0, blockSel.Position);
           world.BlockAccessor.SetBlock(block.BlockId, pos);
       }