MCPcopy Create free account
hub / github.com/DFHack/dfhack / set_nickname

Function set_nickname

plugins/manipulator.cpp:639–644  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

637 string get_age(UnitInfo *u)
638 { return itos((int)Units::getAge(u->unit)); }
639 void set_nickname(UnitInfo *u, std::string nick)
640 {
641 Units::setNickname(u->unit, nick);
642 u->name = get_nickname(u);
643 u->transname = get_nickname_eng(u);
644 }
645 void set_profname(UnitInfo *u, std::string prof)
646 {
647 u->unit->custom_profession = prof;

Callers

nothing calls this directly

Calls 2

get_nicknameFunction · 0.85
get_nickname_engFunction · 0.85

Tested by

no test coverage detected