PDA

View Full Version : Retrieving which extension gets loaded


xerox8521
10-11-2014, 13:20
Hi,

is there a way to retrieve which version of an extension is loaded. For example wheter it is sdktools.ext.1.ep1 or sdktools.ext.2.css or sdktools.ext.2.l4d2 ?
GetExtensionFileStatus probably needs the exact name (except for the .dll or .so).

Edit: sm exts list then sm exts info extension id ( you get the id from sm exts list between []

Powerlord
10-11-2014, 14:59
Out of curiosity, why would you need to know this?

If you want which game is running, use GetEngineVersion (https://sm.alliedmods.net/api/index.php?fastload=show&id=1076&), which compares against the EngineVersion (https://sm.alliedmods.net/api/index.php?fastload=file&id=5&file=&) enum values.

psychonic
10-11-2014, 15:01
GetExtensionFileStatus probably needs the exact name (except for the .dll or .so).
It doesn't, but you shouldn't be using it. Use LibraryExists with the library name registered by the extension.