From 7844e447a51872b380a4b1270f3fd0582941a8e2 Mon Sep 17 00:00:00 2001 From: TheFakeMontyOnTheRun <2441483+TheFakeMontyOnTheRun@users.noreply.github.com> Date: Sat, 6 Jul 2024 18:48:00 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20TheFakeM?= =?UTF-8?q?ontyOnTheRun/space-trashman-blues@0c3f6518b9852380a9b44de67ea0b?= =?UTF-8?q?263884cf912=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- coverage/index-sort-f.html | 14 +- coverage/index-sort-l.html | 14 +- coverage/index.html | 14 +- coverage/src/Core.c.func-sort-c.html | 86 +- coverage/src/Core.c.func.html | 52 +- coverage/src/Core.c.gcov.html | 292 ++-- coverage/src/Derelict.c.func-sort-c.html | 28 +- coverage/src/Derelict.c.func.html | 24 +- coverage/src/Derelict.c.gcov.html | 1566 +++++++++++----------- coverage/src/Parser.c.func-sort-c.html | 4 +- coverage/src/Parser.c.func.html | 4 +- coverage/src/Parser.c.gcov.html | 18 +- coverage/src/index-sort-f.html | 14 +- coverage/src/index-sort-l.html | 14 +- coverage/src/index.html | 14 +- index.html | 2 +- sitemap.xml.gz | Bin 127 -> 127 bytes 17 files changed, 1081 insertions(+), 1079 deletions(-) diff --git a/coverage/index-sort-f.html b/coverage/index-sort-f.html index e8b8799db..a798e77d5 100644 --- a/coverage/index-sort-f.html +++ b/coverage/index-sort-f.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -72,10 +72,10 @@ src -
96.3%96.3%
+
95.9%95.9%
- 96.3 % - 709 / 736 + 95.9 % + 707 / 737 93.8 % 60 / 64 diff --git a/coverage/index-sort-l.html b/coverage/index-sort-l.html index 3a4aca0e2..b3bc1876d 100644 --- a/coverage/index-sort-l.html +++ b/coverage/index-sort-l.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -72,10 +72,10 @@ src -
96.3%96.3%
+
95.9%95.9%
- 96.3 % - 709 / 736 + 95.9 % + 707 / 737 93.8 % 60 / 64 diff --git a/coverage/index.html b/coverage/index.html index 25833a66a..debe9bbe7 100644 --- a/coverage/index.html +++ b/coverage/index.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -72,10 +72,10 @@ src -
96.3%96.3%
+
95.9%95.9%
- 96.3 % - 709 / 736 + 95.9 % + 707 / 737 93.8 % 60 / 64 diff --git a/coverage/src/Core.c.func-sort-c.html b/coverage/src/Core.c.func-sort-c.html index e35192da9..072c90eec 100644 --- a/coverage/src/Core.c.func-sort-c.html +++ b/coverage/src/Core.c.func-sort-c.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 44 @@ -64,15 +64,15 @@ 0 - setPlayerDirection + cantBeUsedWithOthersCallback 1 - cantBeUsedCallback - 2 + setPlayerDirection + 1 - cantBeUsedWithOthersCallback + cantBeUsedCallback 2 @@ -107,6 +107,10 @@ getPlayerDirection 10 + + getPlayerRank + 10 + dropObjectToRoom 11 @@ -124,64 +128,60 @@ 14 - getPlayerRank - 14 + getRoomIdByName + 17 moveBy 18 - getRoomIdByName - 19 + setPlayerLocation + 18 walkBy 19 - setPlayerLocation - 20 + useObjectNamed + 23 - pickObjectByName - 26 + getPlayerItems + 24 - useObjectNamed - 27 + pickObjectByName + 24 - getPlayerItems + setPlayerRank 28 - setPlayerRank - 31 + setLoggerDelegate + 38 - setLoggerDelegate - 40 + removeObjectFromList + 49 getPlayerRoom 51 - removeObjectFromList - 51 + getRoom + 53 initCore - 55 - - - getRoom - 57 + 53 setErrorHandlerCallback - 61 + 59 hasItemInRoom @@ -193,51 +193,51 @@ playerHasObject - 99 + 91 getItemNamed - 109 + 104 isCloseToObject - 135 + 129 pickObject - 135 + 129 getPlayerPosition - 152 + 146 addRoom - 1265 + 1219 addToRoom - 1624 + 1565 addObjectToRoom - 1642 + 1583 - removeObjectFromRoom - 1777 + getItem + 1710 - addObjectToList - 1779 + removeObjectFromRoom + 1712 - getItem - 1797 + addObjectToList + 1714 addItem - 1936 + 1866
diff --git a/coverage/src/Core.c.func.html b/coverage/src/Core.c.func.html index a2b6a0feb..935306172 100644 --- a/coverage/src/Core.c.func.html +++ b/coverage/src/Core.c.func.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 44 @@ -61,23 +61,23 @@ addItem - 1936 + 1866 addObjectToList - 1779 + 1714 addObjectToRoom - 1642 + 1583 addRoom - 1265 + 1219 addToRoom - 1624 + 1565 cantBeUsedCallback @@ -85,7 +85,7 @@ cantBeUsedWithOthersCallback - 2 + 1 dropObjectByName @@ -101,11 +101,11 @@ getItem - 1797 + 1710 getItemNamed - 109 + 104 getPlayerDirection @@ -113,15 +113,15 @@ getPlayerItems - 28 + 24 getPlayerPosition - 152 + 146 getPlayerRank - 14 + 10 getPlayerRoom @@ -129,7 +129,7 @@ getRoom - 57 + 53 getRoomByName @@ -141,7 +141,7 @@ getRoomIdByName - 19 + 17 hasItemInRoom @@ -149,11 +149,11 @@ initCore - 55 + 53 isCloseToObject - 135 + 129 isPlayerAtRoom @@ -165,27 +165,27 @@ pickObject - 135 + 129 pickObjectByName - 26 + 24 playerHasObject - 99 + 91 removeObjectFromList - 51 + 49 removeObjectFromRoom - 1777 + 1712 setErrorHandlerCallback - 61 + 59 setGameStatus @@ -193,7 +193,7 @@ setLoggerDelegate - 40 + 38 setPlayerDirection @@ -201,7 +201,7 @@ setPlayerLocation - 20 + 18 setPlayerPosition @@ -209,7 +209,7 @@ setPlayerRank - 31 + 28 turnLeft @@ -221,7 +221,7 @@ useObjectNamed - 27 + 23 useObjectsTogether diff --git a/coverage/src/Core.c.gcov.html b/coverage/src/Core.c.gcov.html index 876486b4d..6fa64eb18 100644 --- a/coverage/src/Core.c.gcov.html +++ b/coverage/src/Core.c.gcov.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 44 @@ -170,13 +170,13 @@ 108 2 : defaultLogger("You can't use it like this."); 109 2 : } 110 : - 111 2 : void cantBeUsedWithOthersCallback(struct Item *item1, struct Item *item2) { + 111 1 : void cantBeUsedWithOthersCallback(struct Item *item1, struct Item *item2) { 112 : (void)item1; 113 : (void)item2; - 114 2 : defaultLogger("Nothing happens."); - 115 2 : } + 114 1 : defaultLogger("Nothing happens."); + 115 1 : } 116 : - 117 1936 : struct Item *addItem(const char *description, + 117 1866 : struct Item *addItem(const char *description, 118 : #ifdef INCLUDE_ITEM_DESCRIPTIONS 119 : const char *info, 120 : #endif @@ -187,56 +187,56 @@ 125 : int8_t positionX, 126 : int8_t positionY) { 127 : - 128 1936 : struct Item *toReturn = &item[itemsCount]; + 128 1866 : struct Item *toReturn = &item[itemsCount]; 129 : - 130 1936 : toReturn->index = itemsCount++; - 131 1936 : toReturn->name = description; + 130 1866 : toReturn->index = itemsCount++; + 131 1866 : toReturn->name = description; 132 : #ifdef INCLUDE_ITEM_DESCRIPTIONS 133 : toReturn->info = info; 134 : #endif - 135 1936 : toReturn->pickable = pickable; - 136 1936 : toReturn->position.x = positionX; - 137 1936 : toReturn->position.y = positionY; + 135 1866 : toReturn->pickable = pickable; + 136 1866 : toReturn->position.x = positionX; + 137 1866 : toReturn->position.y = positionY; 138 : - 139 1936 : toReturn->useCallback = cantBeUsedCallback; - 140 1936 : toReturn->useWithCallback = cantBeUsedWithOthersCallback; + 139 1866 : toReturn->useCallback = cantBeUsedCallback; + 140 1866 : toReturn->useWithCallback = cantBeUsedWithOthersCallback; 141 : - 142 1936 : return toReturn; + 142 1866 : return toReturn; 143 : } 144 : - 145 1265 : struct Room *addRoom( + 145 1219 : struct Room *addRoom( 146 : const char *name, 147 : #ifdef INCLUDE_ROOM_DESCRIPTIONS 148 : const char *info, 149 : #endif 150 : uint8_t sizeX, uint8_t sizeY, uint8_t chanceOfRandomBattle, const int8_t connections[6]) { 151 : - 152 1265 : struct Room *toReturn = &rooms[roomCount]; - 153 1265 : toReturn->name = name; + 152 1219 : struct Room *toReturn = &rooms[roomCount]; + 153 1219 : toReturn->name = name; 154 : #ifdef INCLUDE_ROOM_DESCRIPTIONS 155 : toReturn->info = info; 156 : #endif - 157 1265 : toReturn->sizeX = sizeX; - 158 1265 : toReturn->sizeY = sizeY; - 159 1265 : toReturn->chanceOfRandomBattle = chanceOfRandomBattle; + 157 1219 : toReturn->sizeX = sizeX; + 158 1219 : toReturn->sizeY = sizeY; + 159 1219 : toReturn->chanceOfRandomBattle = chanceOfRandomBattle; 160 : - 161 1265 : memCopyToFrom((void*)toReturn->connections, (void*)connections, 6); + 161 1219 : memCopyToFrom((void*)toReturn->connections, (void*)connections, 6); 162 : 163 : /* add list head to make manipulations easier */ - 164 1265 : toReturn->itemsPresent = &roomObjectHeads[roomCount++]; - 165 1265 : memFill(toReturn->itemsPresent, 0, sizeof(struct ObjectNode)); + 164 1219 : toReturn->itemsPresent = &roomObjectHeads[roomCount++]; + 165 1219 : memFill(toReturn->itemsPresent, 0, sizeof(struct ObjectNode)); 166 : - 167 1265 : return toReturn; + 167 1219 : return toReturn; 168 : } 169 : 170 : LogDelegate defaultLogger = writeToLog; 171 : - 172 61 : void setErrorHandlerCallback(ErrorHandlerCallback callback) { - 173 61 : errorHandlerCallback = callback; - 174 61 : } + 172 59 : void setErrorHandlerCallback(ErrorHandlerCallback callback) { + 173 59 : errorHandlerCallback = callback; + 174 59 : } 175 : - 176 152 : struct WorldPosition *getPlayerPosition(void) { - 177 152 : return &playerPosition; + 176 146 : struct WorldPosition *getPlayerPosition(void) { + 177 146 : return &playerPosition; 178 : } 179 : 180 4 : void setPlayerPosition(struct WorldPosition *pos) { @@ -245,8 +245,8 @@ 183 4 : } 184 : 185 : #ifndef CAN_PICK_OBJECT_AT_ANY_DISTANCE - 186 135 : uint8_t isCloseToObject(struct WorldPosition *pos, struct Item *_item) { - 187 135 : return (abs(pos->x - _item->position.x) + abs(pos->y - _item->position.y)) <= 1; + 186 129 : uint8_t isCloseToObject(struct WorldPosition *pos, struct Item *_item) { + 187 129 : return (abs(pos->x - _item->position.x) + abs(pos->y - _item->position.y)) <= 1; 188 : } 189 : #endif 190 : @@ -254,16 +254,16 @@ 192 14 : return gameStatus; 193 : } 194 : - 195 28 : struct ObjectNode *getPlayerItems(void) { - 196 28 : return collectedObject->next; + 195 24 : struct ObjectNode *getPlayerItems(void) { + 196 24 : return collectedObject->next; 197 : } 198 : - 199 109 : struct Item *getItemNamed(const char *name) { + 199 104 : struct Item *getItemNamed(const char *name) { 200 : uint8_t c; 201 : - 202 1276 : for (c = 0; c < itemsCount; ++c) { - 203 1275 : if (!strcmp(item[c].name, name)) { - 204 108 : return &item[c]; + 202 1221 : for (c = 0; c < itemsCount; ++c) { + 203 1220 : if (!strcmp(item[c].name, name)) { + 204 103 : return &item[c]; 205 : } 206 : } 207 : @@ -271,13 +271,13 @@ 209 : } 210 : 211 : #ifdef MORE_OBJECTS - 212 19 : uint8_t getRoomIdByName(const char *name) { + 212 17 : uint8_t getRoomIdByName(const char *name) { 213 : uint8_t c; 214 : - 215 19 : if (name != NULL) { - 216 232 : for (c = 1; c < roomCount; ++c) { - 217 231 : if (!strcmp(rooms[c].name, name)) { - 218 17 : return c; + 215 17 : if (name != NULL) { + 216 215 : for (c = 1; c < roomCount; ++c) { + 217 214 : if (!strcmp(rooms[c].name, name)) { + 218 15 : return c; 219 : } 220 : } 221 : } @@ -300,53 +300,53 @@ 238 1 : return NULL; 239 : } 240 : - 241 1779 : void addObjectToList(struct Item *itemToAdd, struct ObjectNode *listHead) { - 242 1779 : struct ObjectNode *head = listHead; + 241 1714 : void addObjectToList(struct Item *itemToAdd, struct ObjectNode *listHead) { + 242 1714 : struct ObjectNode *head = listHead; 243 : - 244 2799 : while (head->next != NULL) { - 245 1021 : if (getItem(head->item) == itemToAdd) { + 244 2697 : while (head->next != NULL) { + 245 984 : if (getItem(head->item) == itemToAdd) { 246 : /* Object already belongs to the list! */ 247 1 : return; 248 : } 249 : - 250 1020 : head = head->next; + 250 983 : head = head->next; 251 : } 252 : - 253 1778 : head->next = &objectNodes[itemToAdd->index]; - 254 1778 : memFill(head->next, 0, sizeof(struct ObjectNode)); - 255 1778 : head->next->item = itemToAdd->index; + 253 1713 : head->next = &objectNodes[itemToAdd->index]; + 254 1713 : memFill(head->next, 0, sizeof(struct ObjectNode)); + 255 1713 : head->next->item = itemToAdd->index; 256 : } 257 : - 258 51 : void removeObjectFromList(struct Item *itemToRemove, struct ObjectNode *listHead) { - 259 51 : struct ObjectNode *head = listHead->next; - 260 51 : struct ObjectNode *prev = listHead; + 258 49 : void removeObjectFromList(struct Item *itemToRemove, struct ObjectNode *listHead) { + 259 49 : struct ObjectNode *head = listHead->next; + 260 49 : struct ObjectNode *prev = listHead; 261 : - 262 137 : while (head != NULL) { - 263 137 : if (head->item == itemToRemove->index) { - 264 51 : prev->next = head->next; - 265 51 : return; + 262 134 : while (head != NULL) { + 263 134 : if (head->item == itemToRemove->index) { + 264 49 : prev->next = head->next; + 265 49 : return; 266 : } 267 : - 268 86 : prev = head; - 269 86 : head = head->next; + 268 85 : prev = head; + 269 85 : head = head->next; 270 : } 271 : /* Object doesn't belong to the list! */ 272 : } 273 : - 274 1777 : void removeObjectFromRoom(struct Item *itemToRemove) { - 275 1777 : if (itemToRemove->roomId != 0) { - 276 40 : removeObjectFromList(itemToRemove, rooms[itemToRemove->roomId].itemsPresent); - 277 40 : itemToRemove->roomId = 0; + 274 1712 : void removeObjectFromRoom(struct Item *itemToRemove) { + 275 1712 : if (itemToRemove->roomId != 0) { + 276 38 : removeObjectFromList(itemToRemove, rooms[itemToRemove->roomId].itemsPresent); + 277 38 : itemToRemove->roomId = 0; 278 : } - 279 1777 : } + 279 1712 : } 280 : 281 : - 282 1642 : void addObjectToRoom(uint8_t roomId, struct Item *itemToAdd) { - 283 1642 : struct Room *roomToAddObject = &rooms[roomId]; - 284 1642 : removeObjectFromRoom(itemToAdd); - 285 1642 : addObjectToList(itemToAdd, roomToAddObject->itemsPresent); - 286 1642 : itemToAdd->roomId = roomId; - 287 1642 : } + 282 1583 : void addObjectToRoom(uint8_t roomId, struct Item *itemToAdd) { + 283 1583 : struct Room *roomToAddObject = &rooms[roomId]; + 284 1583 : removeObjectFromRoom(itemToAdd); + 285 1583 : addObjectToList(itemToAdd, roomToAddObject->itemsPresent); + 286 1583 : itemToAdd->roomId = roomId; + 287 1583 : } 288 : 289 11 : void dropObjectToRoom(uint8_t roomId, struct Item *itemToDrop) { 290 : #ifdef CLI_BUILD @@ -368,33 +368,33 @@ 306 : } 307 : } 308 : - 309 135 : void pickObject(struct Item *itemToPick) { + 309 129 : void pickObject(struct Item *itemToPick) { 310 : #ifndef CAN_PICK_OBJECT_AT_ANY_DISTANCE - 311 135 : if (!isCloseToObject(getPlayerPosition(), itemToPick)) { + 311 129 : if (!isCloseToObject(getPlayerPosition(), itemToPick)) { 312 0 : return; 313 : } 314 : #endif 315 : - 316 135 : if (!itemToPick->pickable) { + 316 129 : if (!itemToPick->pickable) { 317 1 : defaultLogger("Can't pick it up"); 318 1 : return; 319 : } 320 : - 321 134 : removeObjectFromRoom(itemToPick); - 322 134 : addObjectToList(itemToPick, collectedObject); + 321 128 : removeObjectFromRoom(itemToPick); + 322 128 : addObjectToList(itemToPick, collectedObject); 323 : - 324 134 : if (itemToPick->pickCallback != NULL) { - 325 16 : itemToPick->pickCallback(itemToPick); + 324 128 : if (itemToPick->pickCallback != NULL) { + 325 14 : itemToPick->pickCallback(itemToPick); 326 : } 327 : } 328 : - 329 14 : uint8_t getPlayerRank(void) { - 330 14 : return playerRank; + 329 10 : uint8_t getPlayerRank(void) { + 330 10 : return playerRank; 331 : } 332 : - 333 31 : void setPlayerRank(uint8_t newRank) { - 334 31 : playerRank = newRank; - 335 31 : } + 333 28 : void setPlayerRank(uint8_t newRank) { + 334 28 : playerRank = newRank; + 335 28 : } 336 : 337 18 : void moveBy(uint8_t direction) { 338 : uint8_t c; @@ -456,19 +456,19 @@ 394 : } 395 : } 396 : - 397 26 : void pickObjectByName(const char *objName) { - 398 26 : struct Room *room = &rooms[playerLocation]; - 399 26 : struct ObjectNode *itemToPick = room->itemsPresent->next; + 397 24 : void pickObjectByName(const char *objName) { + 398 24 : struct Room *room = &rooms[playerLocation]; + 399 24 : struct ObjectNode *itemToPick = room->itemsPresent->next; 400 : - 401 87 : while (itemToPick != NULL) { - 402 86 : if (!strcmp(getItem(itemToPick->item)->name, objName)) { + 401 84 : while (itemToPick != NULL) { + 402 83 : if (!strcmp(getItem(itemToPick->item)->name, objName)) { 403 : #ifdef MOVE_TO_OBJECT_POSITION_WHEN_PICKING - 404 25 : playerPosition = getItem(itemToPick->item)->position; + 404 23 : playerPosition = getItem(itemToPick->item)->position; 405 : #endif - 406 25 : pickObject(getItem(itemToPick->item)); - 407 25 : return; + 406 23 : pickObject(getItem(itemToPick->item)); + 407 23 : return; 408 : } - 409 61 : itemToPick = itemToPick->next; + 409 60 : itemToPick = itemToPick->next; 410 : } 411 : } 412 : @@ -526,16 +526,16 @@ 464 32 : return 0; 465 : } 466 : - 467 99 : uint8_t playerHasObject(const char *itemName) { - 468 99 : struct ObjectNode *itemToPick = collectedObject->next; + 467 91 : uint8_t playerHasObject(const char *itemName) { + 468 91 : struct ObjectNode *itemToPick = collectedObject->next; 469 : - 470 354 : while (itemToPick != NULL) { - 471 282 : if (!strcmp(getItem(itemToPick->item)->name, itemName)) { - 472 27 : return 1; + 470 322 : while (itemToPick != NULL) { + 471 255 : if (!strcmp(getItem(itemToPick->item)->name, itemName)) { + 472 24 : return 1; 473 : } - 474 255 : itemToPick = itemToPick->next; + 474 231 : itemToPick = itemToPick->next; 475 : } - 476 72 : return 0; + 476 67 : return 0; 477 : } 478 : 479 : @@ -551,43 +551,43 @@ 489 0 : return room->name; 490 : } 491 : - 492 57 : struct Room *getRoom(uint8_t index) { - 493 57 : return &rooms[index]; + 492 53 : struct Room *getRoom(uint8_t index) { + 493 53 : return &rooms[index]; 494 : } 495 : - 496 1797 : struct Item *getItem(uint8_t index) { - 497 1797 : return &item[index]; + 496 1710 : struct Item *getItem(uint8_t index) { + 497 1710 : return &item[index]; 498 : } 499 : 500 51 : uint8_t getPlayerRoom(void) { 501 51 : return playerLocation; 502 : } 503 : - 504 27 : void useObjectNamed(const char *operand) { - 505 27 : struct ObjectNode *itemToPick = getPlayerItems(); + 504 23 : void useObjectNamed(const char *operand) { + 505 23 : struct ObjectNode *itemToPick = getPlayerItems(); 506 : - 507 84 : while (itemToPick != NULL) { - 508 60 : struct Item *_item = getItem(itemToPick->item); - 509 60 : if (!strcmp(_item->name, operand)) { + 507 69 : while (itemToPick != NULL) { + 508 49 : struct Item *_item = getItem(itemToPick->item); + 509 49 : if (!strcmp(_item->name, operand)) { 510 3 : if (_item->useCallback != NULL) { 511 3 : _item->useCallback(_item); 512 : } 513 3 : return; 514 : } - 515 57 : itemToPick = itemToPick->next; + 515 46 : itemToPick = itemToPick->next; 516 : } 517 : - 518 24 : itemToPick = getRoom(playerLocation)->itemsPresent->next; + 518 20 : itemToPick = getRoom(playerLocation)->itemsPresent->next; 519 : - 520 41 : while (itemToPick != NULL) { - 521 38 : struct Item *_item = getItem(itemToPick->item); - 522 38 : if (!strcmp(_item->name, operand)) { - 523 21 : if (_item->useCallback != NULL) { - 524 21 : _item->useCallback(_item); + 520 36 : while (itemToPick != NULL) { + 521 33 : struct Item *_item = getItem(itemToPick->item); + 522 33 : if (!strcmp(_item->name, operand)) { + 523 17 : if (_item->useCallback != NULL) { + 524 17 : _item->useCallback(_item); 525 : } - 526 21 : return; + 526 17 : return; 527 : } - 528 17 : itemToPick = itemToPick->next; + 528 16 : itemToPick = itemToPick->next; 529 : } 530 : } 531 : @@ -720,9 +720,9 @@ 658 4 : playerDirection = (enum EDirection)pDir; 659 4 : } 660 : - 661 20 : void setPlayerLocation(uint8_t location) { - 662 20 : playerLocation = location; - 663 20 : } + 661 18 : void setPlayerLocation(uint8_t location) { + 662 18 : playerLocation = location; + 663 18 : } 664 : 665 19 : void walkBy(uint8_t direction) { 666 : @@ -822,22 +822,22 @@ 760 10 : return playerDirection; 761 : } 762 : - 763 1624 : void addToRoom(const char *roomName, struct Item *itemName) { + 763 1565 : void addToRoom(const char *roomName, struct Item *itemName) { 764 : uint8_t r; 765 : 766 : #ifdef CLI_BUILD - 767 1624 : if (roomName == NULL || itemName == NULL || strlen(roomName) == 0) { + 767 1565 : if (roomName == NULL || itemName == NULL || strlen(roomName) == 0) { 768 3 : defaultLogger("Either the object name or the room name are null. Check your stuff"); 769 3 : return; 770 : } 771 : #endif 772 : - 773 19229 : for (r = 1; r < TOTAL_ROOMS; ++r) { - 774 19228 : const char *desc = rooms[r].name; + 773 18532 : for (r = 1; r < TOTAL_ROOMS; ++r) { + 774 18531 : const char *desc = rooms[r].name; 775 : - 776 19228 : if (desc != NULL && !strcmp(desc, roomName)) { - 777 1620 : addObjectToRoom(r, itemName); - 778 1620 : return; + 776 18531 : if (desc != NULL && !strcmp(desc, roomName)) { + 777 1561 : addObjectToRoom(r, itemName); + 778 1561 : return; 779 : } 780 : } 781 : @@ -846,9 +846,9 @@ 784 : #endif 785 : } 786 : - 787 40 : void setLoggerDelegate(LogDelegate newDelegate) { - 788 40 : defaultLogger = newDelegate; - 789 40 : } + 787 38 : void setLoggerDelegate(LogDelegate newDelegate) { + 788 38 : defaultLogger = newDelegate; + 789 38 : } 790 : 791 : 792 1 : void setPlayerDirection(enum EDirection direction) { @@ -859,26 +859,26 @@ 797 7 : gameStatus = newStatus; 798 7 : } 799 : - 800 55 : void initCore(void) { - 801 55 : defaultLogger = writeToLog; + 800 53 : void initCore(void) { + 801 53 : defaultLogger = writeToLog; 802 : /* prepare for a single player in the game */ - 803 55 : memFill(&playerPosition, 0, sizeof(struct WorldPosition)); - 804 55 : setErrorHandlerCallback(NULL); + 803 53 : memFill(&playerPosition, 0, sizeof(struct WorldPosition)); + 804 53 : setErrorHandlerCallback(NULL); 805 : - 806 55 : collectedObject = &collectedObjectHead; - 807 55 : memFill(collectedObject, 0, sizeof(struct ObjectNode)); - 808 55 : playerLocation = 1; - 809 55 : itemsCount = 0; - 810 55 : roomCount = 1; /* there's an implicit dummy first */ - 811 55 : playerRank = 0; - 812 55 : gameStatus = kNormalGameplay; - 813 55 : playerDirection = kNorth; - 814 55 : playerPosition.x = 15; - 815 55 : playerPosition.y = 15; + 806 53 : collectedObject = &collectedObjectHead; + 807 53 : memFill(collectedObject, 0, sizeof(struct ObjectNode)); + 808 53 : playerLocation = 1; + 809 53 : itemsCount = 0; + 810 53 : roomCount = 1; /* there's an implicit dummy first */ + 811 53 : playerRank = 0; + 812 53 : gameStatus = kNormalGameplay; + 813 53 : playerDirection = kNorth; + 814 53 : playerPosition.x = 15; + 815 53 : playerPosition.y = 15; 816 : - 817 55 : memFill(&rooms, 0, TOTAL_ROOMS * sizeof(struct Room)); - 818 55 : memFill(&item, 0, TOTAL_ITEMS * sizeof(struct Item)); - 819 55 : } + 817 53 : memFill(&rooms, 0, TOTAL_ROOMS * sizeof(struct Room)); + 818 53 : memFill(&item, 0, TOTAL_ITEMS * sizeof(struct Item)); + 819 53 : } 820 : 821 : 822 : diff --git a/coverage/src/Derelict.c.func-sort-c.html b/coverage/src/Derelict.c.func-sort-c.html index 29f2b72eb..fb5578a45 100644 --- a/coverage/src/Derelict.c.func-sort-c.html +++ b/coverage/src/Derelict.c.func-sort-c.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 313 - 320 - 97.8 % + 311 + 321 + 96.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 15 @@ -72,7 +72,11 @@ 0 - reactorValveCallback + reactorValveCallback + 1 + + + useKeycardWith 1 @@ -100,11 +104,7 @@ 4 - useCommWithRank - 4 - - - useComputerRack + useComputerRack 4 @@ -121,15 +121,15 @@ keycardPickCallback - 15 + 13 updateRankFromKeycards - 22 + 20 - initStation - 55 + initStation + 53
diff --git a/coverage/src/Derelict.c.func.html b/coverage/src/Derelict.c.func.html index abda2e3e9..d3358e6a4 100644 --- a/coverage/src/Derelict.c.func.html +++ b/coverage/src/Derelict.c.func.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 313 - 320 - 97.8 % + 311 + 321 + 96.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 15 @@ -80,8 +80,8 @@ 0 - initStation - 55 + initStation + 53 inspectItemWithHelmetCallback @@ -97,15 +97,15 @@ keycardPickCallback - 15 + 13 - reactorValveCallback + reactorValveCallback 1 updateRankFromKeycards - 22 + 20 useBootsWithMagneticCoupling @@ -120,12 +120,12 @@ 4 - useCommWithRank + useComputerRack 4 - useComputerRack - 4 + useKeycardWith + 1 useRegularFlush diff --git a/coverage/src/Derelict.c.gcov.html b/coverage/src/Derelict.c.gcov.html index 57caa20de..3a8a0d958 100644 --- a/coverage/src/Derelict.c.gcov.html +++ b/coverage/src/Derelict.c.gcov.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 313 - 320 - 97.8 % + 311 + 321 + 96.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 15 @@ -97,32 +97,32 @@ 35 0 : return accessGrantedToSafe; 36 : } 37 : - 38 22 : void updateRankFromKeycards(void) { - 39 22 : uint8_t rank = 0; + 38 20 : void updateRankFromKeycards(void) { + 39 20 : uint8_t rank = 0; 40 : - 41 22 : if (playerHasObject("low-rank-keycard")) { - 42 9 : rank = 1; + 41 20 : if (playerHasObject("low-rank-keycard")) { + 42 7 : rank = 1; 43 : } 44 : - 45 22 : if (playerHasObject("hacked-keycard")) { - 46 4 : rank = 2; + 45 20 : if (playerHasObject("hacked-keycard")) { + 46 3 : rank = 2; 47 : } 48 : - 49 22 : if (playerHasObject("high-rank-keycard")) { + 49 20 : if (playerHasObject("high-rank-keycard")) { 50 3 : rank = 3; 51 : } 52 : - 53 22 : if (playerHasObject("root-keycard")) { + 53 20 : if (playerHasObject("root-keycard")) { 54 4 : rank = 4; 55 : } 56 : - 57 22 : setPlayerRank(rank); - 58 22 : } + 57 20 : setPlayerRank(rank); + 58 20 : } 59 : - 60 15 : void keycardPickCallback(struct Item *item) { + 60 13 : void keycardPickCallback(struct Item *item) { 61 : (void)item; - 62 15 : updateRankFromKeycards(); - 63 15 : } + 62 13 : updateRankFromKeycards(); + 63 13 : } 64 : 65 : 66 7 : void keycardDropCallback(struct Item *item) { @@ -274,787 +274,789 @@ 212 : #endif 213 0 : } 214 : - 215 4 : void useCommWithRank(struct Item *item) { - 216 : - 217 4 : if (getPlayerRank() <= 1) { - 218 2 : defaultLogger("Insufficient rank to access"); - 219 2 : return; - 220 : } - 221 2 : defaultLogger("Computer node rebooted"); - 222 2 : item->active = !item->active; - 223 : } + 215 1 : void useKeycardWith(struct Item *item1, struct Item *item2) { + 216 1 : if (item2 == getItemNamed("comm-terminal-1") || + 217 0 : item2 == getItemNamed("comm-terminal-2") || + 218 0 : item2 == getItemNamed("comm-terminal-3")) { + 219 : + 220 1 : defaultLogger("Computer node rebooted"); + 221 1 : item2->active = TRUE; + 222 1 : return; + 223 : } 224 : - 225 : /** - 226 : * TODO: change name for this function - 227 : * @param item - 228 : */ - 229 4 : void useComputerRack(struct Item *item) { - 230 : (void)item; - 231 4 : if (!getItemNamed("comm-terminal-1")->active || - 232 2 : !getItemNamed("comm-terminal-2")->active || - 233 2 : !getItemNamed("comm-terminal-3")->active) { - 234 2 : defaultLogger("Central computer is offline"); - 235 2 : return; - 236 : } - 237 : - 238 : - 239 2 : if (accessGrantedToSafe) { - 240 1 : defaultLogger("Safe unlocked"); - 241 1 : addToRoom("situation-room", getItemNamed("root-keycard")); - 242 1 : return; - 243 : } - 244 : - 245 1 : defaultLogger("Safe secured"); - 246 : } + 225 0 : defaultLogger("Keycard can't be used with that"); + 226 : } + 227 : + 228 : /** + 229 : * TODO: change name for this function + 230 : * @param item + 231 : */ + 232 4 : void useComputerRack(struct Item *item) { + 233 : (void)item; + 234 4 : if (!getItemNamed("comm-terminal-1")->active || + 235 2 : !getItemNamed("comm-terminal-2")->active || + 236 2 : !getItemNamed("comm-terminal-3")->active) { + 237 2 : defaultLogger("Central computer is offline"); + 238 2 : return; + 239 : } + 240 : + 241 : + 242 2 : if (accessGrantedToSafe) { + 243 1 : defaultLogger("Safe unlocked"); + 244 1 : addToRoom("situation-room", getItemNamed("root-keycard")); + 245 1 : return; + 246 : } 247 : - 248 1 : void reactorValveCallback(struct Item *item) { - 249 : (void)item; - 250 1 : setGameStatus(kBadVictory); - 251 1 : } - 252 : - 253 55 : void initStation(void) { - 254 : - 255 : struct Item *newItem; - 256 : int8_t connections[6]; - 257 55 : accessGrantedToSafe = FALSE; - 258 : - 259 55 : initCore(); - 260 : - 261 : /*Rooms*/ - 262 : /* 1 */ - 263 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 264 55 : connections[0] = 2; - 265 55 : addRoom( - 266 : "lss-daedalus", - 267 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 268 : "The salvage operations vehicle. It's\n" - 269 : "tracked remotely, to prevent \n" - 270 : "escapes. If I try taking outside \n" - 271 : "the predicted path, I will sink into\n" - 272 : "the abyss myself.", - 273 : #endif - 274 : 32, 32, 0, connections); - 275 : - 276 : /* 2 */ - 277 55 : connections[2] = 1; - 278 55 : connections[1] = 6; - 279 55 : connections[0] = 3; - 280 55 : addRoom("hangar", - 281 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 282 : "The main hangar is rather \n" - 283 : "unremarkable. The only thing you \n" - 284 : "notice is a slight yellow tint of \n" - 285 : "the air, as if a mist slides next \n" - 286 : "to the floor. It's very faint. Your\n" - 287 : "ship's computer tells you this is\n" - 288 : "harmless (as if those readings were\n" - 289 : "worth the trust). Unfortunately, no\n" - 290 : "useful tools around here. Around the\n" - 291 : "corner, there's a escape pod entrance.\n" - 292 : "Apparently, only one pod was launched.", - 293 : #endif - 294 : 32, 32, 0, connections); - 295 : - 296 : /* 3 */ - 297 55 : connections[2] = 0; - 298 55 : connections[3] = 2; - 299 55 : connections[0] = 4; - 300 55 : connections[1] = 5; - 301 55 : addRoom("hall-2", - 302 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 303 : "A well lit hall, with doors. It's \n" - 304 : "the main hub of the vehicle. Despite\n" - 305 : "being right next to the hangar and\n" - 306 : "the control room, it's rather quiet.", - 307 : #endif - 308 : 32, 32, 0, connections); - 309 : - 310 : /* 4 */ - 311 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 312 55 : connections[2] = 3; - 313 55 : connections[4] = 19; - 314 55 : connections[5] = 13; - 315 55 : addRoom("elevator-level-2", - 316 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 317 : "It's rather surprising that this \n" - 318 : "ship has an elevator. This is was\n" - 319 : "typical only of ships with 5 levels\n" - 320 : "or more.", - 321 : #endif - 322 55 : 64, 64, 0, connections)->rankRequired = 1; - 323 : - 324 : /* 5 */ - 325 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 326 55 : connections[3] = 3; - 327 55 : connections[1] = 9; - 328 55 : connections[0] = 7; - 329 55 : connections[2] = 8; - 330 55 : addRoom("dorms-1", - 331 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 332 : "Part of the dorms hallway. There are\n" - 333 : "some (busted) control panels for \n" - 334 : "ejecting the pods. Some pieces of \n" - 335 : "cloth and broken plastic on the floor,\n" - 336 : "but nothing really useful.", - 337 : #endif - 338 55 : 32, 32, 0, connections)->rankRequired = 1; - 339 : - 340 : - 341 : /* 6 */ - 342 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 343 55 : connections[3] = 2; - 344 55 : addRoom("rls-bohr-2", - 345 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 346 : "A rescue ship. Only for emergencies.\n" - 347 : "Named after some Niels Bohr scientist\n" - 348 : "guy or whatever. Some drops on the\n" - 349 : "carpet and I don't even want know \n" - 350 : "what it is, but I guess I already\n" - 351 : "know. Ick.", - 352 : #endif - 353 : 64, 9, 0, connections); - 354 : - 355 : - 356 : /* 7 */ - 357 55 : connections[3] = 0; - 358 55 : connections[2] = 5; - 359 55 : addRoom("pod-1", - 360 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 361 : "A living pod. Looks like from one \n" - 362 : "of the oficcers. It's messy, but \n" - 363 : "as if it's occupant would easily \n" - 364 : "find his belongings in there. \n" - 365 : "There are some burn marks on the \n" - 366 : "walls.", - 367 : #endif - 368 55 : 32, 32, 0, connections)->rankRequired = 1; - 369 : - 370 : /* 8 */ - 371 55 : connections[2] = 0; - 372 55 : connections[0] = 5; - 373 55 : addRoom("pod-2", - 374 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 375 : "A empty living pod. Looks as if it\n" - 376 : "was never ever used. If can even \n" - 377 : "see some of the factory stickers \n" - 378 : "in it.", - 379 : #endif - 380 55 : 32, 32, 0, connections)->rankRequired = 2; - 381 : - 382 : /* 9 */ - 383 55 : connections[1] = 12; - 384 55 : connections[3] = 5; - 385 55 : connections[0] = 10; - 386 55 : connections[2] = 11; - 387 55 : addRoom("dorms-2", - 388 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 389 : "Anonther part of the dorms hallway.\n" - 390 : "On those, the panels were visibly\n" - 391 : "well. These parts of the quarters \n" - 392 : "were probably the more prestigious ones.", - 393 : #endif - 394 55 : 32, 32, 0, connections)->rankRequired = 1; - 395 : - 396 : /* 10 */ - 397 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 398 55 : connections[2] = 9; - 399 55 : addRoom("pod-3", - 400 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 401 : "A young woman's pod. You \n" - 402 : "do recognize a few items, but its \n" - 403 : "badly mixed up. It's hard to make \n" - 404 : "the age of girl, but she was young.", - 405 : #endif - 406 55 : 32, 32, 0, connections)->rankRequired = 3; - 407 : - 408 : /* 11 */ - 409 55 : connections[2] = 0; - 410 55 : connections[0] = 9; - 411 55 : addRoom("pod-4", - 412 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 413 : "A the first officer's pod, for sure.\n" - 414 : "It's neat, clean and organized. Not \n" - 415 : "much around. He had a strange \n" - 416 : "fixation on redheads.", - 417 : #endif - 418 55 : 32, 32, 0, connections)->rankRequired = 4; - 419 : - 420 : /* 12 */ - 421 55 : connections[0] = 0; - 422 55 : connections[3] = 9; - 423 55 : addRoom("computer-core", - 424 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 425 : "TBD.", - 426 : #endif - 427 : 32, 32, 0, connections); - 428 : - 429 : /* 13 */ - 430 55 : connections[3] = 0; - 431 55 : connections[4] = 4; - 432 55 : connections[2] = 14; - 433 55 : addRoom("elevator-level-1", - 434 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 435 : "It's rather surprising that this ship\n" - 436 : "has an elevator. This is was typical \n" - 437 : "only of ships with 5 levels or more.", - 438 : #endif - 439 55 : 32, 32, 0, connections)->rankRequired = 1; - 440 : - 441 : /* 14 */ - 442 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 443 55 : connections[0] = 13; - 444 55 : connections[1] = 17; - 445 55 : connections[2] = 16; - 446 55 : connections[3] = 15; - 447 55 : addRoom("hall-1", - 448 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 449 : "This hall has a busier feel.\n" - 450 : "Here you see objects thrown all over \n" - 451 : "the place, as if someone was in the \n" - 452 : "middle of a day-to-day routine and had\n" - 453 : "to quickly run.", - 454 : #endif - 455 55 : 32, 32, 0, connections)->rankRequired = 1; - 456 : - 457 : /* 15 */ - 458 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 459 55 : connections[1] = 14; - 460 55 : addRoom("bridge", - 461 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 462 : "TBD.", - 463 : #endif - 464 55 : 32, 32, 0, connections)->rankRequired = 4; - 465 : - 466 : /* 16 */ - 467 55 : connections[1] = 0; - 468 55 : connections[0] = 14; - 469 55 : addRoom("situation-room", - 470 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 471 : "TBD.", - 472 : #endif - 473 55 : 32, 32, 0, connections)->rankRequired = 3; - 474 : - 475 : /* 17 */ - 476 55 : connections[0] = 0; - 477 55 : connections[3] = 14; - 478 55 : connections[1] = 18; - 479 55 : addRoom("crew-bunks", - 480 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 481 : "TBD.", - 482 : #endif - 483 55 : 32, 32, 0, connections)->rankRequired = 1; - 484 : - 485 : /* 18 */ - 486 55 : connections[1] = 0; - 487 55 : connections[3] = 17; - 488 55 : addRoom("armory", - 489 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 490 : "TBD", - 491 : #endif - 492 55 : 32, 32, 0, connections)->rankRequired = 3; - 493 : - 494 : /* 19 */ - 495 55 : connections[3] = 0; - 496 55 : connections[2] = 20; - 497 55 : connections[5] = 4; - 498 55 : addRoom("elevator-level-3", - 499 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 500 : "It's rather surprising that this ship has an\n" - 501 : "elevator. This is was typical only of ships \n" - 502 : "with 5 levels or more.", - 503 : #endif - 504 55 : 32, 32, 0, connections)->rankRequired = 1; - 505 : - 506 : /* 20 */ - 507 55 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); - 508 55 : connections[0] = 19; - 509 55 : connections[1] = 21; - 510 55 : connections[3] = 23; - 511 55 : addRoom("hall-3", - 512 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 513 : "TBD", - 514 : #endif - 515 : 32, 32, 0, connections); - 516 : - 517 : /* 21 */ - 518 55 : connections[0] = 0; - 519 55 : connections[3] = 20; - 520 55 : connections[1] = 22; - 521 55 : addRoom("wc", - 522 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 523 : "TBD.", - 524 : #endif - 525 : 32, 32, 0, connections); - 526 : - 527 : /* 22 */ - 528 55 : connections[1] = 0; - 529 55 : connections[3] = 21; - 530 55 : addRoom("reactor-core", - 531 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 532 : "TBD.", - 533 : #endif - 534 55 : 32, 32, 0, connections)->rankRequired = 4; - 535 : - 536 : /* 23 */ - 537 55 : connections[3] = 0; - 538 55 : connections[1] = 20; - 539 55 : addRoom("radar-array", - 540 : #ifdef INCLUDE_ROOM_DESCRIPTIONS - 541 : "TBD", - 542 : #endif - 543 55 : 32, 32, 0, connections)->rankRequired = 2; - 544 : - 545 : - 546 : /*Items*/ - 547 55 : addItem("dummy", - 548 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 549 : "ERROR", - 550 : #endif - 551 : #ifdef ITEMS_HAVE_WEIGHT - 552 : 0, + 248 1 : defaultLogger("Safe secured"); + 249 : } + 250 : + 251 1 : void reactorValveCallback(struct Item *item) { + 252 : (void)item; + 253 1 : setGameStatus(kBadVictory); + 254 1 : } + 255 : + 256 53 : void initStation(void) { + 257 : + 258 : struct Item *newItem; + 259 : int8_t connections[6]; + 260 53 : accessGrantedToSafe = FALSE; + 261 : + 262 53 : initCore(); + 263 : + 264 : /*Rooms*/ + 265 : /* 1 */ + 266 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 267 53 : connections[0] = 2; + 268 53 : addRoom( + 269 : "lss-daedalus", + 270 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 271 : "The salvage operations vehicle. It's\n" + 272 : "tracked remotely, to prevent \n" + 273 : "escapes. If I try taking outside \n" + 274 : "the predicted path, I will sink into\n" + 275 : "the abyss myself.", + 276 : #endif + 277 : 32, 32, 0, connections); + 278 : + 279 : /* 2 */ + 280 53 : connections[2] = 1; + 281 53 : connections[1] = 6; + 282 53 : connections[0] = 3; + 283 53 : addRoom("hangar", + 284 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 285 : "The main hangar is rather \n" + 286 : "unremarkable. The only thing you \n" + 287 : "notice is a slight yellow tint of \n" + 288 : "the air, as if a mist slides next \n" + 289 : "to the floor. It's very faint. Your\n" + 290 : "ship's computer tells you this is\n" + 291 : "harmless (as if those readings were\n" + 292 : "worth the trust). Unfortunately, no\n" + 293 : "useful tools around here. Around the\n" + 294 : "corner, there's a escape pod entrance.\n" + 295 : "Apparently, only one pod was launched.", + 296 : #endif + 297 : 32, 32, 0, connections); + 298 : + 299 : /* 3 */ + 300 53 : connections[2] = 0; + 301 53 : connections[3] = 2; + 302 53 : connections[0] = 4; + 303 53 : connections[1] = 5; + 304 53 : addRoom("hall-2", + 305 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 306 : "A well lit hall, with doors. It's \n" + 307 : "the main hub of the vehicle. Despite\n" + 308 : "being right next to the hangar and\n" + 309 : "the control room, it's rather quiet.", + 310 : #endif + 311 : 32, 32, 0, connections); + 312 : + 313 : /* 4 */ + 314 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 315 53 : connections[2] = 3; + 316 53 : connections[4] = 19; + 317 53 : connections[5] = 13; + 318 53 : addRoom("elevator-level-2", + 319 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 320 : "It's rather surprising that this \n" + 321 : "ship has an elevator. This is was\n" + 322 : "typical only of ships with 5 levels\n" + 323 : "or more.", + 324 : #endif + 325 53 : 64, 64, 0, connections)->rankRequired = 1; + 326 : + 327 : /* 5 */ + 328 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 329 53 : connections[3] = 3; + 330 53 : connections[1] = 9; + 331 53 : connections[0] = 7; + 332 53 : connections[2] = 8; + 333 53 : addRoom("dorms-1", + 334 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 335 : "Part of the dorms hallway. There are\n" + 336 : "some (busted) control panels for \n" + 337 : "ejecting the pods. Some pieces of \n" + 338 : "cloth and broken plastic on the floor,\n" + 339 : "but nothing really useful.", + 340 : #endif + 341 53 : 32, 32, 0, connections)->rankRequired = 1; + 342 : + 343 : + 344 : /* 6 */ + 345 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 346 53 : connections[3] = 2; + 347 53 : addRoom("rls-bohr-2", + 348 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 349 : "A rescue ship. Only for emergencies.\n" + 350 : "Named after some Niels Bohr scientist\n" + 351 : "guy or whatever. Some drops on the\n" + 352 : "carpet and I don't even want know \n" + 353 : "what it is, but I guess I already\n" + 354 : "know. Ick.", + 355 : #endif + 356 : 64, 9, 0, connections); + 357 : + 358 : + 359 : /* 7 */ + 360 53 : connections[3] = 0; + 361 53 : connections[2] = 5; + 362 53 : addRoom("pod-1", + 363 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 364 : "A living pod. Looks like from one \n" + 365 : "of the oficcers. It's messy, but \n" + 366 : "as if it's occupant would easily \n" + 367 : "find his belongings in there. \n" + 368 : "There are some burn marks on the \n" + 369 : "walls.", + 370 : #endif + 371 53 : 32, 32, 0, connections)->rankRequired = 1; + 372 : + 373 : /* 8 */ + 374 53 : connections[2] = 0; + 375 53 : connections[0] = 5; + 376 53 : addRoom("pod-2", + 377 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 378 : "A empty living pod. Looks as if it\n" + 379 : "was never ever used. If can even \n" + 380 : "see some of the factory stickers \n" + 381 : "in it.", + 382 : #endif + 383 53 : 32, 32, 0, connections)->rankRequired = 2; + 384 : + 385 : /* 9 */ + 386 53 : connections[1] = 12; + 387 53 : connections[3] = 5; + 388 53 : connections[0] = 10; + 389 53 : connections[2] = 11; + 390 53 : addRoom("dorms-2", + 391 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 392 : "Anonther part of the dorms hallway.\n" + 393 : "On those, the panels were visibly\n" + 394 : "well. These parts of the quarters \n" + 395 : "were probably the more prestigious ones.", + 396 : #endif + 397 53 : 32, 32, 0, connections)->rankRequired = 1; + 398 : + 399 : /* 10 */ + 400 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 401 53 : connections[2] = 9; + 402 53 : addRoom("pod-3", + 403 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 404 : "A young woman's pod. You \n" + 405 : "do recognize a few items, but its \n" + 406 : "badly mixed up. It's hard to make \n" + 407 : "the age of girl, but she was young.", + 408 : #endif + 409 53 : 32, 32, 0, connections)->rankRequired = 3; + 410 : + 411 : /* 11 */ + 412 53 : connections[2] = 0; + 413 53 : connections[0] = 9; + 414 53 : addRoom("pod-4", + 415 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 416 : "A the first officer's pod, for sure.\n" + 417 : "It's neat, clean and organized. Not \n" + 418 : "much around. He had a strange \n" + 419 : "fixation on redheads.", + 420 : #endif + 421 53 : 32, 32, 0, connections)->rankRequired = 4; + 422 : + 423 : /* 12 */ + 424 53 : connections[0] = 0; + 425 53 : connections[3] = 9; + 426 53 : addRoom("computer-core", + 427 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 428 : "TBD.", + 429 : #endif + 430 : 32, 32, 0, connections); + 431 : + 432 : /* 13 */ + 433 53 : connections[3] = 0; + 434 53 : connections[4] = 4; + 435 53 : connections[2] = 14; + 436 53 : addRoom("elevator-level-1", + 437 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 438 : "It's rather surprising that this ship\n" + 439 : "has an elevator. This is was typical \n" + 440 : "only of ships with 5 levels or more.", + 441 : #endif + 442 53 : 32, 32, 0, connections)->rankRequired = 1; + 443 : + 444 : /* 14 */ + 445 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 446 53 : connections[0] = 13; + 447 53 : connections[1] = 17; + 448 53 : connections[2] = 16; + 449 53 : connections[3] = 15; + 450 53 : addRoom("hall-1", + 451 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 452 : "This hall has a busier feel.\n" + 453 : "Here you see objects thrown all over \n" + 454 : "the place, as if someone was in the \n" + 455 : "middle of a day-to-day routine and had\n" + 456 : "to quickly run.", + 457 : #endif + 458 53 : 32, 32, 0, connections)->rankRequired = 1; + 459 : + 460 : /* 15 */ + 461 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 462 53 : connections[1] = 14; + 463 53 : addRoom("bridge", + 464 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 465 : "TBD.", + 466 : #endif + 467 53 : 32, 32, 0, connections)->rankRequired = 4; + 468 : + 469 : /* 16 */ + 470 53 : connections[1] = 0; + 471 53 : connections[0] = 14; + 472 53 : addRoom("situation-room", + 473 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 474 : "TBD.", + 475 : #endif + 476 53 : 32, 32, 0, connections)->rankRequired = 3; + 477 : + 478 : /* 17 */ + 479 53 : connections[0] = 0; + 480 53 : connections[3] = 14; + 481 53 : connections[1] = 18; + 482 53 : addRoom("crew-bunks", + 483 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 484 : "TBD.", + 485 : #endif + 486 53 : 32, 32, 0, connections)->rankRequired = 1; + 487 : + 488 : /* 18 */ + 489 53 : connections[1] = 0; + 490 53 : connections[3] = 17; + 491 53 : addRoom("armory", + 492 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 493 : "TBD", + 494 : #endif + 495 53 : 32, 32, 0, connections)->rankRequired = 3; + 496 : + 497 : /* 19 */ + 498 53 : connections[3] = 0; + 499 53 : connections[2] = 20; + 500 53 : connections[5] = 4; + 501 53 : addRoom("elevator-level-3", + 502 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 503 : "It's rather surprising that this ship has an\n" + 504 : "elevator. This is was typical only of ships \n" + 505 : "with 5 levels or more.", + 506 : #endif + 507 53 : 32, 32, 0, connections)->rankRequired = 1; + 508 : + 509 : /* 20 */ + 510 53 : memFill(&connections[0], 0, 6 * sizeof(int8_t)); + 511 53 : connections[0] = 19; + 512 53 : connections[1] = 21; + 513 53 : connections[3] = 23; + 514 53 : addRoom("hall-3", + 515 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 516 : "TBD", + 517 : #endif + 518 : 32, 32, 0, connections); + 519 : + 520 : /* 21 */ + 521 53 : connections[0] = 0; + 522 53 : connections[3] = 20; + 523 53 : connections[1] = 22; + 524 53 : addRoom("wc", + 525 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 526 : "TBD.", + 527 : #endif + 528 : 32, 32, 0, connections); + 529 : + 530 : /* 22 */ + 531 53 : connections[1] = 0; + 532 53 : connections[3] = 21; + 533 53 : addRoom("reactor-core", + 534 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 535 : "TBD.", + 536 : #endif + 537 53 : 32, 32, 0, connections)->rankRequired = 4; + 538 : + 539 : /* 23 */ + 540 53 : connections[3] = 0; + 541 53 : connections[1] = 20; + 542 53 : addRoom("radar-array", + 543 : #ifdef INCLUDE_ROOM_DESCRIPTIONS + 544 : "TBD", + 545 : #endif + 546 53 : 32, 32, 0, connections)->rankRequired = 2; + 547 : + 548 : + 549 : /*Items*/ + 550 53 : addItem("dummy", + 551 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 552 : "ERROR", 553 : #endif - 554 : FALSE, 0, 0); - 555 : - 556 : /* LSS-Daedalus */ - 557 55 : newItem = addItem("emp-bomb", - 558 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 559 : "Time-programmable Halogen EMP bomb.\n" - 560 : "Will disable any electrical device\n" - 561 : "within the 50 nautical miles range.", - 562 : #endif - 563 : #ifdef ITEMS_HAVE_WEIGHT - 564 : 5, + 554 : #ifdef ITEMS_HAVE_WEIGHT + 555 : 0, + 556 : #endif + 557 : FALSE, 0, 0); + 558 : + 559 : /* LSS-Daedalus */ + 560 53 : newItem = addItem("emp-bomb", + 561 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 562 : "Time-programmable Halogen EMP bomb.\n" + 563 : "Will disable any electrical device\n" + 564 : "within the 50 nautical miles range.", 565 : #endif - 566 : TRUE, 9, 6); - 567 55 : addToRoom("lss-daedalus", newItem); - 568 55 : newItem->useCallback = bombActivatedCallback; - 569 : - 570 : - 571 55 : newItem = addItem("emp-controller", - 572 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 573 : "The remote controller allows you to\n" - 574 : "instantly detonate the bomb from very\n" - 575 : "far (empirical evidence tells it \n" - 576 : "works from as far as 200 nautical\n" - 577 : "miles).", - 578 : #endif - 579 : #ifdef ITEMS_HAVE_WEIGHT - 580 : 0, + 566 : #ifdef ITEMS_HAVE_WEIGHT + 567 : 5, + 568 : #endif + 569 : TRUE, 9, 6); + 570 53 : addToRoom("lss-daedalus", newItem); + 571 53 : newItem->useCallback = bombActivatedCallback; + 572 : + 573 : + 574 53 : newItem = addItem("emp-controller", + 575 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 576 : "The remote controller allows you to\n" + 577 : "instantly detonate the bomb from very\n" + 578 : "far (empirical evidence tells it \n" + 579 : "works from as far as 200 nautical\n" + 580 : "miles).", 581 : #endif - 582 : TRUE, 10, 6); - 583 55 : addToRoom("lss-daedalus", newItem); - 584 55 : newItem->useCallback = bombControllerActivatedCallback; - 585 : - 586 55 : newItem = addItem("ship-ignition", - 587 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 588 : "Token needed to ignite the ship's\n" - 589 : "computer and thrusters", - 590 : #endif - 591 : #ifdef ITEMS_HAVE_WEIGHT - 592 : 0, + 582 : #ifdef ITEMS_HAVE_WEIGHT + 583 : 0, + 584 : #endif + 585 : TRUE, 10, 6); + 586 53 : addToRoom("lss-daedalus", newItem); + 587 53 : newItem->useCallback = bombControllerActivatedCallback; + 588 : + 589 53 : newItem = addItem("ship-ignition", + 590 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 591 : "Token needed to ignite the ship's\n" + 592 : "computer and thrusters", 593 : #endif - 594 : TRUE, 11, 6); - 595 55 : addToRoom("lss-daedalus", newItem); - 596 55 : newItem->useCallback = bombActivatedCallback; - 597 : - 598 55 : newItem = addItem("magnetic-boots", - 599 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 600 : "Boots with strong electro-magnets.\n" - 601 : "Ideal for walking underwater...\n" - 602 : "...as long as the surface in question\n" - 603 : "is metallic (like most of the \n" - 604 : "surfaces here).", - 605 : #endif - 606 : #ifdef ITEMS_HAVE_WEIGHT - 607 : 2, + 594 : #ifdef ITEMS_HAVE_WEIGHT + 595 : 0, + 596 : #endif + 597 : TRUE, 11, 6); + 598 53 : addToRoom("lss-daedalus", newItem); + 599 53 : newItem->useCallback = bombActivatedCallback; + 600 : + 601 53 : newItem = addItem("magnetic-boots", + 602 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 603 : "Boots with strong electro-magnets.\n" + 604 : "Ideal for walking underwater...\n" + 605 : "...as long as the surface in question\n" + 606 : "is metallic (like most of the \n" + 607 : "surfaces here).", 608 : #endif - 609 : TRUE, 15, 15); - 610 : - 611 55 : newItem->active = TRUE; - 612 55 : pickObject(newItem); - 613 55 : newItem->pickable = FALSE; - 614 55 : newItem->useWithCallback = useBootsWithMagneticCoupling; - 615 : - 616 55 : newItem = addItem("helmet", - 617 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 618 : "Atmosphere-contained helmet for\n" - 619 : "safety.", - 620 : #endif - 621 : #ifdef ITEMS_HAVE_WEIGHT - 622 : 2, + 609 : #ifdef ITEMS_HAVE_WEIGHT + 610 : 2, + 611 : #endif + 612 : TRUE, 15, 15); + 613 : + 614 53 : newItem->active = TRUE; + 615 53 : pickObject(newItem); + 616 53 : newItem->pickable = FALSE; + 617 53 : newItem->useWithCallback = useBootsWithMagneticCoupling; + 618 : + 619 53 : newItem = addItem("helmet", + 620 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 621 : "Atmosphere-contained helmet for\n" + 622 : "safety.", 623 : #endif - 624 : TRUE, 15, 15); - 625 55 : newItem->active = TRUE; - 626 55 : pickObject(newItem); - 627 55 : newItem->pickable = FALSE; - 628 55 : newItem->useWithCallback = inspectItemWithHelmetCallback; - 629 : - 630 : - 631 55 : newItem = addItem("low-rank-keycard", - 632 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 633 : "Clearance for low rank. Oddly, \n" - 634 : "this one is of the rewrittable kind;\n" - 635 : "probably due to a field promotion.", - 636 : #endif - 637 : #ifdef ITEMS_HAVE_WEIGHT - 638 : 0, + 624 : #ifdef ITEMS_HAVE_WEIGHT + 625 : 2, + 626 : #endif + 627 : TRUE, 15, 15); + 628 53 : newItem->active = TRUE; + 629 53 : pickObject(newItem); + 630 53 : newItem->pickable = FALSE; + 631 53 : newItem->useWithCallback = inspectItemWithHelmetCallback; + 632 : + 633 : + 634 53 : newItem = addItem("low-rank-keycard", + 635 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 636 : "Clearance for low rank. Oddly, \n" + 637 : "this one is of the rewrittable kind;\n" + 638 : "probably due to a field promotion.", 639 : #endif - 640 : TRUE, 4, 7); - 641 55 : addToRoom("hall-2", newItem); - 642 55 : newItem->useWithCallback = useCardWithCardWriter; - 643 55 : newItem->pickCallback = keycardPickCallback; - 644 55 : newItem->dropCallback = keycardDropCallback; - 645 : - 646 : - 647 55 : newItem = addItem("hacked-keycard", - 648 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 649 : "Hacked keycard for mid-clearance\nrank.", - 650 : #endif - 651 : #ifdef ITEMS_HAVE_WEIGHT - 652 : 0, + 640 : #ifdef ITEMS_HAVE_WEIGHT + 641 : 0, + 642 : #endif + 643 : TRUE, 4, 7); + 644 53 : addToRoom("hall-2", newItem); + 645 53 : newItem->useWithCallback = useCardWithCardWriter; + 646 53 : newItem->pickCallback = keycardPickCallback; + 647 53 : newItem->dropCallback = keycardDropCallback; + 648 : + 649 : + 650 53 : newItem = addItem("hacked-keycard", + 651 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 652 : "Hacked keycard for mid-clearance\nrank.", 653 : #endif - 654 : TRUE, 21, 9); - 655 55 : newItem->pickCallback = keycardPickCallback; - 656 55 : newItem->dropCallback = keycardDropCallback; - 657 : - 658 : /* Hangar */ - 659 : - 660 55 : newItem = addItem("magnetic-coupling", - 661 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 662 : "Automatic seal activated by \nspecial safety protocols", - 663 : #endif - 664 : #ifdef ITEMS_HAVE_WEIGHT - 665 : 17, - 666 : #endif - 667 : FALSE, 2, 2); - 668 55 : addToRoom("hangar", newItem); - 669 55 : newItem->active = TRUE; - 670 : - 671 : /* Comm terminals*/ - 672 : - 673 55 : newItem = addItem("door-panel", - 674 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 675 : "Special control for the door", - 676 : #endif - 677 : #ifdef ITEMS_HAVE_WEIGHT - 678 : 200, - 679 : #endif - 680 : FALSE, 12, 3); - 681 55 : addToRoom("hangar", newItem); - 682 : - 683 : - 684 : /* Comm terminals*/ - 685 55 : newItem = addItem("comm-terminal-1", - 686 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 687 : "Terminal for communicating with\nthe central computer.", - 688 : #endif - 689 : #ifdef ITEMS_HAVE_WEIGHT - 690 : 200, - 691 : #endif - 692 : FALSE, 7, 2); - 693 55 : newItem->useCallback = useCommWithRank; - 694 55 : addToRoom("hall-1", newItem); - 695 : - 696 : - 697 55 : newItem = addItem("comm-terminal-2", - 698 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 699 : "Terminal for communicating with\nthe central computer.", - 700 : #endif - 701 : #ifdef ITEMS_HAVE_WEIGHT - 702 : 200, + 654 : #ifdef ITEMS_HAVE_WEIGHT + 655 : 0, + 656 : #endif + 657 : TRUE, 21, 9); + 658 53 : newItem->useWithCallback = useKeycardWith; + 659 53 : newItem->pickCallback = keycardPickCallback; + 660 53 : newItem->dropCallback = keycardDropCallback; + 661 : + 662 : /* Hangar */ + 663 : + 664 53 : newItem = addItem("magnetic-coupling", + 665 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 666 : "Automatic seal activated by \nspecial safety protocols", + 667 : #endif + 668 : #ifdef ITEMS_HAVE_WEIGHT + 669 : 17, + 670 : #endif + 671 : FALSE, 2, 2); + 672 53 : addToRoom("hangar", newItem); + 673 53 : newItem->active = TRUE; + 674 : + 675 : /* Comm terminals*/ + 676 : + 677 53 : newItem = addItem("door-panel", + 678 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 679 : "Special control for the door", + 680 : #endif + 681 : #ifdef ITEMS_HAVE_WEIGHT + 682 : 200, + 683 : #endif + 684 : FALSE, 12, 3); + 685 53 : addToRoom("hangar", newItem); + 686 : + 687 : + 688 : /* Comm terminals*/ + 689 53 : newItem = addItem("comm-terminal-1", + 690 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 691 : "Terminal for communicating with\nthe central computer.", + 692 : #endif + 693 : #ifdef ITEMS_HAVE_WEIGHT + 694 : 200, + 695 : #endif + 696 : FALSE, 7, 2); + 697 53 : addToRoom("hall-1", newItem); + 698 : + 699 : + 700 53 : newItem = addItem("comm-terminal-2", + 701 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 702 : "Terminal for communicating with\nthe central computer.", 703 : #endif - 704 : FALSE, 6, 2); - 705 55 : newItem->useCallback = useCommWithRank; - 706 55 : addToRoom("hall-2", newItem); - 707 : - 708 : - 709 55 : newItem = addItem("comm-terminal-3", - 710 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 711 : "Terminal for communicating with\nthe central computer.", - 712 : #endif - 713 : #ifdef ITEMS_HAVE_WEIGHT - 714 : 200, - 715 : #endif - 716 : FALSE, 7, 2); - 717 55 : newItem->useCallback = useCommWithRank; - 718 55 : addToRoom("hall-3", newItem); - 719 : - 720 : /* Diaries */ - 721 55 : newItem = addItem("black-diary", - 722 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 723 : "...We meet every night in the rest\n" - 724 : "room, to make out. I asked her for\n" - 725 : "an access key for the armory - let's\n" - 726 : " see if she keeps her promisse. If\n" - 727 : "they catch me, I'm scr...", - 728 : #endif - 729 : #ifdef ITEMS_HAVE_WEIGHT - 730 : 0, - 731 : #endif - 732 : TRUE, 4, 6); - 733 55 : addToRoom("pod-1", newItem); - 734 : + 704 : #ifdef ITEMS_HAVE_WEIGHT + 705 : 200, + 706 : #endif + 707 : FALSE, 6, 2); + 708 53 : addToRoom("hall-2", newItem); + 709 : + 710 : + 711 53 : newItem = addItem("comm-terminal-3", + 712 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 713 : "Terminal for communicating with\nthe central computer.", + 714 : #endif + 715 : #ifdef ITEMS_HAVE_WEIGHT + 716 : 200, + 717 : #endif + 718 : FALSE, 7, 2); + 719 53 : addToRoom("hall-3", newItem); + 720 : + 721 : /* Diaries */ + 722 53 : newItem = addItem("black-diary", + 723 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 724 : "...We meet every night in the rest\n" + 725 : "room, to make out. I asked her for\n" + 726 : "an access key for the armory - let's\n" + 727 : " see if she keeps her promisse. If\n" + 728 : "they catch me, I'm scr...", + 729 : #endif + 730 : #ifdef ITEMS_HAVE_WEIGHT + 731 : 0, + 732 : #endif + 733 : TRUE, 4, 6); + 734 53 : addToRoom("pod-1", newItem); 735 : - 736 55 : newItem = addItem("blue-diary", - 737 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 738 : "The growing discontent is very \n" - 739 : "noticeable. I don't know for how\n" - 740 : "long can we keep the situation\n" - 741 : "stable. For safety, I gave the root\n" - 742 : "keycard to first officer Costa.", - 743 : #endif - 744 : #ifdef ITEMS_HAVE_WEIGHT - 745 : 0, - 746 : #endif - 747 : TRUE, 11, 8); - 748 55 : addToRoom("pod-2", newItem); - 749 : + 736 : + 737 53 : newItem = addItem("blue-diary", + 738 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 739 : "The growing discontent is very \n" + 740 : "noticeable. I don't know for how\n" + 741 : "long can we keep the situation\n" + 742 : "stable. For safety, I gave the root\n" + 743 : "keycard to first officer Costa.", + 744 : #endif + 745 : #ifdef ITEMS_HAVE_WEIGHT + 746 : 0, + 747 : #endif + 748 : TRUE, 11, 8); + 749 53 : addToRoom("pod-2", newItem); 750 : - 751 55 : newItem = addItem("white-diary", - 752 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 753 : "Crew is growing demotivated with\n" - 754 : "all the combat exercises and no \n" - 755 : "downtime. Don't know long can I\n" - 756 : "keep the fact that we already lost\n" - 757 : "the war. If anything goes wrong,\n" - 758 : "the situation room will be our\n" - 759 : "last stand.", - 760 : #endif - 761 : #ifdef ITEMS_HAVE_WEIGHT - 762 : 0, - 763 : #endif - 764 : TRUE, 3, 2); - 765 55 : addToRoom("pod-3", newItem); - 766 : + 751 : + 752 53 : newItem = addItem("white-diary", + 753 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 754 : "Crew is growing demotivated with\n" + 755 : "all the combat exercises and no \n" + 756 : "downtime. Don't know long can I\n" + 757 : "keep the fact that we already lost\n" + 758 : "the war. If anything goes wrong,\n" + 759 : "the situation room will be our\n" + 760 : "last stand.", + 761 : #endif + 762 : #ifdef ITEMS_HAVE_WEIGHT + 763 : 0, + 764 : #endif + 765 : TRUE, 3, 2); + 766 53 : addToRoom("pod-3", newItem); 767 : - 768 55 : newItem = addItem("yellow-book", - 769 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 770 : "Situation is hopeless. I must enact\n" - 771 : "the security lockdown protocol and \n" - 772 : "set the reactor to a low activity \n" - 773 : "state. With luck, they will rescue \n" - 774 : "us in the next weeks or so.", - 775 : #endif - 776 : #ifdef ITEMS_HAVE_WEIGHT - 777 : 0, - 778 : #endif - 779 : TRUE, 5, 10); - 780 55 : addToRoom("pod-4", newItem); - 781 : + 768 : + 769 53 : newItem = addItem("yellow-book", + 770 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 771 : "Situation is hopeless. I must enact\n" + 772 : "the security lockdown protocol and \n" + 773 : "set the reactor to a low activity \n" + 774 : "state. With luck, they will rescue \n" + 775 : "us in the next weeks or so.", + 776 : #endif + 777 : #ifdef ITEMS_HAVE_WEIGHT + 778 : 0, + 779 : #endif + 780 : TRUE, 5, 10); + 781 53 : addToRoom("pod-4", newItem); 782 : - 783 55 : newItem = addItem("log-book", - 784 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 785 : "Power conduit on level 3 was restored\n" - 786 : "without incidents.", - 787 : #endif - 788 : #ifdef ITEMS_HAVE_WEIGHT - 789 : 1, - 790 : #endif - 791 : TRUE, 26, 8); - 792 55 : addToRoom("crew-bunks", newItem); - 793 : - 794 : /* Misc */ - 795 55 : newItem = addItem("card-writer", - 796 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 797 : "Terminal with card writer, connected\n" - 798 : " to the main computer", - 799 : #endif - 800 : #ifdef ITEMS_HAVE_WEIGHT - 801 : 3, - 802 : #endif - 803 : FALSE, 22, 10); - 804 55 : addToRoom("computer-core", newItem); - 805 : + 783 : + 784 53 : newItem = addItem("log-book", + 785 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 786 : "Power conduit on level 3 was restored\n" + 787 : "without incidents.", + 788 : #endif + 789 : #ifdef ITEMS_HAVE_WEIGHT + 790 : 1, + 791 : #endif + 792 : TRUE, 26, 8); + 793 53 : addToRoom("crew-bunks", newItem); + 794 : + 795 : /* Misc */ + 796 53 : newItem = addItem("card-writer", + 797 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 798 : "Terminal with card writer, connected\n" + 799 : " to the main computer", + 800 : #endif + 801 : #ifdef ITEMS_HAVE_WEIGHT + 802 : 3, + 803 : #endif + 804 : FALSE, 22, 10); + 805 53 : addToRoom("computer-core", newItem); 806 : - 807 55 : newItem = addItem("high-rank-keycard", - 808 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 809 : "Clearance for high-rank officer.", - 810 : #endif - 811 : #ifdef ITEMS_HAVE_WEIGHT - 812 : 0, - 813 : #endif - 814 : TRUE, 23, 17); - 815 55 : newItem->pickCallback = keycardPickCallback; - 816 55 : newItem->dropCallback = keycardDropCallback; - 817 : - 818 : - 819 55 : newItem = addItem("digital-safe", - 820 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 821 : "A very valuable vintage rare and in\n" - 822 : "working-conditions computer rack!", - 823 : #endif - 824 : #ifdef ITEMS_HAVE_WEIGHT - 825 : 138, - 826 : #endif - 827 : FALSE, 16, 4); - 828 55 : newItem->useCallback = useComputerRack; - 829 55 : addToRoom("situation-room", newItem); - 830 : - 831 55 : newItem = addItem("computer-terminal", - 832 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 833 : "An offline terminal connected to the\n" - 834 : "computer node", - 835 : #endif - 836 : #ifdef ITEMS_HAVE_WEIGHT - 837 : 138, - 838 : #endif - 839 : FALSE, 16, 5); - 840 55 : newItem->useCallback = useComputerRack; - 841 55 : addToRoom("situation-room", newItem); - 842 : - 843 : - 844 55 : newItem = addItem("journal", - 845 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 846 : "...and so you guys could just join in\n" - 847 : "and see whats going on. I hope it is not\n" - 848 : "too instrusive of me. To that, she just\n" - 849 : "gave me a cold stare and...", - 850 : #endif - 851 : #ifdef ITEMS_HAVE_WEIGHT - 852 : 0, - 853 : #endif - 854 : TRUE, 8, 6); - 855 55 : addToRoom("situation-room", newItem); - 856 : - 857 55 : newItem = addItem("metal-mending", - 858 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 859 : "A piece of metal that might be valuable.", - 860 : #endif - 861 : #ifdef ITEMS_HAVE_WEIGHT - 862 : 74, - 863 : #endif - 864 : FALSE, 5, 4); - 865 55 : addToRoom("radar-array", newItem); - 866 : - 867 : - 868 55 : newItem = addItem("scientific-treatise", - 869 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 870 : "Voynich Manuscript\nAnnottated Translation.\n" - 871 : "Classical edition. It's badly burn't.\n" - 872 : "Can't read it.", - 873 : #endif - 874 : #ifdef ITEMS_HAVE_WEIGHT - 875 : 1, - 876 : #endif - 877 : TRUE, 17, 17); - 878 55 : addToRoom("wc", newItem); - 879 : - 880 : - 881 55 : newItem = addItem("clogged-flush", - 882 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 883 : "There is so much matter in the pipe...", - 884 : #endif - 885 : #ifdef ITEMS_HAVE_WEIGHT - 886 : 1, - 887 : #endif - 888 : FALSE, 22, 17); - 889 55 : newItem->useCallback = useCloggedFlush; - 890 55 : addToRoom("wc", newItem); - 891 : - 892 55 : newItem = addItem("flush", - 893 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 894 : "Working dispose valve for a very basic need.", - 895 : #endif - 896 : #ifdef ITEMS_HAVE_WEIGHT - 897 : 1, - 898 : #endif - 899 : FALSE, 18, 17); - 900 55 : newItem->useCallback = useRegularFlush; - 901 55 : addToRoom("wc", newItem); - 902 : - 903 : - 904 55 : newItem = addItem("fuel-rods", - 905 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 906 : "This is the source of all the trouble.\n" - 907 : "Both now and then. Gotta find a way to\n" - 908 : "eject those into the abyss.", - 909 : #endif - 910 : #ifdef ITEMS_HAVE_WEIGHT - 911 : 209, - 912 : #endif - 913 : FALSE, 29, 10); - 914 55 : addToRoom("reactor-core", newItem); - 915 : - 916 : - 917 55 : newItem = addItem("reactor-valve-control", - 918 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 919 : "This is the computer node that could be\n" - 920 : "used to eject the rods into the abyss.", - 921 : #endif - 922 : #ifdef ITEMS_HAVE_WEIGHT - 923 : 62, - 924 : #endif - 925 : FALSE, 21, 4); - 926 55 : newItem->useCallback = reactorValveCallback; - 927 55 : addToRoom("reactor-core", newItem); - 928 : - 929 : - 930 55 : newItem = addItem("root-keycard", - 931 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 932 : "Card for root access.", - 933 : #endif - 934 : #ifdef ITEMS_HAVE_WEIGHT - 935 : 0, - 936 : #endif - 937 : TRUE, 16, 3); - 938 55 : newItem->pickCallback = keycardPickCallback; - 939 55 : newItem->dropCallback = keycardDropCallback; - 940 : - 941 : /* Elevator controls */ - 942 55 : newItem = addItem("elevator-level1-go-down", - 943 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 944 : "Elevator controls - Go down.", - 945 : #endif - 946 : #ifdef ITEMS_HAVE_WEIGHT - 947 : 0, - 948 : #endif - 949 : FALSE, 2, 0); - 950 55 : newItem->useCallback = elevatorGoDownCallback; - 951 55 : addToRoom("elevator-level-1", newItem); - 952 : - 953 55 : newItem = addItem("elevator-level2-go-down", - 954 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 955 : "Elevator controls - Go down.", - 956 : #endif - 957 : #ifdef ITEMS_HAVE_WEIGHT - 958 : 0, - 959 : #endif - 960 : FALSE, 2, 0); - 961 55 : newItem->useCallback = elevatorGoDownCallback; - 962 55 : addToRoom("elevator-level-2", newItem); - 963 : - 964 55 : newItem = addItem("elevator-level2-go-up", - 965 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 966 : "Elevator controls - Go Up.", - 967 : #endif - 968 : #ifdef ITEMS_HAVE_WEIGHT - 969 : 0, - 970 : #endif - 971 : FALSE, 3, 0); - 972 55 : newItem->useCallback = elevatorGoUpCallback; - 973 55 : addToRoom("elevator-level-2", newItem); - 974 : - 975 55 : newItem = addItem("elevator-level3-go-up", - 976 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 977 : "Elevator controls - Go Up.", - 978 : #endif - 979 : #ifdef ITEMS_HAVE_WEIGHT - 980 : 0, - 981 : #endif - 982 : FALSE, 3, 0); - 983 55 : newItem->useCallback = elevatorGoUpCallback; - 984 55 : addToRoom("elevator-level-3", newItem); - 985 : - 986 55 : newItem = addItem("the-mistral-report", - 987 : #ifdef INCLUDE_ITEM_DESCRIPTIONS - 988 : "RetroZaragoza Homebrew '18 awarded\nentry: A espionage-themed \nturn-based 3D RPG for MS-DOS,\nXBox One, Mac and Amiga.", - 989 : #endif - 990 : #ifdef ITEMS_HAVE_WEIGHT - 991 : 200, - 992 : #endif - 993 : TRUE, 15, 19); - 994 55 : addToRoom("crew-bunks", newItem); - 995 55 : } + 807 : + 808 53 : newItem = addItem("high-rank-keycard", + 809 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 810 : "Clearance for high-rank officer.", + 811 : #endif + 812 : #ifdef ITEMS_HAVE_WEIGHT + 813 : 0, + 814 : #endif + 815 : TRUE, 23, 17); + 816 53 : newItem->useWithCallback = useKeycardWith; + 817 53 : newItem->pickCallback = keycardPickCallback; + 818 53 : newItem->dropCallback = keycardDropCallback; + 819 : + 820 : + 821 53 : newItem = addItem("digital-safe", + 822 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 823 : "A very valuable vintage rare and in\n" + 824 : "working-conditions computer rack!", + 825 : #endif + 826 : #ifdef ITEMS_HAVE_WEIGHT + 827 : 138, + 828 : #endif + 829 : FALSE, 16, 4); + 830 53 : newItem->useCallback = useComputerRack; + 831 53 : addToRoom("situation-room", newItem); + 832 : + 833 53 : newItem = addItem("computer-terminal", + 834 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 835 : "An offline terminal connected to the\n" + 836 : "computer node", + 837 : #endif + 838 : #ifdef ITEMS_HAVE_WEIGHT + 839 : 138, + 840 : #endif + 841 : FALSE, 16, 5); + 842 53 : newItem->useCallback = useComputerRack; + 843 53 : addToRoom("situation-room", newItem); + 844 : + 845 : + 846 53 : newItem = addItem("journal", + 847 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 848 : "...and so you guys could just join in\n" + 849 : "and see whats going on. I hope it is not\n" + 850 : "too instrusive of me. To that, she just\n" + 851 : "gave me a cold stare and...", + 852 : #endif + 853 : #ifdef ITEMS_HAVE_WEIGHT + 854 : 0, + 855 : #endif + 856 : TRUE, 8, 6); + 857 53 : addToRoom("situation-room", newItem); + 858 : + 859 53 : newItem = addItem("metal-mending", + 860 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 861 : "A piece of metal that might be valuable.", + 862 : #endif + 863 : #ifdef ITEMS_HAVE_WEIGHT + 864 : 74, + 865 : #endif + 866 : FALSE, 5, 4); + 867 53 : addToRoom("radar-array", newItem); + 868 : + 869 : + 870 53 : newItem = addItem("scientific-treatise", + 871 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 872 : "Voynich Manuscript\nAnnottated Translation.\n" + 873 : "Classical edition. It's badly burn't.\n" + 874 : "Can't read it.", + 875 : #endif + 876 : #ifdef ITEMS_HAVE_WEIGHT + 877 : 1, + 878 : #endif + 879 : TRUE, 17, 17); + 880 53 : addToRoom("wc", newItem); + 881 : + 882 : + 883 53 : newItem = addItem("clogged-flush", + 884 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 885 : "There is so much matter in the pipe...", + 886 : #endif + 887 : #ifdef ITEMS_HAVE_WEIGHT + 888 : 1, + 889 : #endif + 890 : FALSE, 22, 17); + 891 53 : newItem->useCallback = useCloggedFlush; + 892 53 : addToRoom("wc", newItem); + 893 : + 894 53 : newItem = addItem("flush", + 895 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 896 : "Working dispose valve for a very basic need.", + 897 : #endif + 898 : #ifdef ITEMS_HAVE_WEIGHT + 899 : 1, + 900 : #endif + 901 : FALSE, 18, 17); + 902 53 : newItem->useCallback = useRegularFlush; + 903 53 : addToRoom("wc", newItem); + 904 : + 905 : + 906 53 : newItem = addItem("fuel-rods", + 907 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 908 : "This is the source of all the trouble.\n" + 909 : "Both now and then. Gotta find a way to\n" + 910 : "eject those into the abyss.", + 911 : #endif + 912 : #ifdef ITEMS_HAVE_WEIGHT + 913 : 209, + 914 : #endif + 915 : FALSE, 29, 10); + 916 53 : addToRoom("reactor-core", newItem); + 917 : + 918 : + 919 53 : newItem = addItem("reactor-valve-control", + 920 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 921 : "This is the computer node that could be\n" + 922 : "used to eject the rods into the abyss.", + 923 : #endif + 924 : #ifdef ITEMS_HAVE_WEIGHT + 925 : 62, + 926 : #endif + 927 : FALSE, 21, 4); + 928 53 : newItem->useCallback = reactorValveCallback; + 929 53 : addToRoom("reactor-core", newItem); + 930 : + 931 : + 932 53 : newItem = addItem("root-keycard", + 933 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 934 : "Card for root access.", + 935 : #endif + 936 : #ifdef ITEMS_HAVE_WEIGHT + 937 : 0, + 938 : #endif + 939 : TRUE, 16, 3); + 940 53 : newItem->pickCallback = keycardPickCallback; + 941 53 : newItem->dropCallback = keycardDropCallback; + 942 : + 943 : /* Elevator controls */ + 944 53 : newItem = addItem("elevator-level1-go-down", + 945 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 946 : "Elevator controls - Go down.", + 947 : #endif + 948 : #ifdef ITEMS_HAVE_WEIGHT + 949 : 0, + 950 : #endif + 951 : FALSE, 2, 0); + 952 53 : newItem->useCallback = elevatorGoDownCallback; + 953 53 : addToRoom("elevator-level-1", newItem); + 954 : + 955 53 : newItem = addItem("elevator-level2-go-down", + 956 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 957 : "Elevator controls - Go down.", + 958 : #endif + 959 : #ifdef ITEMS_HAVE_WEIGHT + 960 : 0, + 961 : #endif + 962 : FALSE, 2, 0); + 963 53 : newItem->useCallback = elevatorGoDownCallback; + 964 53 : addToRoom("elevator-level-2", newItem); + 965 : + 966 53 : newItem = addItem("elevator-level2-go-up", + 967 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 968 : "Elevator controls - Go Up.", + 969 : #endif + 970 : #ifdef ITEMS_HAVE_WEIGHT + 971 : 0, + 972 : #endif + 973 : FALSE, 3, 0); + 974 53 : newItem->useCallback = elevatorGoUpCallback; + 975 53 : addToRoom("elevator-level-2", newItem); + 976 : + 977 53 : newItem = addItem("elevator-level3-go-up", + 978 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 979 : "Elevator controls - Go Up.", + 980 : #endif + 981 : #ifdef ITEMS_HAVE_WEIGHT + 982 : 0, + 983 : #endif + 984 : FALSE, 3, 0); + 985 53 : newItem->useCallback = elevatorGoUpCallback; + 986 53 : addToRoom("elevator-level-3", newItem); + 987 : + 988 53 : newItem = addItem("the-mistral-report", + 989 : #ifdef INCLUDE_ITEM_DESCRIPTIONS + 990 : "RetroZaragoza Homebrew '18 awarded\nentry: A espionage-themed \nturn-based 3D RPG for MS-DOS,\nXBox One, Mac and Amiga.", + 991 : #endif + 992 : #ifdef ITEMS_HAVE_WEIGHT + 993 : 200, + 994 : #endif + 995 : TRUE, 15, 19); + 996 53 : addToRoom("crew-bunks", newItem); + 997 53 : } diff --git a/coverage/src/Parser.c.func-sort-c.html b/coverage/src/Parser.c.func-sort-c.html index ecc6bf725..cf542d3e9 100644 --- a/coverage/src/Parser.c.func-sort-c.html +++ b/coverage/src/Parser.c.func-sort-c.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 1 @@ -61,7 +61,7 @@ parseCommand - 111 + 105
diff --git a/coverage/src/Parser.c.func.html b/coverage/src/Parser.c.func.html index 111fb6af0..dff54b510 100644 --- a/coverage/src/Parser.c.func.html +++ b/coverage/src/Parser.c.func.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 1 @@ -61,7 +61,7 @@ parseCommand - 111 + 105
diff --git a/coverage/src/Parser.c.gcov.html b/coverage/src/Parser.c.gcov.html index 66002d2b9..73dcfdd8e 100644 --- a/coverage/src/Parser.c.gcov.html +++ b/coverage/src/Parser.c.gcov.html @@ -37,7 +37,7 @@ Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 1 @@ -81,20 +81,20 @@ 19 : 20 : #endif 21 : - 22 111 : uint8_t parseCommand(const char *cmd, const char *operand) { - 23 111 : if (!strcmp(cmd, "pick")) { - 24 25 : pickObjectByName(operand); - 25 86 : } else if (!strcmp(cmd, "drop")) { + 22 105 : uint8_t parseCommand(const char *cmd, const char *operand) { + 23 105 : if (!strcmp(cmd, "pick")) { + 24 23 : pickObjectByName(operand); + 25 82 : } else if (!strcmp(cmd, "drop")) { 26 11 : dropObjectByName(operand); - 27 75 : } else if (!strcmp(cmd, "move")) { + 27 71 : } else if (!strcmp(cmd, "move")) { 28 : 29 14 : if (operand != NULL && operand[0] != '\0') { 30 12 : moveBy(operand[0] - '0'); 31 : } else { 32 2 : errorHandlerCallback("Please specify a valid direction"); 33 : } - 34 61 : } else if (!strcmp(cmd, "use")) { - 35 27 : useObjectNamed(operand); + 34 57 : } else if (!strcmp(cmd, "use")) { + 35 23 : useObjectNamed(operand); 36 34 : } else if (!strcmp(cmd, "w")) { 37 4 : walkBy(0); 38 30 : } else if (!strcmp(cmd, "s")) { @@ -120,7 +120,7 @@ 58 1 : return FALSE; 59 : } 60 : - 61 110 : return TRUE; + 61 104 : return TRUE; 62 : } diff --git a/coverage/src/index-sort-f.html b/coverage/src/index-sort-f.html index 3e64641d5..5f896f7cb 100644 --- a/coverage/src/index-sort-f.html +++ b/coverage/src/index-sort-f.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -72,10 +72,10 @@ Derelict.c -
97.8%97.8%
+
96.9%96.9%
- 97.8 % - 313 / 320 + 96.9 % + 311 / 321 83.3 % 15 / 18 diff --git a/coverage/src/index-sort-l.html b/coverage/src/index-sort-l.html index b72226312..827c60517 100644 --- a/coverage/src/index-sort-l.html +++ b/coverage/src/index-sort-l.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -82,10 +82,10 @@ Derelict.c -
97.8%97.8%
+
96.9%96.9%
- 97.8 % - 313 / 320 + 96.9 % + 311 / 321 83.3 % 15 / 18 diff --git a/coverage/src/index.html b/coverage/src/index.html index eb7cc237d..4815bf310 100644 --- a/coverage/src/index.html +++ b/coverage/src/index.html @@ -31,13 +31,13 @@ lcov-output.info Lines: - 709 - 736 - 96.3 % + 707 + 737 + 95.9 % Date: - 2024-07-01 22:09:32 + 2024-07-06 18:47:59 Functions: 60 @@ -82,10 +82,10 @@ Derelict.c -
97.8%97.8%
+
96.9%96.9%
- 97.8 % - 313 / 320 + 96.9 % + 311 / 321 83.3 % 15 / 18 diff --git a/index.html b/index.html index 2ea82c2fe..53d70a0bd 100644 --- a/index.html +++ b/index.html @@ -130,5 +130,5 @@

Technical details

diff --git a/sitemap.xml.gz b/sitemap.xml.gz index e2ead42776d2ff45afa9f3ec1b0d4d692dd107b7..69fc27aa19b85e8d08be2cf393f75b2d43b0494a 100644 GIT binary patch delta 13 Ucmb=gXP58h;9%(Nn8;oM02){W;Q#;t delta 13 Ucmb=gXP58h;Ar^RIFY>q03SpI!T