ID:266367
 
How do you get a Code to MUTE a plyer(Stop the Player from Chatting)If you need to know my Say Verbs these are it://OCC
I need it in a GM VERB!

mob
verb/OOC(T as text)
set desc = "Do a OCC!"
set category = "Communication"
world << "\icon[usr]\red \<[src.name]> [T]"

//World Talk
mob
verb/WorldTalk(T as text)
set desc = "Do a World Talk!"
set category = "Communication"
world << "\icon
[usr]**\white \<[src.name]> ** [T]*"

If you know how to Mute please tell me.Thanks!
You need to make a var.
mob
var
muted = 0

Then in the say verb, make it check it.
mob
verb
Say(m as text)
if(usr.muted == 1)
usr << "You cant talk! You are muted!"
else
world << "[usr]: [m]"


-Rcet
In response to Rcet
Rcet wrote:
You need to make a var.
> mob
> var
> muted = 0
>

Then in the say verb, make it check it.
> mob
> verb
> Say(m as text)
> if(usr.muted == 1)
> usr << "You cant talk! You are muted!"
> else
> world << "[usr]: [m]"
>

-Rcet

Can you make that into a GM Verb plz?
In response to SSJ4_Gohan_Majin
SSJ4_Gohan_Majin wrote:
Can you make that into a GM Verb plz?

that is a pointless Question to ask, but since you said plz

mob\GM
verb
Say(m as text)
if(usr.muted == 1)
usr << "You cant talk! You are muted!"
else
world << "[usr]: [m]"


Now if you want it so that a GM can "Mute" people, then you would need this LITTLE code:

mob
GM
verb
GM_Mute(mob/m in world)
M.muted = 1


You'll have to figure out on your own how to un-mute them (it shouldnt be that hard)
In response to Pillsverry
I'm in a kinda giving mood, so here:


mob
var
muted = 0
mob/verb/Say(T as text)
if(!usr.muted)
//normal say actions
else
usr<<"You're silenced!"

mob/GM/verb/mute(mob/M in world)
if(M.muted)
M<<"You can now speak!"
usr<<"You unmute [M]."
M.muted = 0
else
M<<"You have been silenced"
usr<<"You mute [M]!"
M.muted = 1
In response to Pillsverry
Read your code over, I found a few errors.
In response to Pillsverry
Errors on this Code:

GM_Mute(mob/m in world)
set category = "GM"
set desc = "() Stop a Mob from Talking in the World"
World_Talk(m as text)
if(usr.muted == 1)
M.muted = 1
usr << "You cant talk! You are muted!"
else world << "[usr]: [m]"

Whats the problem?
In response to SSJ4_Gohan_Majin
SSJ4_Gohan_Majin wrote:
Errors on this Code:

GM_Mute(mob/m in world)
set category = "GM"
set desc = "() Stop a Mob from Talking in the World"
World_Talk(m as text)
if(usr.muted == 1)
M.muted = 1
usr << "You cant talk! You are muted!"
else world << "[usr]: [m]"

Whats the problem?


You have to tell us the errors you get, and that code will cause errors because it's indented really badly.
In response to Nadrew
Nadrew wrote:
SSJ4_Gohan_Majin wrote:
Errors on this Code:

GM_Mute(mob/m in world)
set category = "GM"
set desc = "() Stop a Mob from Talking in the World"
World_Talk(m as text)
if(usr.muted == 1)
M.muted = 1
usr << "You cant talk! You are muted!"
else world << "[usr]: [m]"

Whats the problem?


You have to tell us the errors you get, and that code will cause errors because it's indented really badly.

Error:if:Invailed proc defenition
Error:M.Mute Invailed proc defenition
Error:= Invailed proc defenition
Error:<< Invailed proc defenition
Error:else Invailed proc defenition

Were Wolf Human Quest 5 errors,0 warnings(Dubble click on an error to jump it)
In response to SSJ4_Gohan_Majin
BIG PROBLEMS when i fixed the code cause ur code was indented badly it made 72 errors:
        
GM_Mute(mob/M in world)
set category = "GM"
mob
var
muted = 0
mob/verb/WorldTalk(T as text)
mob/verb/OCC(T as text)
if(!usr.muted)//normal say actions
else
usr<<"You're silenced!"
In response to SSJ4_Gohan_Majin
SSJ4_Gohan_Majin wrote:
BIG PROBLEMS when i fixed the code cause ur code was indented badly it made 72 errors:
        
> GM_Mute(mob/M in world)
> set category = "GM"
> mob
> var
> muted = 0
> mob/verb/WorldTalk(T as text)
> mob/verb/OCC(T as text)
> if(!usr.muted)//normal say actions
> else
> usr<<"You're silenced!"
>

mob
var
mute = 0
verb
say(T as text)
if(usr.mute == 1)
usr << "You are muted!!"
else
world << "[usr]: [T]"
mob/GM
verb
Mute(mob/M in world)
if(M.mute == 0)
M.mute = 1
usr << "[M] is muted!!"
else
M.mute = 0
usr << "[M] is unmuted!!"

Is this what you are looking for?
In response to SSJ4_Gohan_Majin
SSJ4_Gohan_Majin wrote:
BIG PROBLEMS when i fixed the code cause ur code was indented badly it made 72 errors:
        
> GM_Mute(mob/M in world)
> set category = "GM"
> mob
> var
> muted = 0
> mob/verb/WorldTalk(T as text)
> mob/verb/OCC(T as text)
> if(!usr.muted)//normal say actions
> else
> usr<<"You're silenced!"
>

Whos Code?
In response to Pillsverry
Try this:
mob
var
muted=0

mob/GM
verb
GM_Mute(mob/M in world)
set category = "GM"
if(M.muted == 1)
usr <<"[M] is already muted!"
else
usr <<"You have been muted by [M]!"
M.muted=1


GM_Un_Mute(mob/M in world)
set category = "GM"
if(M.muted == 0)
usr <<"[M] is not muted!"
else
usr <<"You have un-muted [M]!"
M.muted=0


mob/verb/Say(T as text)
if(usr.muted == 1)
usr <<"You are muted!"
else
world <<"[usr]: [T]"

That should work.

-Kappa the Imp