07/24/14, 02:19 PM | #21 | |
|
xml Code:
While this seems to be valid XML, but EventExploerWindowSrcoll stays nil for some reason so I cannot assign anything to it: xml Code:
|
|
07/24/14, 06:18 PM | #22 | |
|
I think you misunderstood me Keep your XML exactly as you had it on the previous page. Only change the parent in Lua code from EventExplorerWindowScroll to EventExplorerWindowScrollContents.
xml Code:
You see? By inheriting from ZO_ScrollList, you get a control which has a child named "Contents" where you put all the controls you want in the scrollable window. It's parent is your EventExplorerWindow->Scroll, thus the full name is EventExplorerWindowScrollContents. |
|
07/25/14, 05:40 AM | #23 | |
|
After some tests to get the name right I got it added to the proper container. But there are still two issues: The ScrollBar starts out hidden (I forced it visible by calling SetHidden via Zgoo wich hands in nil). And (propably releated) it is not not as scrolly as I picutred it to be: As can be expected it cannot be dragged and does not react to mousewheel. My guess is that the Scroll element caleld "Contents" is not properly aware of the size of it's contents. So it confines itself to Anchor size. |
|
07/25/14, 06:04 AM | #24 |
ZO_ScrollList is much more complex template then ZO_ScrollContainer. If you are not going to use ZO_ScrollList functions it's much easier to use the ZO_ScrollContainer template.
For example if you want to add data to the ZO_ScrollList, you should use: function ZO_ScrollList_AddDataType(self, typeId, templateName, height, setupCallback, hideCallback, dataTypeSelectSound, resetControlCallback) Working example is in pills' ScrollListExample addon which I have linked before. |
|
07/25/14, 11:57 AM | #25 | |
|
Right now only one piece seems to be missing: The scroll is not expanding to the summed size of the labels. This is just a basic layout issue (contaienr not aware of it's contents size), nothing more. Right now first Label is anchored with the Scroll, but all further ones are anchored with the previous labels. Maybe changing that up or directly overriding the Scrolls height based on the label count will deal with that. If we just had something like a WPF Stackpannel it would be childs play to do this. |
|
07/25/14, 12:11 PM | #26 |
I'm just curious, but what will be the difference between this and the event viewer in Zgoo?
|
|
07/25/14, 12:44 PM | #27 | |
|
But it is more like a "all event log" where you have to explicitly unregister events (and cannot just easily turn them back on). If you want only a specific event to be tracked, you have a lot of excluding to do. What are the differences? You can explicilty register and unregister events at runtime. It provides an overview of all Events so you can look wich ones are avalible at realtime. As a side effect: I will also finally learn a bit about ESO UI XML. Wich means I can afterwards make the wiki a bit newcommer friendly. Maybe even make the odd usefull tool or two (this game UI could really use a StackPanel and similar containers). |
|
07/25/14, 12:58 PM | #28 | ||||
|
This is the (complete) documentation for ZO_ScrollContainer:
With ZO_ScrollList, you have to supply a row setup function and raw data, and it creates the required row controls as it needs them. I think a good example is Inventory window. If you have 100 items, it probably doesn't contain 100 rows, but only as many as are simultaneously visible, and fills them with item data as you scroll. |
||||
07/25/14, 02:28 PM | #29 | |
Btw, where did you get that from? There is nothing about that in the wiki. |
||
07/25/14, 03:00 PM | #30 |
|
That from client scripts.
|
07/25/14, 04:00 PM | #31 |
|
There are some scripts (which likely violate the TOS) that you can find online and use to extract assets from the compressed data files. If you extract those, you can find existing LUA definitions (and documentation) of some of the ZOS functions and default UI and such.
|
07/25/14, 05:14 PM | #32 |
|
Which is pretty absurd in my opinion - these files are not protected in any way other than legal rubbish. They could've been just zipfiles, or ZOS could've given addon developers an unpacker. Instead, people waste their time reversing data formats, writing their own unpackers (the simplest of which doesn't even need reversing anything). And as Sephiroth wrote, addon developers waste their time reinventing the wheels that are already there, so they have less time to develop something new for ESO.
|
07/25/14, 05:39 PM | #33 |
|
I agree that closing down Addon development is counter-productive. It is in the TOS, however, and pursuing extraction of the .dat files could open you up to some sort of reprisal by Zenimax. Will they? Probably not. Could they? Yes.
Ideally they'd compile the documentation in some sort of Javadoc-style documentation and release that (instead of a list of functions) for the API. I mean, it takes all to 15 seconds in Google to find one exists (LuaDoc) and in a business-compatible license. I'd expect any SDE could get it setup and running in a couple hours and then for each release it'd only take probably 1 minute to re-run the script and update it -- less if they get it built-in as a target for the build/make script. |
07/25/14, 05:46 PM | #34 |
It maybe absurd but it is a violation of the TOS to extract the default UI code from the dat files. ZeniMax has not given written authorization to view it. It maybe a simple compression algorithm but you are decompiling the source code at your own risk to lose your ESO account. It is one thing to open a plain text file and something else when ZeniMax took the effort to obfuscate it even a little. You can call it legal rubbish all you want they still could deny you service for the violation.
It would be wonderful if they gave an approved de-packing tool and more documentation. It's been requested. The fine folks that host this site ask ZeniMax consistently if the default UI code can be publicly posted. The legal depart of ZeniMax continue to drag their feet on saying yes. |
|
07/25/14, 09:57 PM | #35 |
ESOUI has asked Zenimax if we could release the source code, and they have not ever gotten back to us with an answer.
|
|
ESOUI » Developer Discussions » Lua/XML Help » Creating a whole bunch of Elements dynamic from code |
«
Previous Thread
|
Next Thread
»
|
Display Modes |
Linear Mode |
Switch to Hybrid Mode |
Switch to Threaded Mode |
|
|