Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ SMAUG
➜ SMAUG coding
➜ SWR1.0 (maybe stock SMAUG) bug
SWR1.0 (maybe stock SMAUG) bug
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Boborak
USA (228 posts) Bio
|
Date
| Sun 20 Apr 2003 08:07 AM (UTC) |
Message
| An admin of mine pointed out that there's a potentially BAD flaw in the mudprogs for SWR1.0
It appears that some of the mudprogs in mud_comm.c don't take CHARM into account. This allows a charmed mob to execute a mudprog command for a player. The most dangerous of these is 'mp_withdraw' which allows a mob to withdraw money from the local economy, then give it to the player.
Easy fix:
in act_comm.c find the do_order() function
Find this chunk of code about mid-function:
if ( !IS_AFFECTED(victim, AFF_CHARM) || victim->master != ch )
{
send_to_char( "Do it yourself!\n\r", ch );
return;
}
}
Add this directly after that: (note: this is AFTER the closing bracket of the else condition)
if(strstr(argument,"mp"))
{
send_to_char("Huh?\n\r",ch);
return;
}
Recompile. You're good to go.
If you're REALLY want to play it safe or you have added functions that are similar to 'order' add this to the begining of every mpcommand in mud_comm.c that's missing it:
if ( IS_AFFECTED( ch, AFF_CHARM ) )
return;
add it AFTER the IS_NPC check | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
8,173 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top