X-Git-Url: https://deadsoftware.ru/gitweb?p=cavecraft.git;a=blobdiff_plain;f=src%2Fitems_logic.mpsrc;h=a0816c786b5cf4a569b16b157452430252312bb9;hp=d4900720c14ff97e92740b4079910d991620deb5;hb=13a872abec65a21544bfa928624c6bf3975fd50f;hpb=be17b532d3ef289fa455ba7be5ff8c25ad95a18d diff --git a/src/items_logic.mpsrc b/src/items_logic.mpsrc index d490072..a0816c7 100644 --- a/src/items_logic.mpsrc +++ b/src/items_logic.mpsrc @@ -231,7 +231,7 @@ procedure destroy_block_cr(id, xx, yy:integer); setmap(0,xx,yy); destsign(getmapinfo(xx,yy)); end; else - if id=106 then + if (id = 106) or (id = 125) then begin setmap(0,xx,yy); DestroyFurnace(xx, yy); @@ -266,7 +266,7 @@ procedure destroy_block_cr(id, xx, yy:integer); begin if createsign(xx,yy)=-1 then set_block_code:=true; end; else - if it=106 then + if (it = 106) or (it = 125) then begin if CreateFurnace(xx, yy)=FURNACE_ERROR then set_block_code:=true; @@ -338,7 +338,7 @@ procedure destroy_block_cr(id, xx, yy:integer); begin destsign(getmapinfo(xx,yy)); end; else - if id=106 then + if (id = 106) or (id = 125) then begin DestroyFurnace(xx, yy); end; else @@ -578,7 +578,7 @@ procedure destroy_block_cr(id, xx, yy:integer); destsign(getmapinfo(xx,yy)); drop.create(104,1,xx*16+4,yy*16+4); end; else - if id=106 then + if (id = 106) or (id = 125) then begin setmap(0,xx,yy); DestroyFurnace(xx, yy); @@ -680,7 +680,7 @@ procedure destroy_block_cr(id, xx, yy:integer); if block=104 then keymode:=5;*/ else - if block=106 then + if (block = 106) or (block = 125) then OpenFurnaceWindow(info); else if block=107 then @@ -1348,6 +1348,14 @@ procedure updateBlock(x, y:integer); create_particle(4, x*16+4, y*16+4); end; else + if (block = 106) or (block = 125) then + begin + if furnaceBurn(getMapInfo(x, y)) then + setmap(125, x, y); + else + setmap(106, x, y); + end; + else if block=110 then begin if (getmap(x-1, y)=0) or (getmap(x+1, y)=0) or (getmap(x, y-1)=0) or (getmap(x, y+1)=0) then