#include <iostream> #include "minecraft.h" using namespace std; TxMinecraft mc; void set1(int x,int y,int z){ mc.drawLine(x+1+1,y,z,x+2+1,y,z,143,3); mc.drawLine(x+4+1,y,z,x+5+1,y,z,143,3); mc.drawLine(x+7+1,y,z,x+8+1,y,z,143,3); mc.drawLine(x+1,y,z,x+9+1,y,z,101,0); } void set2(int x,int y,int z){ mc.drawLine(x+1+1,y,z,x+2+1,y,z,251,15); mc.drawLine(x+4+1,y,z,x+5+1,y,z,251,15); mc.drawLine(x+7+1,y,z,x+8+1,y,z,251,15); mc.setBlock(x+9+1,y+1,z,251,15); mc.drawLine(x+1+1,y,z,x+7+1,y,z,67,6); mc.setBlock(x+1,y,z,114,4); mc.setBlock(x+3+1,y,z,44,0); mc.setBlock(x+6+1,y,z,44,0); mc.setBlock(x+7+1,y+2,z,44,0); mc.setBlock(x+8+1,y+2,z,44,0); mc.setBlock(x,y+1,z,167,6); mc.setBlock(x+1,y+1,z,1,0); mc.setBlock(x+8+1,y+1,z,67,15); mc.setBlock(x+9+1,y,z,114,5); mc.setBlock(x+10+1,y,z,65,4); mc.setBlock(x+1,y+2,z,151,0); mc.setBlock(x+2,y+2,z,151,0); mc.drawLine(x+3,y+2,z,x+4,y+2,z,167,0); mc.setBlock(x+10,y+2,z,151,0); mc.setBlock(x+4+1,y+2,z,67,0); mc.drawLine(x+5+1,y+2,z,x+6+1,y+2,z,67,2); mc.drawLine(x+7+1,y+2,z,x+8+1,y+2,z,44,0); mc.setBlock(x+9+1,y+2,z,167,0); mc.drawLine(x+3+1,y+3,z,x+5+1,y+3,z,139,1); } void set3(){ //1 0 mc.setBlock(x+3+1,y,z,1,0); mc.setBlock(x+6+1,y,z,1,0); mc.setBlock(x+1,y+1,z,1,0); mc.setBlock(x+9+1,y+1,z,1,0); mc.drawLine(x+4+1,y+3,z,x+6+1,y+3,z,1,0); mc.setBlock(x+4+1,y+2,z,1,0); //44 8 mc.setBlock(x+1,y,z,44,8); mc.setBlock(x+9+1,y,z,44,8); mc.setBlock(x+5+1,y+2,z,44,8); mc.setBlock(x+6+1,y+2,z,44,8); //139 1 mc.drawLine(x,y+1,z,x,y+2,z,139,1); mc.setBlock(x+3+1,y+3,z,139,1); mc.setBlock(x+7+1,y+3,z,139,1); //101 0 mc.setBlock(x+10+1,y+1,z,101,0); //67 2 mc.drawLine(x+1+1,y+2,z,x+2+1,y+2,z,67,2); //44 0 mc.setBlock(x+3+1,y+2,z,44,0); mc.setBlock(x+8+1,y+2,z,44,0); mc.setBlock(x+4+1,y+4,z,44,0); //171 8 mc.setBlock(x+9+1,y+2,z,171,8); //67 1 mc.setBlock(x+7+1,y+2,z,67,1); } void set4(){ //44 0 mc.drawLine(x,y+2,z,x+2+1,y+2,z,44,0); mc.drawLine(x+8+1,y+3,z,x+14+1,y+3,z,44,0); mc.setBlock(x+7+1,y+2,z,44,0); //44 8 mc.setBlock(x,y,z,44,8); mc.setBlock(x+8+1,y,z,44,8); mc.drawLine(x+4+1,y+2,z,x+5+1,y+2,z,44,8); //1 0 mc.setBlock(x+2+1,y,z,1,0); mc.setBlock(x+5+1,y,z,1,0); mc.setBlock(x,y+1,z,1,0); mc.setBlock(x+8+1,y+1,z,1,0); mc.setBlock(x+3+1,y+2,z,1,0); mc.setBlock(x+6+1,y+2,z,1,0); mc.drawLine(x+3+1,y+3,z,x+5+1,y+3,z,1,0); //139 1 mc.setBlock(x+2+1,y+3,z,1,0); } int main() { bool con = mc.ConnectMinecraft("zk","4cd7d6e558c943c397a3a5243fa78e19"); if(!con){ cout<<"连接失败"<<endl; } mc.setPlayerFly("wangyihang"); int x,y,z; cin>>x>>y>>z; set1(x,y,z); z++; set2(x,y,z); z++; set3(x,y,z); z++; set4(x,y,z); z++; set3(x,y,z); z++; set2(x,y,z); z++; set1(x,y,z); return 0; }
标签:mc,drawLine,44,int,setBlock,111,67 From: https://www.cnblogs.com/wangyihang-xh/p/18047835