Is there any downside of using all the modules in every script?
In most of the complicated scripts it happens anyway through the link of chained includes.
Does using excess modules slow down the script?
Thank you.
"use" directive - using all the modules
Re: "use" directive - using all the modules
apart from the npc modle, I see no problem using all the modules in scripts ( I do it already, because Im lazy to use them separate )
Re: "use" directive - using all the modules
If I remember right - in the core the module functions are matched up; It uses the module IDs in the script to limit the function pointer tables the core will look in.
If you have unnecessary modules used, it can cause an insignificant slow down.
If you have unnecessary modules used, it can cause an insignificant slow down.
Re: "use" directive - using all the modules
Thank you, I appreciate your help.
Re: "use" directive - using all the modules
That's one thing I've always hated in the way my shard was originally written was includes using modules or including other files. While rewriting my shard I've enforced only allowing "use" and "include" inside the src file, not in any include files.
Re: "use" directive - using all the modules
Ill check sometime.. its been a while since I looked at the core.
I do know during compile it wont use any functions in an include that were not called when it builds the ECL.
Not sure if it does the same for the use commands (ignore a use command if no function was called in it)
I do know during compile it wont use any functions in an include that were not called when it builds the ECL.
Not sure if it does the same for the use commands (ignore a use command if no function was called in it)