#include <iostream> #include <string> #include "minecraft.h" using namespace std; TxMinecraft mc; int main(int argc, char** argv) { bool con = mc.ConnectMinecraft("tk.makeblock.net.cn","4cd7d6e558c943c397a3a5243fa78e19"); if(!con){ cout<<"连接失败"; } int x = -151; int y = 5; int z = -356; int id = 251; int data = 1; for(int i=0;i<16;i++){ mc.drawLine(x+i,y+20,z,x+i,y+12,z,id,data); } for(int i=4;i<12;i++){ mc.drawLine(x+i,y,z,x+i,y+1,z,id,data); } data = 2; for(int i=0;i<16;i++){ mc.drawLine(x+i,y+24,z,x+i,y+21,z,id,data); } for(int i=4;i<12;i++){ mc.drawLine(x+i,y+11,z,x+i,y+2,z,id,data); } data = 3; for(int i=4;i<12;i++){ mc.drawLine(x+i,y+24,z,x+i,y+12,z,id,data); } mc.drawLine(x+4,y+11,z,x+5,y+11,z,id,data); mc.setBlock(x+4,y+10,z,id,data); data = 2; for(int i=4;i<12;i++){ mc.drawLine(x+i,y+25,z,x+i,y+30,z,id,data); } mc.drawLine(x+6,y+24,z,x+9,y+24,z,id,data); mc.drawLine(x+7,y+23,z,x+8,y+23,z,id,data); data = 4; for(int i=4;i<12;i++){ mc.drawLine(x+i,y+31,z,x+i,y+32,z,id,data); } mc.setBlock(x+4,y+30,z,id,data); mc.setBlock(x+11,y+30,z,id,data); mc.drawLine(x+7,y+27,z,x+8,y+27,z,id,data); mc.drawLine(x+6,y+25,z,x+9,y+25,z,id,data); mc.setBlock(x+9,y+26,z,id,data); mc.setBlock(x+6,y+26,z,id,data); mc.drawLine(x+6,y+28,z,x+5,y+28,z,0,0); mc.drawLine(x+10,y+28,z,x+9,y+28,z,0,0); return 0; }
原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/288882.html