예제 #1
0
static void _rune_of_body_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Body");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Body on your body armor or shield. If you wear that armor or shield, you gain +4 Str, Dex, Con, and Resist Nexus.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(_body_test);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_BODY, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #2
0
static void _rune_of_mind_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Mind");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Mind on a body armor or a shield. If you wear that armor, you gain +4 Int, Telepathy, Resist Confusion, Resist Chaos, and Resist Eldritch Horror.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(_mind_test);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_MIND, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #3
0
static void _rune_of_reflection_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Reflection");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Reflection on your shield. Your shield gains the Reflection property.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_shield);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_REFLECTION, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #4
0
static void _rune_of_good_fortune_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Good Fortune");
		break;
	case SPELL_DESC:
		var_set_string(res, "Creates a standalone rune. As long as you have this rune in your inventory, you gain the effects of White Aura mutation.");
		break;
	case SPELL_CAST:
	{
		object_type forge;

		object_prep(&forge, lookup_kind(TV_RUNE, SV_RUNE));
		rune_add(&forge, RUNE_GOOD_FORTUNE, FALSE);
		drop_near(&forge, -1, py, px);

		var_set_bool(res, TRUE);
		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #5
0
static void _rune_of_elemental_protection_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Protection");
		break;
	case SPELL_DESC:
		var_set_string(res, "Creates a standalone rune. As long as you have this rune in your inventory, your inventory items are 50% less likely to be destroyed by elemental attacks.");
		break;
	case SPELL_CAST:
	{
		object_type forge;

		object_prep(&forge, lookup_kind(TV_RUNE, SV_RUNE));
		rune_add(&forge, RUNE_ELEMENTAL_PROTECTION, FALSE);
		drop_near(&forge, -1, py, px);

		var_set_bool(res, TRUE);
		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #6
0
static void _rune_of_sacrifice_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Sacrifice");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Sacrifice on an artifact. You can now destroy (with 'k' command) the artifact, and if you do so, you restore all HP and SP.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_artifact);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_SACRIFICE, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #7
0
static void _rune_of_destruction_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Destruction");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Destruction on a weapon. Your weapon becomes Force-branded.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_melee_weapon);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_DESTRUCTION, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #8
0
static void _rune_of_stasis_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Stasis");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Stasis on a body armor. If you are wearing that armor, you gain Sustain Str at Lvl 15, Sustain Dex at Lvl 20, Sustain Int at Lvl 25, Sustain Con at Lvl 30, Sustain Wis and Chr at Lvl 35, Hold Life at Lvl 40, Resist Disenchantment at Lvl 45, and Resist Time at Lvl 50.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_body_armour);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_STASIS, TRUE));
		
		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #9
0
static void _rune_of_deflection_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Deflection");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Deflection on a shield. If you are wearing that shield, your AC is improved.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_shield);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_DEFLECTION, TRUE));

		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #10
0
static void _rune_of_regeneration_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Regeneration");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Regeneration on a body armor. If you are wearing that armor then you regain hitpoints more quickly.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_body_armour);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_REGENERATION, TRUE));
		
		break;
	}
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
예제 #11
0
static void _rune_of_absorption_spell(int cmd, variant *res)
{
	switch (cmd)
	{
	case SPELL_NAME:
		var_set_string(res, "Rune of Absorption");
		break;
	case SPELL_DESC:
		var_set_string(res, "Places a Rune of Absorption on a weapon.  If you are hit with a magical spell while wielding that weapon, you take less damage and you recover some spell points.");
		break;
	case SPELL_CAST:
	{
		object_type *o_ptr = _rune_object_prompt(object_is_melee_weapon);
		var_set_bool(res, FALSE);

		if (o_ptr)
			var_set_bool(res, rune_add(o_ptr, RUNE_ABSORPTION, TRUE));

		break;
	}
	case SPELL_COST_EXTRA:
		var_set_int(res, p_ptr->msp/3);
		break;
	default:
		_rune_default_spell(cmd, res);
		break;
	}
}
/****************************************************************
 * Sexy
 ****************************************************************/
static void _sexy_birth(void)
{
    if ( p_ptr->prace != RACE_MON_SWORD
      && !demon_is_(DEMON_BALROG) )
    {
        object_type forge = {0};
        object_prep(&forge, lookup_kind(TV_HAFTED, SV_WHIP));
        if (p_ptr->pclass == CLASS_RUNE_KNIGHT)
            rune_add(&forge, RUNE_ABSORPTION, FALSE);
        py_birth_obj(&forge);
    }
}