{"id":"xvyuub","deleted":false,"future_paste":false,"expired":false,"language":"cpp","created_at":"2025-09-24 05:30:00","expires_at":null,"content":"#include <bits\/stdc++.h>\r\nusing namespace std;\r\nint main(int argc, char** argv)\r\n{\r\n\tif (argc < 2) { std::cout << \"usage: \" << argv[0] << \" SECTORS.lmp\\n\"; return 1; }\r\n\tifstream file(argv[1]);\r\n\tfor (int i = 0; file.peek() != EOF; ++i)\r\n\t{\r\n\t\tstruct Sector {\r\n\t\t\tint16_t floor, ceil;\r\n\t\t\tchar floortex[8], ceiltex[8];\r\n\t\t\tint16_t light, special, tag;\r\n\t\t} sector;\r\n\t\tfile.read((char*)&sector, sizeof(Sector));\r\n\t\tcout << \"id: \" << i << \"\\t\"\r\n\t\t     << \"floor: \" << sector.floor << \"\\t\"\r\n\t\t     << \"ceil: \" << sector.ceil << \"\\t\"\r\n\t\t     << \"floortex: \" << sector.floortex << \"\\t\"\r\n\t\t     << \"ceiltex: \" << sector.ceiltex << \"\\t\"\r\n\t\t     << \"light: \" << sector.light << \"\\t\"\r\n\t\t     << \"special: \" << sector.special << \"\\t\"\r\n\t\t     << \"tag: \" << sector.tag << \"\\n\\n\";\r\n\t}\r\n\treturn 0;\r\n}"}