From 008d652ee8a55b92c105cb35fce5dfb88e9cf375 Mon Sep 17 00:00:00 2001 From: Rick L Bird Date: Fri, 6 May 2011 15:38:45 -0400 Subject: [PATCH] Made Chat into a levchk power as it was referenced that way several places in the code. Also Made it so you have to be Prived + Site power in order to delete a power, as well as if you add a power you automatically get the power. --- src/division.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/division.c b/src/division.c index 297f438..0bfbb70 100644 --- a/src/division.c +++ b/src/division.c @@ -187,7 +187,7 @@ static struct new_division_power_entry_t new_power_list[] = { {"Builder", "self"}, {"Can_NsPemit", "levchk"}, {"Cemit", "self"}, - {"Chat", "self"}, + {"Chat", "levchk"}, {"Chown", "levchk"}, {"Combat", "levchk"}, {"Cron", "self"}, @@ -1203,11 +1203,17 @@ COMMAND(cmd_power) power = add_power_type(arg_left, powc_list[i].name); notify_format(player, "Added power '%s' as a '%s' type power.", power->name, powc_list[i].name); + /* Ok.. they added the power, they should get it themself.. At its max level */ + RESET_POWER(player, power); + GIVE_DPBIT(player, power->flag_yes); + GIVE_DPBIT(player, power->flag_lte); + GIVE_DPBIT(player, power->flag_lt); + } else notify(player, "Invalid Type."); } else notify(player, "No point adding a power that already exists."); - } else if (SW_ISSET(sw, SWITCH_DELETE) && Site(player)) { + } else if (SW_ISSET(sw, SWITCH_DELETE) && Site(player) && Prived(player)) { /* This should handle deleting both aliases & powers */ if (arg_left && *arg_left) { power = (POWER *) ptab_find_exact(ps_tab.powers, arg_left); -- 2.30.2