PDA

View Full Version : Environment Variables


CrazyHackGUT
03-10-2020, 07:30
This extension exposes getenv() C function to SourcePawn API. Currently is named as GetEnvironmentVariable().
Requires SourceMod 1.10 or higher.

Installation


Open page with latest releases.
Find your platform in assets list and download archive.
Unzip archive to your server directory.
Restart.

Helpful links


Source code (https://github.com/CrazyHackGUT/sm-env/tree/master/src)
Include file (https://github.com/CrazyHackGUT/sm-env/blob/master/package/scripting/include/env_variables.inc)
Usage example (https://github.com/CrazyHackGUT/sm-env/blob/master/package/scripting/env_test.sp)

https://github.com/CrazyHackGUT/sm-env/workflows/CI/badge.svg (https://github.com/CrazyHackGUT/sm-env/actions?query=workflow%3ACI) https://img.shields.io/github/v/release/CrazyHackGUT/sm-env?include_prereleases (https://github.com/CrazyHackGUT/sm-env/releases/latest)

CrazyHackGUT
03-15-2020, 06:13
In latest release (v1.0.0.2) added ability change environment variables. This can be useful in cases when you starts another process from SourcePawn plugin with using extensions like System2 (https://forums.alliedmods.net/showthread.php?t=146019).

ImACow
03-16-2020, 15:32
Nice!

This is very usefull!

Thanks a bunch!