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
➜ Adding ifchecks to act_wiz
Adding ifchecks to act_wiz
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Saryn
USA (28 posts) Bio
|
Date
| Wed 27 Aug 2003 01:20 AM (UTC) Amended on Wed 27 Aug 2003 02:23 AM (UTC) by Saryn
|
Message
| Ok i want to add 2 ifchecks to the following code for duedates...
if ( ( !str_cmp( arg2, "days" ) || !str_cmp( arg2, "months" ) ) && ch->owner == FALSE )
{
send_to_char( "Only Josh may set custom duedate durations.\n\r", ch );
return;
}
I want to add an ifcheck for director_newbie and director_asst_newbie (these are put in pfiles along with owner. I tried:
if ( ( !str_cmp( arg2, "days" ) || !str_cmp( arg2, "months" ) ) ch->owner == FALSE && ( ch->director_newbie == FALSE && ch->director_asst_newbie == FALSE ) )
{
send_to_char( "Only Josh may set custom duedate durations.\n\r", ch );
return;
}
And it didn't like that. Any suggestions? | Top |
|
Posted by
| Boborak
USA (228 posts) Bio
|
Date
| Reply #1 on Wed 27 Aug 2003 06:43 AM (UTC) |
Message
| What errors did it give you? Have you added director_newbie and director_asst_newbie to the CHAR_DATA struct in mud.h? | Top |
|
Posted by
| Saryn
USA (28 posts) Bio
|
Date
| Reply #2 on Thu 28 Aug 2003 12:06 AM (UTC) Amended on Thu 28 Aug 2003 12:21 AM (UTC) by Saryn
|
Message
| It basically says there is a parse error before the next if after the code I posted | Top |
|
Posted by
| Nick Cash
USA (626 posts) Bio
|
Date
| Reply #3 on Thu 28 Aug 2003 12:32 AM (UTC) Amended on Thu 28 Aug 2003 12:33 AM (UTC) by Nick Cash
|
Message
| Looks like your missing an and. Perhaps this will work:
if ( ( !str_cmp( arg2, "days" ) || !str_cmp( arg2, "months" ) ) && ch->owner == FALSE && ( ch->director_newbie == FALSE && ch->director_asst_newbie == FALSE ) )
|
~Nick Cash
http://www.nick-cash.com | Top |
|
Posted by
| Saryn
USA (28 posts) Bio
|
Date
| Reply #4 on Thu 28 Aug 2003 12:57 AM (UTC) |
Message
| Haha...can't believe I didnt see that.. Thanks alot..it works. | Top |
|
Posted by
| Nick Cash
USA (626 posts) Bio
|
Date
| Reply #5 on Sat 30 Aug 2003 03:27 AM (UTC) |
Message
| Heh, no problem, I do that all the time. :) |
~Nick Cash
http://www.nick-cash.com | 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.
17,798 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top