]> git.pond.sub.org Git - empserver/commit
Use relations_with() for getrel(getnatp(US), THEM) where US!=THEM
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 29 Jan 2011 13:34:40 +0000 (14:34 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Wed, 16 Feb 2011 06:52:25 +0000 (07:52 +0100)
commit8cb7b755574f67e43d752fb46cf090ee6d23177a
tree001aca26910e4544e11a4001be116b5405e52e57
parent6807cd91b5b8aa457ef18885b7dbca5ec8d5de9e
Use relations_with() for getrel(getnatp(US), THEM) where US!=THEM

Replacing getrel(getnatp(US), THEM) by relations_with(US, THEM) makes
a difference only when US equals THEM.  Replace in places where it's
obvious that they're not equal.

Note: getsect() sets player->owner to "player is god or owns this
sector".  Thus, after getsect(..., &sect), sect.sct_own ==
player->cnum implies player->owner.  Conversely, !player->owner
implies sect.sct_own != player->cnum.  Similarly for getship(),
getplane() and nxtitem().
src/lib/commands/arm.c
src/lib/commands/assa.c
src/lib/commands/atta.c
src/lib/commands/load.c
src/lib/commands/scra.c
src/lib/commands/sona.c
src/lib/commands/spy.c
src/lib/commands/tend.c
src/lib/subs/fortdef.c
src/lib/subs/plnsub.c