MCPcopy Index your code
hub / github.com/NetHack/NetHack / docast

Function docast

src/spell.c:819–829  ·  view source on GitHub ↗

the #cast command -- cast a spell */

Source from the content-addressed store, hash-verified

817
818/* the #cast command -- cast a spell */
819int
820docast(void)
821{
822 int spell_no;
823
824 if (getspell(&spell_no)) {
825 cmdq_add_key(CQ_REPEAT, spellet(spell_no));
826 return spelleffects(svs.spl_book[spell_no].sp_id, FALSE, FALSE);
827 }
828 return ECMD_FAIL;
829}
830
831staticfn const char *
832spelltypemnemonic(int skill)

Callers

nothing calls this directly

Calls 3

getspellFunction · 0.85
cmdq_add_keyFunction · 0.85
spelleffectsFunction · 0.85

Tested by

no test coverage detected