EQ2Interface.com
Search Downloads


Go Back   EQ2Interface > Developer Discussion > XML Modification Help & Info

Reply
Thread Tools Search this Thread Display Modes
  #26  
Unread 01-23-2005, 01:46 PM
Quib Quib is offline
A Griffon
This person is a EQ2Map developer.
Interface Author - Click to view interfaces
 
Join Date: Jan 2005
Posts: 720
Default

Semi important discovery relating to OnEvents:
When you have an OnEvent property, all actions on the same line within the OnEvent execute in order from right to left. If you add line returns within the OnEvent, they go from top to bottom, with commands on individual lines (if you have more than 1 on some lines) still execute from right to left. Examples follow:

OnPress="x=3 x=2 x=1"
In this event, x would equal 3.

OnPress="x=3
x=2
x=1"
In this event, x would equal 1.

OnPress="x=3
x=2 x=1"
In this event, x would equal 2.

I think that's simple enough. Just adding to our knowledge base.

Quib
Reply With Quote
  #27  
Unread 03-02-2005, 05:35 AM
Deathbane27's Avatar
Deathbane27 Deathbane27 is offline
aka Mook
This person is a EQ2Map developer.
Interface Author - Click to view interfaces
 
Join Date: Jul 2004
Server: Nektulos
Posts: 1,451
Default

UPDATE!

Getting commands like /say and /gsay to work:

OnPress="say='This is a test.' say='This is a test.'"

The two executes much match exactly, and you must do each execute twice.
So, for example, if you wanted to make a button on the player window that casted a ward and announced it (out of macro slots? ), you would do something like this:

OnPress="gsay='Warding %t!' gsay='Warding %t!'
useability='Demonstration of Faith' useability='Demonstration of Faith'"



Bug to be aware of.

If you do a script with Anything=Somethingelse, and "Somethingelse" is a command, then you may have problems. Examples:

OnPress="mood='happy' mood='happy'"

OnPress="somevalue=(Some math thing that results in the number 2)"

The first will execute /happy instead of /mood happy because /happy is a command. No known way to work around this.

If you are in two or more chat channels, then the second script may give the message Usage: /tellchannel <channelname> <message> because it thinks you're trying to talk in the second chat channel (/2 Hello!). I'm not certain how to work around it or why it started showing up with math calculations a patch or two ago.
__________________
If it ain't broke, it needs more features!
Reply With Quote
  #28  
Unread 03-02-2005, 02:04 PM
Drumstix42's Avatar
Drumstix42 Drumstix42 is offline
A Griffon
Featured
 
Join Date: Oct 2004
Server: Antonia Bayle
Posts: 3,287
Send a message via AIM to Drumstix42 Send a message via MSN to Drumstix42 Send a message via Yahoo to Drumstix42
Default

Interesting...
__________________
"I'm afraid you're guilty of thought-crime. Don't bother getting the door, we'll let ourselves in..."
<Donate to DrumsUI> < [DrumsUI] Updater > < [DrumsUI] Full Interface> < Drumstix42 on Twitch.tv
>
Reply With Quote
  #29  
Unread 03-02-2005, 02:39 PM
Kosmos's Avatar
Kosmos Kosmos is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Dec 2004
Server: Lucan DLere
Posts: 581
Default

Quote:
Originally Posted by Deathbane27
UPDATE!

Getting commands like /say and /gsay to work:

OnPress="say='This is a test.' say='This is a test.'"

The two executes much match exactly, and you must do each execute twice.
So, for example, if you wanted to make a button on the player window that casted a ward and announced it (out of macro slots? ), you would do something like this:

OnPress="gsay='Warding %t!' gsay='Warding %t!'
useability='Demonstration of Faith' useability='Demonstration of Faith'"



Bug to be aware of.

If you do a script with Anything=Somethingelse, and "Somethingelse" is a command, then you may have problems. Examples:

OnPress="mood='happy' mood='happy'"

OnPress="somevalue=(Some math thing that results in the number 2)"

The first will execute /happy instead of /mood happy because /happy is a command. No known way to work around this.

If you are in two or more chat channels, then the second script may give the message Usage: /tellchannel <channelname> <message> because it thinks you're trying to talk in the second chat channel (/2 Hello!). I'm not certain how to work around it or why it started showing up with math calculations a patch or two ago.

The message that pops up in the other chat window.
I was also getting that message with my Performance Panel mod for a while.
I 'think' it was when I gave it a whole number value instead of a decimal value. But I'm not where I can test it. Once I had all the commands in the correct order and formated it seemed dissapeared. So you might try throwing in 2.0 instead of 2.


On Setting the mood.
For commands that set states. Like Mood, you might try a number instead of the text. mood="2.0" maybe it's some sort of indexed list that the command is interpreted by the chat windows, but not when you use the command through a script.


EDIT: Also... Perhaps social animations are boolean values? Since the macros like /dance are animations that start and stop. It's possible those are set to true or 0 or 1 and that starts the timer, it runs out and the value is reset to false.

The moods might work the same way?

happy = true and you stay happy, since it's not a timed animation.

or mood.happy=enabled.

Last edited by Kosmos : 03-02-2005 at 03:42 PM.
Reply With Quote
  #30  
Unread 03-04-2005, 03:28 PM
Kosmos's Avatar
Kosmos Kosmos is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Dec 2004
Server: Lucan DLere
Posts: 581
Default

Quote:
OnPress="somevalue=(Some math thing that results in the number 2)"

The first will execute /happy instead of /mood happy because /happy is a command. No known way to work around this.

If you are in two or more chat channels, then the second script may give the message Usage: /tellchannel <channelname> <message> because it thinks you're trying to talk in the second chat channel (/2 Hello!). I'm not certain how to work around it or why it started showing up with math calculations a patch or two ago.

I just had some real fun with this! Check the release section for the MainHUD.PerformancePanel mod for more details.

But this main thing is that if you are working with numbers on OnEvents.
Always. Always. Use Decimals. If you use decimal values you will not get the error in your chat window. It was causing some really freaky behavior with some things that was very hard to figure out. Some of the numbers would work and some wouldn't.. I tried switching the ones in my file that were causing the errors to decimal number, but that wouldn't fix the problem.
like r_light_priority=1 to r_light_priority=1.0 But that didn't fix it.
The reason was because there were OTHER numbers in the Event that would cause the error then. Once I changed ALL of them, the problem went away.

So, if you are getting those errors, throw a decimal in and you should be fine.
Reply With Quote
  #31  
Unread 03-04-2005, 05:00 PM
Deathbane27's Avatar
Deathbane27 Deathbane27 is offline
aka Mook
This person is a EQ2Map developer.
Interface Author - Click to view interfaces
 
Join Date: Jul 2004
Server: Nektulos
Posts: 1,451
Default

Quote:
Originally Posted by Kosmos
So, if you are getting those errors, throw a decimal in and you should be fine.
Thanks for the tip!
__________________
If it ain't broke, it needs more features!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 04:00 AM.


Our Network
EQInterface | EQ2Interface | WoWInterface | LoTROInterface | ESOUI | MMOUI