forked from github/server
rename race_ to _race, to follow the style guide.
This commit is contained in:
parent
b30de914aa
commit
669712f04f
|
@ -26,7 +26,6 @@ extern "C" {
|
||||||
/* this should always be the first thing included after platform.h */
|
/* this should always be the first thing included after platform.h */
|
||||||
#include "types.h"
|
#include "types.h"
|
||||||
|
|
||||||
struct _dictionary_;
|
|
||||||
/* experimental gameplay features (that don't affect the savefile) */
|
/* experimental gameplay features (that don't affect the savefile) */
|
||||||
/* TODO: move these settings to settings.h or into configuration files */
|
/* TODO: move these settings to settings.h or into configuration files */
|
||||||
#define GOBLINKILL /* Goblin-Spezialklau kann tödlich enden */
|
#define GOBLINKILL /* Goblin-Spezialklau kann tödlich enden */
|
||||||
|
|
|
@ -858,7 +858,7 @@ bool leave(unit * u, bool force)
|
||||||
|
|
||||||
const struct race *urace(const struct unit *u)
|
const struct race *urace(const struct unit *u)
|
||||||
{
|
{
|
||||||
return u->race_;
|
return u->_race;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool can_survive(const unit * u, const region * r)
|
bool can_survive(const unit * u, const region * r)
|
||||||
|
@ -1766,18 +1766,18 @@ const struct race *u_irace(const struct unit *u)
|
||||||
if (u->irace && skill_enabled(SK_STEALTH)) {
|
if (u->irace && skill_enabled(SK_STEALTH)) {
|
||||||
return u->irace;
|
return u->irace;
|
||||||
}
|
}
|
||||||
return u->race_;
|
return u->_race;
|
||||||
}
|
}
|
||||||
|
|
||||||
const struct race *u_race(const struct unit *u)
|
const struct race *u_race(const struct unit *u)
|
||||||
{
|
{
|
||||||
return u->race_;
|
return u->_race;
|
||||||
}
|
}
|
||||||
|
|
||||||
void u_setrace(struct unit *u, const struct race *rc)
|
void u_setrace(struct unit *u, const struct race *rc)
|
||||||
{
|
{
|
||||||
assert(rc);
|
assert(rc);
|
||||||
u->race_ = rc;
|
u->_race = rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
void unit_add_spell(unit * u, sc_mage * m, struct spell * sp, int level)
|
void unit_add_spell(unit * u, sc_mage * m, struct spell * sp, int level)
|
||||||
|
|
|
@ -104,7 +104,7 @@ extern "C" {
|
||||||
struct order *old_orders;
|
struct order *old_orders;
|
||||||
|
|
||||||
/* race and illusionary race */
|
/* race and illusionary race */
|
||||||
const struct race *race_;
|
const struct race *_race;
|
||||||
const struct race *irace;
|
const struct race *irace;
|
||||||
|
|
||||||
int flags;
|
int flags;
|
||||||
|
|
|
@ -444,7 +444,7 @@ static void test_unarmed_races_can_guard(CuTest *tc) {
|
||||||
race * rc;
|
race * rc;
|
||||||
|
|
||||||
setup_guard(&fix, false);
|
setup_guard(&fix, false);
|
||||||
rc = rc_get_or_create(fix.u->race_->_name);
|
rc = rc_get_or_create(fix.u->_race->_name);
|
||||||
rc->flags |= RCF_UNARMEDGUARD;
|
rc->flags |= RCF_UNARMEDGUARD;
|
||||||
update_guards();
|
update_guards();
|
||||||
CuAssertTrue(tc, fval(fix.u, UFL_GUARD));
|
CuAssertTrue(tc, fval(fix.u, UFL_GUARD));
|
||||||
|
|
Loading…
Reference in New Issue