PtokaX forum

Archive => Archived 5.1 boards => Request for scripts => Topic started by: Syphrone-NL on 27 August, 2007, 07:19:47

Title: Request table chatrooms
Post by: Syphrone-NL on 27 August, 2007, 07:19:47
Hello all.

I downloaded the script chatrooms 4.15 from jitten:


--[[

Chatrooms v 4.15 - LUA 5.0/5.1

By: jiten and Dessamator

Based on: Chatrooms v3 by tezlo

Changelog:

- Changed: Profile permissions; (requested by GeceBekcisi)
- Rewritten: Significant code and loops; code is more presentable;
- Added: Status for each chatroom;
- Changed: MyINFO handling to avoid flooding;
- Changed: Other small mods
- Changed: Updated to LUA 5.1 (3/25/2006)
- Changed: DC away messages aren't sent anymore to rooms - reported by CrazyGuy;
- Changed: Show members when autologin is enabled - requested by CrazyGuy;
- Changed: tAllowed value structure - requested by CrazyGuy;
- Fixed: RightClick commands - reported by osse; (5/23/2006)
- Fixed: ToArrival locked permissions - reported by CrazyGuy; (5/24/2006)
- Changed: MyINFO is sent on Op/UserConnected - reported by CrazyGuy;
- Changed: string.lower comparison between connecting user and existing rooms (5/28/2006)
- Changed: New save function;
- Fixed: !members command when autologin is disabled - reported by CrazyGuy;
- Added: Toggle reset away status on connect - requested by shamu (9/15/2006)
- Fixed: !leave only removes rooms from userlist when hide mode is enabled;
- Changed: Rightclick commands don't need rooms to be typed - just click on them in the userlist;
- Added: !help and custom message on connect - requested by speedX;
- Added: Leaviathan profiles support (9/30/2006)
- Fixed: !mkchat sent as PM when using User Commands - reported by Jorgo (12/2/2006)

]]--


for the exact code search for chatrooms.

But can somebody make it that i can change the permissions in a table

So there will be a table --> permissions.tbl
and there will be in:

Create chatroom -- (1 = allowed - 0 = not allowed)
   
Title: Re: Request table chatrooms
Post by: CrazyGuy on 27 August, 2007, 15:49:06
First request :

The script has a part called tAllowed which is a table where you can set all profiles which are allowed to join a room.
Per command there's also a tLevel table which hold permissions of the profiles being able to use that command. I take it that's the 1 you were after ?

Second request :

Yes, that should be possible. You can name a command for it in Command = { table, and then you add the function to tCmds = { Command.<your command name>

Third request:

This isn't really possible as chatrooms are made visible by sending a MyINFO as a user does. In other words, they're added and removed from the userlist the exact same way as a user. It will be alot of work to have the script decide which users are allowed to see it.
Besides, how can 1 join a chatroom not visible ?

Fourth request:

Setting a max on chatrooms to join is also theoratically possible but not handy to implement in this script. As this script can be configured for users to auto-join, or for whole profiles to be added as members, you may run into the problem that the first created chatroom has alot of users and nobody is allowed to join the chatrooms created after that.

Hope that helps a bit  :)
Title: Re: Request table chatrooms
Post by: Syphrone-NL on 27 August, 2007, 16:59:48
It helps me a lot. I know now its not possible what i want or its to difficult. Thats a shame for me :(
And request 1 was that:
      tLevels = {
Title: Re: Request table chatrooms
Post by: Yahoo on 27 August, 2007, 19:22:47
As a topic of chatroom script has been in discussion i will like to request for sum addition in the script
i had requested this earlier also but i think there was no reply or not a positive reply for the addition
i will like to have this addition commands on the script
Following the the hub commands
-----General-----------------------------------------------------------------------------------
+list            List all room mates.
+exit            Leave the room.
+read            Read the messages.--------
+write            Write a message.              |-> An Individual Message Board per Chatroom
+delete <ID>         Delete a message.-------
+ip <nick>
+history         Lists the last 50 chat messages.
-----Onwer-----------------------------------------------------------------------------------
+set 1            Make the room private.
+set 2            Make the room public.
+close            Close the conference room.
+ban <nick>         Ban a member.
+unban <nick>         Unban a member.
+setowner <nick>      Change the onwer of the room.
+mod <nick>         Add a new moderator.
+demod <nick>         Remove a moderator.
+swapshowjoins         Turn on/off joins messages.
-----Moderator and Owner----------------------------------------------------------------------
+add <nick>         Add user to the conference. eg +add kewl
+remove <nick>         Kick a user from the room.
+delhistory         Delete the messages from the history.
-----------------------------------------------------------------------------------------------
<mandatory> (optional)

Hoping for a positive reply from scripters
Thanks in advance