order functions sendmessage and receivemessage... ?? |
Author: |
Message: |
Suxsem
Junior Member
Posts: 66
Joined: Mar 2008
|
O.P. order functions sendmessage and receivemessage... ??
Hi...if I have 2 scrips...:
script 1:
function OnEvent_ChatWndSendMessage(ChatWnd, Message){
return Message + "a"
}
script 2:
function OnEvent_ChatWndSendMessage(ChatWnd, Message){
return Message + "b"
}
if I send message "HI" the message will be HIab or HIba?? Why?
Thank and sorry for bad english!
|
|
07-04-2008 05:32 PM |
|
|
roflmao456
Skinning Contest Winner
Posts: 955 Reputation: 24
30 / /
Joined: Nov 2006
Status: Away
|
RE: order functions sendmessage and receivemessage... ??
you are returning the message plus a letter..
you can also change the message sent by doing "return 'blahblah';"
in that case it will be HIab
.. depends on what the script is called. (alphabetical order)
This post was edited on 07-04-2008 at 07:42 PM by roflmao456.
[quote]
Ultimatess6: What a noob mod
|
|
07-04-2008 06:13 PM |
|
|
Suxsem
Junior Member
Posts: 66
Joined: Mar 2008
|
O.P. RE: order functions sendmessage and receivemessage... ??
you are not understan me
i search the messenger plus order of return...in more script!
|
|
07-04-2008 06:31 PM |
|
|
MeEtc
Patchou's look-alike
In the Shadow Gallery once again
Posts: 2200 Reputation: 60
38 / /
Joined: Nov 2004
Status: Away
|
RE: order functions sendmessage and receivemessage... ??
I think the person is asking what order is a sent message parsed in when you have multiple scripts that modify the text.
one script adds an "a" to the end, and a second script adds a "b".
What order are scripts executed, thus what will the resulting text be when its sent
I cannot hear you. There is a banana in my ear.
|
|
07-04-2008 07:12 PM |
|
|
Suxsem
Junior Member
Posts: 66
Joined: Mar 2008
|
O.P. RE: order functions sendmessage and receivemessage... ??
exact MeEtc!!! Who help me please? Thank!
|
|
07-04-2008 07:59 PM |
|
|
Ezra
Veteran Member
Forgiveness is between them and God
Posts: 1960 Reputation: 31
37 / /
Joined: Mar 2003
|
RE: order functions sendmessage and receivemessage... ??
quote: Originally posted by roflmao456
in that case it will be HIab
.. depends on what the script is called. (alphabetical order)
The answer was already giving.
It's the alphabetical order of the scripts name.
|
|
07-04-2008 09:03 PM |
|
|
Suxsem
Junior Member
Posts: 66
Joined: Mar 2008
|
O.P. RE: order functions sendmessage and receivemessage... ??
sorry...i don't read this message!
thank for all! bye
|
|
07-04-2008 09:29 PM |
|
|
Suxsem
Junior Member
Posts: 66
Joined: Mar 2008
|
O.P. RE: order functions sendmessage and receivemessage... ??
emh...another answer
it's possible to change this order?
|
|
07-05-2008 08:49 AM |
|
|
Matti
Elite Member
Script Developer and Helper
Posts: 1646 Reputation: 39
32 / /
Joined: Apr 2004
|
RE: order functions sendmessage and receivemessage... ??
quote: Originally posted by Suxsem
it's possible to change this order?
No, unfortunately, it's not possible. You could try to detect when the message has already been processed by the other script before, but the best thing (if both scripts were made by you) is to merge the script and provide options for the user to choose what should be added first. Of course, the cheapest way would be to rename one script.
|
|
07-05-2008 08:53 AM |
|
|
CookieRevised
Elite Member
Posts: 15517 Reputation: 173
– / /
Joined: Jul 2003
Status: Away
|
RE: order functions sendmessage and receivemessage... ??
This issue should normally never come up though. Unless you have a bad written script in case of replacements in texts, or two scripts with the same functions (in case of additions in the texts).
It never has been an issue before and there are already hundreds and hundreds of scripts floating around, so...
So, Suxsem, why do you ask this question, what do you have in mind or what are you trying todo? There might be a far better way to do what you want...
.-= A 'frrrrrrrituurrr' for Wacky =-.
|
|
07-05-2008 09:45 AM |
|
|
|