authorization

Posted by Ithildin on Thu 23 Jan 2003 06:00 AM — 18 posts, 67,381 views.

USA #0
I'm wanting to take out the whole auth thing. is there a simple way to do that or do i have to go through all the code and take the auth stuff out? i was wanting for the players to just log in and when they made a new character they would automatically be in their hometown, without going through the newbie area.

any thoughts or suggestions?
Ithildin
Australia Forum Administrator #1
Do you have a problem with just turning WaitForAuth off? See this FAQ:

http://www.gammon.com.au/scripts/showfaq.php?faqid=32&productid=6
USA #2
the waitforauth only sends the players to the mob that advances them to two, i was wanting for like when they log into a new character they will automatically start in there hometown. and also i've been seeing that when i authorize people. they pull the rope but they stay unauthed and go to the executioner. i have to actually mset them to get the flag off of them.
USA #3
what i meant for that last one was, when i turn the waitforauth to 0 it sends them straight into the area with the mob that advances them to two.
USA #4
Im afraid youll need to do some coding to make that happen the way youve described it. Or possibly some building instead if youre not particularly ambitious with your code.
USA #5
yea, i was afraid of that. would i have to go in and delete all the authorization functions and stuff to get rid of that command? eventhough i don't know alot about code, i'm a very quick learner and i know enough to get by. plus i'm ambitious...heh.

Thanks,
Ithildin
USA #6
hrm, i've been thinking about this. if i could just use the room, where the mob advances the player, to just have an mprog or rprog in it to get the race of the player and send them to there respectful homes. would that work?
Australia Forum Administrator #7
Yes, why not just change the way the mob advances you to level 2?
USA #8
yea, thats what i'm tryin to do now. i'm tryin to figure all these mop triggers out. what i do is:

mpedit mistress add rand 100


Build: Ithildin: (mset) mpedit mistress add rand 100
Build: Ithildin: mpedit mistress add rand 100
Begin entering your text now (/? = help /s = save /c = clear /l = list)
-----------------------------------------------------------------------
> Done.
if race($r) == dwarf
> mptransfer $r 6500
> endif
> /s
No victim selected. Type '?' for help.


this is what it gives me when i try to do anything in the buffer. the mob is flagged prototype and all.

i look at the /? file and it didn't really show me anything:


-----------------------------------------------------------------------
> Done.
/?
Editing commands
---------------------------------
/l list buffer
/c clear buffer
/d [line] delete line
/g <line> goto line
/i <line> insert line
/r <old> <new> global replace
/a abort editing
/! <command> execute command (do not use another editing command)
/s save buffer

i cleared the buffer with the done at the beginning trying this also, still can't save it.

any thoughts?


USA #9
For starters, a random prog probly isn't going to give you the results you want here. Best way to handle this is use either a grall or speech triggered prog.

The prog code itself is also slightly off as well since everything is targeting a random character.

Try this instead on a grall trigger:

if race $n = dwarf
mptransfer $n 6500
endif

Add a similar check for each pc race with the proper transfer destination and you should be ready to rock.

Using a random check is going to give very unusual results if you have more than one person in the room at a time and it doesnt grab the same target with both the race check and the transfer part of the prog.
Amended on Thu 23 Jan 2003 09:56 PM by Meerclar
USA #10
Build: Ithildin: (mset) mpedit mistress add allgreet
Build: Ithildin: mpedit mistress add allgreet
Begin entering your text now (/? = help /s = save /c = clear /l = list)
-----------------------------------------------------------------------
> Done.
/c
Buffer cleared.
> if race $n == dwarf
> mptransfer $n 6500
> endif
> /s
No victim selected. Type '?' for help.

i'm still getting the no victem message. i'm not sure what i need to put on the end.

thanks for all the help guys
Ithildin

Australia Forum Administrator #11
Load up the file into Notepad and find the appropriate program, and just type it in. Or, use the Area Editor from this site that lets you edit mob programs.
USA #12
alright, thanks nick, i feel kind of dumb for not thinkin about that. ok, so now i've put in a speech prog:

> act_prog $n has entered the game~
say Tell me your race and I will take you to your homeland young one!
~
> speech_prog dwarf~
if race($n) == dwarf
mptransfer $n 6500
t $n Good luck young one!
Endif
If race($n) != dwarf
say &rYou are not a dwarf! How dare you insult me!
Slap $n
Glare $n
Endif

now when the player enters the game, he gets three messages. how is it doing this?

Galindin has entered the game.
Mistress Tsythia says 'Tell me your race and I will take you to your homeland young one!'
Mistress Tsythia says 'Tell me your race and I will take you to your homeland young one!'
Mistress Tsythia says 'Tell me your race and I will take you to your homeland young one!'

any suggestions?

Ithildin
USA #13
Paste us the exact text the mob sees and we might can figure something out.
USA #14
Galindin has entered the game.
You say 'Tell me your race and I will take you to your homeland young one!'
You say 'Tell me your race and I will take you to your homeland young one!'
You say 'Tell me your race and I will take you to your homeland young one!'


i switched to be the mob and it just said that.

and also when the player exits the room and comes back the mob says it again:

Galindin arrives from the north.
You say 'Tell me your race and I will take you to your homeland young one!'

but only once.

i also tried
< act_prog p has entered the game.~
say Tell me your race and I will take you to your homeland young one!
~

but it didn't even show up when i tried it.

i have all the mprogs that i put in, in the last message i sent.
Amended on Fri 24 Jan 2003 12:23 AM by Ithildin
USA #15
The problem is that the act progs look for ALL of the words in that particular string. So try adding a mud_prog based off of my example command here:

mpedit school add act "has entered the game."

note the lack of $n and the period at the end

Try that and see how it flies ;-)
USA #16
It should be possible to set the trigger to react to the entire phrase instead of each word in the list. However, this may require actually editing the prog in the area file and adding a P before the keywords for it to react to. Im not terribly familiar with the SMAUG mprog structure so I'm uncertain of the usefulness of putting the phrase in quotes.
Amended on Fri 24 Jan 2003 05:13 AM by Meerclar
USA #17
cocked locked and ready to rock..

thanks guys. i'll probably have more questions soon..heh
you guys rock

Ithildin