Login
User Name:

Password:



Register
Forgot your password?
Vote for Us!
auth_update crash
Dec 23, 2017, 10:15 pm
By Remcon
check_tumble
Dec 18, 2017, 7:21 pm
By Remcon
parse description bug
Dec 15, 2017, 10:08 pm
By Remcon
Couple bugs
Dec 12, 2017, 5:42 pm
By Remcon
Bug in disarm( )
Nov 12, 2017, 6:54 pm
By GatewaySysop
LoP 1.46
Author: Remcon
Submitted by: Remcon
LOP 1.45
Author: Remcon
Submitted by: Remcon
LOP Heroes Edition
Author: Vladaar
Submitted by: Vladaar
Heroes sound extras
Author: Vladaar
Submitted by: Vladaar
6Dragons 4.3
Author: Vladaar
Submitted by: Vladaar
Users Online
CommonCrawl, Yandex, Raine

Members: 1
Guests: 7
Stats
Files
Topics
Posts
Members
Newest Member
478
3,708
19,242
612
Jacki72H
Today's Birthdays
There are no member birthdays today.
Related Links
» SmaugMuds.org » General » Coding » authorizing question :)
Forum Rules | Mark all | Recent Posts

authorizing question :)
< Newer Topic :: Older Topic >

Pages:<< prev 1 next >>
Post is unread #1 Aug 15, 2006, 4:05 am
Go to the top of the page
Go to the bottom of the page

jparkin

GroupMembers
Posts33
JoinedAug 11, 2006

hey again. sorry for all the questions. lol. hope i'm not bugging anyone!

anyways, here's my problem. i have 2 seperate academy's. one for deadlies and one for peacefuls. the peacefuls one will remain stock (with Tsythia).

now, upon getting authorized, is there a way that if the player chose the "deadly path" to send them to vnum 20504 and if they chose the peaceful path to send them to vnum 10300?

i saw in the mud.h file that you need to define a ROOM_VNUM_SCHOOL and i have that set to vnum 20504. i see no where else within the mud.h file to define another school for peacefuls.

i also tried going about this problem by using the mob and mprogs. unfortionately, there are no ifcheck statements for IFAUTHED or something along those lines so that plan back fired :(

i hope this makes sense! if anyone has any ideas on how to solve this problem please let me know!

thanks in advance!
-Josh
       
Post is unread #2 Aug 15, 2006, 9:27 am
Go to the top of the page
Go to the bottom of the page

Zeno
Sorcerer
GroupMembers
Posts723
JoinedMar 5, 2005

How about making an ifcheck, ifauthed or something?
       
Post is unread #3 Aug 15, 2006, 9:43 am
Go to the top of the page
Go to the bottom of the page

jparkin

GroupMembers
Posts33
JoinedAug 11, 2006

that's what i was thinking of doing but there is no ifcheck for ifauthed or anything even close to that. i checked all 3 ifcheck help files (ifchecks, ifchecks2, ifchecks3)

am i able to make my own ifcheck by chance? and if so, how hard is it?
       
Post is unread #4 Aug 15, 2006, 10:12 am
Go to the top of the page
Go to the bottom of the page

Zeno
Sorcerer
GroupMembers
Posts723
JoinedMar 5, 2005

You can make your own ifcheck by coding it in. It's not hard if you know what you're doing.
       
Post is unread #5 Aug 15, 2006, 10:23 am
Go to the top of the page
Go to the bottom of the page

jparkin

GroupMembers
Posts33
JoinedAug 11, 2006

which i don't. lol. if anyone has any extra spare time that would wanna help me out with this, it would be greatly appreciated! ;)

thanks!
-j
       
Post is unread #6 Aug 15, 2006, 10:41 am
Go to the top of the page
Go to the bottom of the page

Remcon
Geomancer
GroupAdministrators
Posts1,868
JoinedJul 26, 2005

*Don't have spare time, but I can point you in the right direction.* Take a look in mud_prog.c find like
      if( !str_cmp( chck, "level" ) )
         return mprog_veval( get_trust( chkchar ), opr, atoi( rval ), mob );

The part around that is where your ifchecks are at.
All you have to do is fiqure out what kind of ifcheck you are wanting the check to actually check and handle it there.
It should be fairly simple considering I think there is already a define that checks if someone is authroized or not.
       
Post is unread #7 Aug 16, 2006, 6:40 pm
Go to the top of the page
Go to the bottom of the page

Conner
Sorcerer
GroupMembers
Posts870
JoinedMay 8, 2005

If you take a look at the stock newgate.are file, you'll notice that it's only using a room prog with mptrans to send the player on to the academy, it already fails if they're not auth'd, so all you have to do is modify that room prog to something like:
Name: A View of the World.  Vnum: 122.
>act_prog p pulls a rope.
mpechoat $n High overhead you hear a large bell thunder in response.
mpechoaround $n High overhead, a large bell thunders in response.
mpechoat $n If nothing happens, type LOOK ROPE, and pull again in 30 seconds.
if ispkill($n)
mptrans $n 20504
at 20504 mpforce $n look
else
mptrans $n 10300
at 10300 mpforce $n look
endif
push rope

The exception to this is that if you've modified the auth system you might need another approach, but it doesn't sound like you have.
       
Post is unread #8 Aug 16, 2006, 9:58 pm
Go to the top of the page
Go to the bottom of the page

kiasyn
Magician
GroupMembers
Posts121
JoinedJun 30, 2006

shouldn't that be using mpat. :P
       
Post is unread #9 Aug 17, 2006, 5:36 pm
Go to the top of the page
Go to the bottom of the page

Conner
Sorcerer
GroupMembers
Posts870
JoinedMay 8, 2005

Hmm, good point, it should.. guess I'll have to double check our prog for that room to make sure that it was my own typo here rather than in our area file. :redface:
In any event, that's why I said
modify that room prog to something like:
rather than
modify that room prog to read:
:wink:
       
Pages:<< prev 1 next >>