Raised This Month: $12 Target: $400
 3% 

Chat Rooms 1.0


Post New Thread Reply   
 
Thread Tools Display Modes
shine771
Senior Member
Join Date: Jun 2007
Old 12-06-2008 , 06:09   Re: Chat Rooms 0.9
Reply With Quote #11

0.9:
Cleaned code.
shine771 is offline
Killer12201
Senior Member
Join Date: Dec 2007
Old 12-10-2008 , 17:46   Re: Chat Rooms 0.9
Reply With Quote #12

Maybe add in a new version where you can add passwords to the chat room and maybe have a room owner? This would work well for server admins to chat and people guessing the name.
__________________
Killer12201 is offline
shine771
Senior Member
Join Date: Jun 2007
Old 12-25-2008 , 15:29   Re: Chat Rooms 0.9
Reply With Quote #13

I don't think a password is necessary, because you can name your room like -
aassd11374a -, and no one will guess it's name. Owner thing sounds great until, everyone in the room disconnects, then someone who disconnected connects again, and he's the new owner. So..

Someone test it, and tell us if it works or not.
shine771 is offline
Halo Mod 4Ever
Junior Member
Join Date: Jan 2009
Old 01-11-2009 , 19:22   Re: Chat Rooms 0.9
Reply With Quote #14

i like it
Halo Mod 4Ever is offline
shine771
Senior Member
Join Date: Jun 2007
Old 01-12-2009 , 13:56   Re: Chat Rooms 0.9
Reply With Quote #15

You could test it, and confirm that it works..
shine771 is offline
shine771
Senior Member
Join Date: Jun 2007
Old 01-27-2009 , 13:14   Re: Chat Rooms 0.9
Reply With Quote #16

Anyone? Test? Please... :/
shine771 is offline
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 02-05-2009 , 22:27   Re: Chat Rooms 0.9
Reply With Quote #17

There are a few mistakes and optimizations that can be made, however it is acceptable.

If you would like any information regarding possible adjustments you could make or things you could do to make this better, please feel free to post here or PM me.

Approved.
__________________

Last edited by Hawk552; 02-06-2009 at 11:44.
Hawk552 is offline
Send a message via AIM to Hawk552
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 02-06-2009 , 10:52   Re: Chat Rooms 0.9
Reply With Quote #18

Changes have been requested via PM.

Consider tagging your global variables with g_, p_ or some variant of those (depending on whether they're pointers, globals, etc.)

Indent your code some more and add some whitespace. Also, I generally frown upon this style:

Code:
public plugin_init() {     register_plugin("Chat Rooms","0.8","Sh!nE")

As opposed to:

Code:
public plugin_init() {     register_plugin("Chat Rooms","0.8","Sh!nE")

Code:
new info[33],temp[192]

Make this static or global.

Code:
new players[32],num;get_players(players,num)

This is very bad form. Get rid of the semicolon and add a return.

Code:
format(player_chatroom[id],32,"")

Use this instead:

Code:
player_chatroom[id][0] = 0

Code:
stock get_user_chatroom(id) {

Read my article on stocks. Also, this name is not descriptive. You should consider calling it something like get_user_chatroom_index().

Code:
color_print(id,text[]) {     message_begin(MSG_ONE,msg_say,{0,0,0},id)     write_byte(id)     write_string(text)     message_end() }

Use MSG_ONE_UNRELIABLE and consider replacing {0,0,0} with _.

Code:
    onoff = register_cvar("amx_chatrooms","1")     dead_chat = register_cvar("amx_cr_deadchat","1")     min_to_open = register_cvar("amx_cr_min_open","2")     green_text = register_cvar("amx_cr_greentext","1")

Consider unifying your cvar names so they all have a certain prefix.

All in all, this plugin is not bad. It's difficult to read but for the most part it's relatively functional.
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
shine771
Senior Member
Join Date: Jun 2007
Old 02-06-2009 , 11:39   Re: Chat Rooms 1.0
Reply With Quote #19

Thanks.
The only thing that i wont change is:
Quote:
funcion() {
}
with

Quote:
function()
{
}
shine771 is offline
Hawk552
AMX Mod X Moderator
Join Date: Aug 2005
Old 02-06-2009 , 11:44   Re: Chat Rooms 1.0
Reply With Quote #20

Sorry, I just realized I meant to approve this in the first place.

Approved now.
__________________
Hawk552 is offline
Send a message via AIM to Hawk552
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 09:44.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode