WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   Outputting to a chat (https://www.wowinterface.com/forums/showthread.php?t=21546)

Aetharan 03-30-09 06:04 PM

Outputting to a chat
 
I have noticed, while playing around with BattleCry, AnnoyRP, et. al. that of the ones I've tried, only BattleCry is capable of executing slash commands that are stored in its text boxes. I've taken a look into its guts, but (frankly) I'm very new to LUA and to WoW's API. What I have discovered is that BattleCry is using ChatEdit_SendText("msg") where the others appear to be using SendChatMessage("msg",[ "chatType",[ "language",[ "channel"]]]).

This has me wondering, from a theoretical viewpoint, which is better in the long run. If one is focusing on an addon of this type (with the ability to automatically post one of a set of predefined responses to an event such as a spellcast), which methodology has greater advantages, and why? Is this command the reason that slash commands work in Battlecry and not in (at least, the older version of) Segui?

I was fond of being able to setup custom sets in BattleCry for re-direction to a category (for example, Corruption could call one of its own cries, or a DoT general cry, or a Shadow, or just flat Hostile), and especially the ability to alter the timing via Chronos by simply using /in in the cries I created.

------------

Simply for clarification, I've been hoping to write my own version of this idea, after I've gotten my feet wet. This environment seems not too different from scripting in RUBY, so now I'm testing the waters.


All times are GMT -6. The time now is 04:20 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI