Differences From Artifact [f35a650122]:
- File
src/worldio.m
— part of check-in
[75e920ae30]
at
2025-03-29 14:25:43
on branch trunk
— Switch from clang-format to manual formatting
clang-format does too many weird things. (user: js, size: 10161) [annotate] [blame] [check-ins using]
To Artifact [3c6f02e0b1]:
- File src/worldio.m — part of check-in [c634a689e7] at 2025-03-29 17:13:40 on branch trunk — More style fixes (user: js, size: 10013) [annotate] [blame] [check-ins using]
︙ | |||
166 167 168 169 170 171 172 | 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 | - - + + | // run-length encoding and leaves out data for certain kinds of cubes, then zlib // removes the last bits of redundancy. Both passes contribute greatly to the // miniscule map sizes. void save_world(OFString *mname) { |
︙ | |||
199 200 201 202 203 204 205 | 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | - - - - - - - - - - + + + + + + + + + + | e.type, e.attr2, e.attr3, e.attr4 }; endianswap(&tmp, sizeof(short), 4); gzwrite(f, &tmp, sizeof(struct persistent_entity)); } } struct sqr *t = NULL; int sc = 0; |
︙ | |||
258 259 260 261 262 263 264 265 | 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 | + + - + - | settagareas(); } COMMAND(savemap, ARG_1STR, ^ (OFString *mname) { save_world(mname); }) // still supports all map formats that have existed since the earliest cube // betas! void |
︙ |