Go to the documentation of this file.
80 if (
spell->path_attuned&
op->path_denied) {
81 snprintf(spell_sort[num_found++],
sizeof(spell_sort[0]),
82 "%s:%-30s %3s %3s",
spell->skill ?
spell->skill :
"generic",
83 spell->name,
"den",
"den");
85 snprintf(spell_sort[num_found++],
sizeof(spell_sort[0]),
86 "%s:%-30s %3d %3d",
spell->skill ?
spell->skill :
"generic",
95 "You know no spells like '%s'.",
params);
98 "You know no spells.");
105 "You know the following '%s' spells:",
params);
108 "You know the following spells:");
115 qsort(spell_sort, num_found,
MAX_BUF, (
int (*)(
const void *,
const void *))strcmp);
116 strcpy(
tmp,
"asdfg");
117 for (i = 0; i < num_found; i++) {
119 if (strncmp(
tmp, spell_sort[i], strlen(
tmp))) {
120 strcpy(
tmp, spell_sort[i]);
121 cp = strchr(
tmp,
':');
125 "\n[b][fixed]%s spells %.*s <lvl> <sp>",
126 tmp, (
int)(20-strlen(
tmp)),
" ");
130 strchr(spell_sort[i],
':')+1);
153 tag_t spellnumber = 0;
154 if ((spellnumber = atoi(cpy)) != 0)
165 cp = strchr(cpy,
' ');
168 if (!strncmp(cp,
"of ", 3))
171 }
else if (strlen(cpy) > strlen(spob->
name)) {
172 cp = cpy+strlen(spob->
name);
175 if (!strncmp(cp,
"of ", 3))
182 "You need the skill %s to cast %s!",
195 op->contr->golem_count = 0;
209 strncpy(
op->contr->spellparam, cp,
MAX_BUF);
212 op->contr->spellparam[0] =
'\0';
215 "You ready the spell %s%s%s",
255 if (
op->contr->ranges[
r])
268 if (
op->chosen_skill)
289 op->contr->shoottype =
static_cast<rangetype>((
static_cast<int>(
op->contr->shoottype) + ((k ==
'+') ? 1 : -1)));
300 switch (
op->contr->shoottype) {
303 "No ranged attack chosen.");
308 "You regain control of your golem.");
314 "Switched to %s and %s.",
321 "Switched to spells (%s).",
334 "Switched to skill: %s",
335 op->chosen_skill ?
op->chosen_skill->name :
"none");
void remove_friendly_object(object *op)
#define MSG_TYPE_COMMAND_SUCCESS
int cast_spell(object *op, object *caster, int dir, object *spell_ob, char *stringarg)
void draw_ext_info_format(int flags, int pri, const object *pl, uint8_t type, uint8_t subtype, const char *format,...) PRINTF_ARGS(6
#define MSG_TYPE_COMMAND_ERROR
const char * object_get_value(const object *op, const char *const key)
Plugin animator file specs[Config] name
void object_free_drop_inventory(object *ob)
static void show_matching_spells(object *op, const char *params)
void command_cast_spell(object *op, const char *params, int cast_now)
void query_name(const object *op, char *buf, size_t size)
object * lookup_spell_by_name(object *op, const char *spname)
object * object_find_by_tag(const object *who, tag_t tag)
with a maximum of six This is not so if you are wearing plate you receive no benefit Armour is additive with all the supplementry forms of which means that it lasts until the next semi permanent spell effect is cast upon the character spell
#define MSG_TYPE_SKILL_MISSING
int16_t SP_level_spellpoint_cost(object *caster, object *spell, int flags)
object * find_skill_by_name(object *who, const char *name)
int legal_range(object *op, int r)
void command_invoke(object *op, const char *params)
const typedef char * sstring
void object_remove(object *op)
void command_cast(object *op, const char *params)
void query_base_name(const object *op, int plural, char *buf, size_t size)
void command_rotateshoottype(object *op, const char *params)
static void change_spell(object *op, char k)
#define FOR_INV_PREPARE(op_, it_)