Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   Your opinion (https://forums.graalonline.com/forums/forumdisplay.php?f=195)
-   -   Opinion: echo != sendToNC (https://forums.graalonline.com/forums/showthread.php?t=81782)

TSAdmin 09-12-2008 11:02 AM

Opinion: echo != sendToNC
 
This has been posted many, many, many times in one way or another, I am well aware of that, but at least this isn't a request to just make something like an echo2() or sendToNC2() type thing.

Scripting Opinion:

echo() and sendToNC() should not do the same thing, so to speak. Here's what I think it should do-

Quote:

echo() - Act the same way as sendToRC, but you don't have to worry about it ALWAYS starting with "Your Server Nickname (Server): Message" and can make it act the same as it would for NC so that anything before the ":" is in green, however everyone on RC can see it.

sendToNC() - Remain as it is and used for ONLY messages to be sent to the NC users.

This comes [from me] after seeing Tig trying to make something for detecting a form of hacking via GScript2 and it looks really bad when the only way for it to appear as:
Hacker Detection: Information
and only NC users can see it, and not RC users who may have the ability to do something about it, making it only possible for them to see it for it to appear like such:
Server Name (Server): Hacker Detection: Information

xXziroXx 09-12-2008 01:19 PM

Agreed, echo should be visible for everyone with RC, and sendToNC only for those with NC rights.

Chompy 09-12-2008 03:46 PM

When debugging a script I prefer to use echo() since onyl nc users will see it.. Will be odd to have to switch to sendtonc() just to debug stuff :o

Deas_Voice 09-12-2008 03:58 PM

what about sendToRC()?

Chompy 09-12-2008 04:03 PM

I think it echo should have a choosable second parameter..

echo(test[, nc?]);

so..

PHP Code:

echo("Only people who have NC will see this!");

echo(
"All people who is on rc will see this!"true); 

If second parameter is true, all uses will see it. If false or nil, only nc users will see it

Deas_Voice 09-12-2008 04:09 PM

Quote:

Originally Posted by Chompy (Post 1422642)
I think it echo should have a choosable second parameter..

echo(test[, nc?]);

so..

PHP Code:

echo("Only people who have NC will see this!");

echo(
"All people who is on rc will see this!"true); 

If second parameter is true, all uses will see it. If false or nil, only nc users will see it

and you just forgot the clientside part of echo()?

Chompy 09-12-2008 04:22 PM

Quote:

Originally Posted by Deas_Voice (Post 1422645)
and you just forgot the clientside part of echo()?

I was thinking more of the serverside part.

echo() clientside is like savelog() (Dunno if it is still or if savelog() was changed) and sendrpgmessage()

Loriel 09-12-2008 04:28 PM

Can you just use one of those fancy chat room devices and write your own echo and have everybody who is interested in its output join the room in question :\

Tigairius 09-12-2008 05:31 PM

Quote:

Originally Posted by Chompy (Post 1422635)
When debugging a script I prefer to use echo() since onyl nc users will see it.. Will be odd to have to switch to sendtonc() just to debug stuff :o

I disagree, not going to elaborate.

TSAdmin 09-13-2008 12:33 AM

Let me put this simple:

There is no need to ADD to it, or CHANGE it as such, just remove the restriction from echo().

Let echo do what I said, and let sendToNC do what it even is written as: Sends to NC

Deas_Voice 09-13-2008 12:36 AM

Quote:

Originally Posted by TSAdmin (Post 1422875)
Let me put this simple:

There is no need to ADD to it, or CHANGE it as such, just remove the restriction from echo().

Let echo do what I said, and let sendToNC do what it even is written as: Sends to NC

but everyone can see sendToRc() right?
but it comes with the name(Server) thing..

Frankie 09-13-2008 12:37 AM

I like using echo() when sending system messages to RC because it looks neater, and the stuff I would send is usually something all RCs should see.

TSAdmin 09-13-2008 12:43 AM

Quote:

Originally Posted by Deas_Voice (Post 1422877)
but everyone can see sendToRc() right?
but it comes with the name(Server) thing..

This is pretty much what I mean, yes.

Quote:

*TSAdmin: Yeah, there just has to be an easier way to get simple messages to people without NC rights without having to go through sendToRC() just which is filled to the brim with "YOUR SERVER NICKNAME MIGHT BE SUPER LONG HERE (Server)" preceeding it.

Tigairius 09-27-2008 01:58 AM

http://wiki.graal.net/index.php/Serv..._output_to_RCs

:D

PHP Code:

sendechotorc=true/false 

Stefan added it a few days ago it looks like :cool:

TSAdmin 09-27-2008 02:55 AM

Loving it :] Excellent compromise. Thanks Stefan.

Edit: Though, for this to work locally, does the local NPC Server require any action by Stefan? I set it to true and normal RCs could not see the test.


All times are GMT +2. The time now is 02:18 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.