EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   XML Modification Help & Info (https://www.eq2interface.com/forums/forumdisplay.php?f=22)
-   -   Group window send tell (https://www.eq2interface.com/forums/showthread.php?t=11219)

RickF7666 06-27-2008 12:43 PM

Group window send tell
 
I've come up with a way to send a tell to a group member. This is suppose to be an easy way for group members to have a private chat with out involving the entire group. Basically, push a button and send a tell to that group member. The problem I'm having is that it sends the group member's name twice to the chat window. So what I have is:

OnPress="beginchatinput "/t " ## parent.Name.text"

Is there any way to do this with out the group member's name coming up twice?

Drumstix42 06-27-2008 05:18 PM

So your code ends up putting text in the chat like:

/t Drumstix Drumstix

?

*edit* nevermind. you mean it executes /beginchatinput twice

lordebon 06-27-2008 05:36 PM

Quote:

Originally Posted by RickF7666 (Post 73784)
I've come up with a way to send a tell to a group member. This is suppose to be an easy way for group members to have a private chat with out involving the entire group. Basically, push a button and send a tell to that group member. The problem I'm having is that it sends the group member's name twice to the chat window. So what I have is:

OnPress="beginchatinput "/t " ## parent.Name.text"

Is there any way to do this with out the group member's name coming up twice?

I've had this issue before. Here's what to do...

OnHover="A = "/t " ## parent.Name.text"
OnPress="beginchatinput A"

Note that code may not be 100% correct, I'll check it against the file I use later.

Drumstix42 06-27-2008 05:58 PM

Oh I think I see the problem. It seems whenever you execute an in-game command on only one line of code, it executes it twice...

This should work:

Code:

OnPress="sTempName=("/t ")##(Parent.Name.Text)
beginchatinput sTempName"


gm9 06-28-2008 07:46 AM

It's simpler to just remove the ## operator, i.e. it needs to look like this:
OnPress="beginchatinput "/t " parent.Name.Text"
PS: Apart from that - as a general rule - I recommend to not use command abbreviations in code, i.e. write /tell instead of /t. Abbreviations may change over time, better be on the safe side.

Drumstix42 06-28-2008 12:53 PM

May still need to make it two lines of code as I did above, to avoid your double executed command.

lordebon 06-28-2008 02:08 PM

Quote:

Originally Posted by Drumstix42 (Post 73811)
May still need to make it two lines of code as I did above, to avoid your double executed command.

Double executed has to do with the concat ( ## ) operator I believe. It's the only time I've seen it, and it seems that if you put command A ## B you end up with command A B B (ie it concats twice). If you use more than one concat it gets even worse.

gm9 06-28-2008 02:23 PM

Exactly, that's what I was trying to say above.

Drumstix42 06-28-2008 04:23 PM

Oh ok. That's strange...

lordebon 06-28-2008 04:58 PM

Quote:

Originally Posted by Drumstix42 (Post 73820)
Oh ok. That's strange...

That's exactly what I said the first time I saw it happen. But after I figured out how to stop it (using variables and the onHover of the button) it's worked fine. My only guess is that the command parser for whatever reason is parsing the concat twice if you try and put it in a command.

Drumstix42 06-28-2008 05:05 PM

Trying not to derail here... but is it only for executed commands? Cause I haven't run into the problem before (that I know of)

Aseekia 06-29-2008 04:13 AM

another simple code - works fine ;)
 
<Page Name="Tellmacro">
<Data Name="Tell1" text="Write your Tell here."/>
</Page>

OnPress="tell Parent.Name.LocalText Parent.Parent.Parent.Tellmacro.Tell1.Text

test it on my new grp window and it works fine





mfg

gm9 06-29-2008 05:02 AM

Quote:

Originally Posted by Drumstix42 (Post 73822)
Trying not to derail here... but is it only for executed commands? Cause I haven't run into the problem before (that I know of)

Yes, apparently the scripting engine doesn't like combining different types of operations, combining a command with an operator always trips it up (whether you pass it to the command line or just run the command internally).

RickF7666 06-29-2008 10:55 AM

Thanks for the help
 
Thanks everyone for all the help. I've have just uploaded my first group window. As far as I can tell everything works. :confused:


All times are GMT -5. The time now is 11:41 AM.

vBulletin® - Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
© MMOUI