/*
* Empire - A multi-player, client/server Internet based war game.
- * Copyright (C) 1986-2014, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ * Copyright (C) 1986-2021, Dave Pare, Jeff Bailey, Thomas Ruschak,
* Ken Stevens, Steve McClure, Markus Armbruster
*
* Empire is free software: you can redistribute it and/or modify
#include <ctype.h>
#include "chance.h"
#include "damage.h"
-#include "file.h"
#include "map.h"
#include "nsc.h"
#include "path.h"
curx = start->sct_x;
cury = start->sct_y;
total_mcost = 0.0;
- if (getsect(curx, cury, §) < 0) {
+ if (!getsect(curx, cury, §)) {
logerror("move_path: getsect %d,%d", curx, cury);
return -1;
}
}
if (dir == DIR_MAP) {
parse(movstr, scanspace, argp, NULL, NULL, NULL);
- if (argp[0][1]) {
- pr("Use of '%c' without a space before its argument is deprecated.\n"
- "Support for it will go away in a future release\n",
- *movstr);
- argp[2] = argp[1];
- argp[1] = argp[0] + 1;
- }
if (!exploring)
map(curx, cury, argp[1], argp[2]);
*movstr = 0;
*/
tmpx = curx + diroff[dir][0];
tmpy = cury + diroff[dir][1];
- if (getsect(tmpx, tmpy, &next) < 0) {
+ if (!getsect(tmpx, tmpy, &next)) {
pr("You can't go there...\n");
*movstr = 0;
continue;