TimedEventLinkedList v1.2

TimedEventLinkedList
IMPORT GUIDE :
1. Enable "Tick the Automatically create unknown variables ..." located at File>Preference>General
2. Copy the TimedEventLL Folder in the Trigger Editor to your map
3. Configure the TELLConfig trigger according to the comments provided
4. Configure triggers that will utilize TimedEventLinkedList

NOTE: if you are importing TimedEventLinkedList as a requirement for another resource, only step 1-3 is needed. Step 4 is for those who wants to use this as a requirement for their systems.

SYSTEM INFORMATION :
This system is designed to be a base for all Linked List related needs in GUI. The system allows one to create triggers without delving deep into the mechanics of Linked List and focuses on getting their triggers works, benefitting on the instancing capability of Linked List.

In short, to register an instance of Linked List, the following data needs to be provided:
  • TELLSampleTrigger
    • Events
    • Conditions
    • Actions
      • -------- TimedEventLinkedList works by having a specified duration --------
      • Set TELLDuration = 0.00
      • -------- OnEventAlloc is equal to OnIndexEvent, where TimedEventLinkedList started to allocate an instance --------
      • -------- Setting values to be used later on is best done during OnAllocEvent --------
      • Set TELLOnEventAlloc = TELL_TriggerEmptyEvent
      • -------- The loop event is triggered every TELLOnEventLoopTimer duration --------
      • Set TELLOnEventLoop = TELL_TriggerEmptyEvent
      • -------- If OnEventLoopTimer is lower than TimerTIMEOUT, it is automatically set to the timeout value --------
      • Set TELLOnEventLoopTimer = 0.00
      • -------- OnEventDealloc is equal to OnDeindexEvent or OnEndEvent, where the instance has been deallocated and cleaning up can be done --------
      • -------- NEITHER OnEventLoopTimer NOR Duration CAN BE MODIFIED DURING OnEventDealloc --------
      • -------- Check the duration during OnEventLoop instead if you need them --------
      • Set TELLOnEventDealloc = TELL_TriggerEmptyEvent
      • -------- Register to system at the end --------
      • Trigger - Run TELL_TriggerRegister (checking conditions)
This system is meant to be abstract where it can be conveniently used as a dependency for other timed systems or timed spells or triggering in general. The API is intentionally designed to be simple since it is meant to be usable for different needs, as long as it is time-based.

The '_' in variables indicate their accessibility:
no '_' = register variable only
'_' = DO NOT TOUCH AT ALL COST
'__' = OnEventAllocate, OnEventLoop, and OnEventDealloc variables; can be edited except TELL__Index

This system is limited by the maximum array provided by Warcraft 3. However, I believe it is a minimal issue since it is unlikely to hit the limit without being very intentional about it, even when multiple resource utilizing it.

MEDIA SHOWCASE :
CHANGELOG :
Version 1.2:
- Added a reset of TELL__Index before Deallocation section is executed (CRITICAL: Fix a bug that occurs when creating an instance on 0.00 TELL duration)
Version 1.1:
  • Shifted all TELLLoop trigger variables to use TELL_TempID instead of TELL__Index for additional safety layer against TELL__Index accidental manipulations (since it is meant as a getter, but some people might thought they can set it by accident)
  • Fix a critical bug when instantiating an instance inside another instance (a major bug for TimedSpecialEffect)
  • During Allocation, use the TELL__Alloc** instead of TELL__** variables when using setters! TELL__Index is safe for use during Allocation
Version 1.0.1: Improved the import guide and added additional information regarding system limitation
Version 1.0: Released

CREDIT :
- Maker for Linked List instead of Dynamic Indexing thread
Contents

TimedEventLinkedList v1.2 (Map)

Reviews
Wrda
An interesting system which specially maintains the order of causality, perfect for timed related concepts. Sometimes you use TELL__Index other times you use TELL_TempID in TELLLoop trigger. I think you can simply use TELL__Index to simplify. As...
An interesting system which specially maintains the order of causality, perfect for timed related concepts.
Sometimes you use TELL__Index other times you use TELL_TempID in TELLLoop trigger. I think you can simply use TELL__Index to simplify.
As usual, nicely done.

Approved


Merry Christmas ;)

Thank you for the approval! Happy holidays!

About TELL__Index, I agree that it serves better than TELL_ID, it just that TELL_ID helped me better relate to Maker concept for GUI Linked List, while TELL__Index is used so those who used to Dynamic Indexing or older indexing approaches can understand the idea without dealing with the details.

The whole idea is "You need an Index? Just use TELL__Index". People can have no knowledge on Linked List and still benefit if they know Indexing.
 
v1.1:
  • Shifted all TELLLoop trigger variables to use TELL_TempID instead of TELL__Index for additional safety layer against TELL__Index accidental manipulations (since it is meant as a getter, but some people might thought they can set it by accident)
  • Fix a critical bug when instantiating an instance inside another instance (a major bug for TimedSpecialEffect)
  • During Allocation, use the TELL__Alloc** instead of TELL__** variables when using setters! TELL__Index is safe for use during Allocation
 
There's a bug from TSELL and DOT system interaction that I cannot patch with TELL, hence I have rewritten DOT system to discard TELL requirement and become standalone. I will update this resources with the new DOT system.

The bug can be found when there's dead corpse of a unit kept getting burnt by Amaterasu or triggered at somewhat random occurence when DOT and TSELL collides.

So yeah, I think this little script is one abominable monster behind the scene. I would not recommend TELL as direct requirement for any system as of this point since I cannot resolve the collision from multiple system directly interacting with TELL. I would recommend layering systems above TSELL since it has more safety net against weird behaviors in TELL that I cannot deduce right now, as proven with Stun Snippet Linked List.
 
Version 1.2:
- Added a reset of TELL__Index before Deallocation section is executed (CRITICAL: Fix a bug that occurs when creating an instance on 0.00 TELL duration)

I think this system might have hidden issues that occurs on very specific edge cases I have yet to find out (both v1.1 and v1.2 fixes comes as I try to solve issue within my spells). To the best of my current knowledge, there's no major issue remaining for all systems it currently handles. I am planning to reinstate DamageOverTime that uses LinkedList which I remove in favor of Dynamic Indexing due to the bug I just solved.
 
Top