trigger with shared functions?

waaaks!

Zinctified
Reaction score
255
how to make functions in a trigger that can be used by other triggers?

like if i put a function in this trigger, the function inside that trigger can be used by other triggers
 
Reaction score
456
This shall be our first trigger.
JASS:
library myFunctions

function NoIdea takes nothing returns nothing
endfunction

endlibrary


This shall be our second trigger.
JASS:
library myOtherFunctions requires myFunctions

function IHaveAnIdea takes nothing returns nothing
    call NoIdea()   
endfunction

endlibrary


As the library myOtherFunctions requires the library myFunctions, the myFunctions library is checked (when you save) before the myOtherFunctions library.
 

waaaks!

Zinctified
Reaction score
255
how about cs cache?
its in the trigger right?

but when i call a function in it, why does it works even if i didnt used libraries in my trigger?
 
Reaction score
456
JASS:
library myLib requires CSCache
//functions here
endlibrary

Make your trigger require the CSCache trigger's library like that.
 
Reaction score
456
I meant that "make your trigger's library require CSCache trigger's library".
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top