Mod Tools

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

Post Reply
ImmenseTurmoil
Posts: 20
Joined: 26 Mar 2005, 17:11
Contact:

Mod Tools

Post by ImmenseTurmoil »

Hey. To allow moderators to kick/ban, I decided to make mod tools. The mod tools are a movie clip that is only visible if they are mods. I have a field for username and a field for reason and buttons for kick and ban. But I have one question.

Code: Select all

var dataObj:Object = {}

dataObj.id = userId.toString()
dataObj.msg = msg

smartFox.sendXtMessage("$dmn", "kick", dataObj)
Is that the code that I put on the button for kick?
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Post by Lapo »

That's correct!
The params are:

"$dmn" : this is the name of the admin extension, never change it
"kick": is the command you want to invoke ("ban" is also available)
dataObj: an object with the userId (as a string) and the mod message

:)
Lapo
--
gotoAndPlay()
...addicted to flash games
Post Reply