- Joined
- Feb 6, 2014
- Messages
- 2,466
There are two TimerUtils, one is TimerUtils by Vexorian and the other is TimerUtilsEx by Magtheridon96. Now, how do I make the library required to use one of them but not both?
As of now this is what I do
But I think there is a better formal way to do this.
EDIT: It will automatically create error when I used NewTimerEx(someInt) so that's good and no need for the intentional error. However, I'm still interested on how to implement this correcty.
As of now this is what I do
JASS:
optional TimerUtils
optional TimerUtilsEx
...
...
static if LIBRARY_TimerUtils then
else if LIBRARY_TimerUtilsEx then
else
//Throw Error
.
endif
But I think there is a better formal way to do this.
EDIT: It will automatically create error when I used NewTimerEx(someInt) so that's good and no need for the intentional error. However, I'm still interested on how to implement this correcty.