slimmed down
This commit is contained in:
@@ -57,11 +57,10 @@ The C# wrapper is in:
|
||||
examples/CounterStrikeSharp/SendProxyNative.cs
|
||||
```
|
||||
|
||||
It loads the native addon with `NativeLibrary.Load` and exposes byte-oriented and typed helpers. In a CSS plugin, resolve the native library from the normal addons layout:
|
||||
It loads the native addon with `NativeLibrary.Load` and exposes byte-oriented and typed helpers. In a CSS plugin, resolve the native library from `Server.GameDirectory`:
|
||||
|
||||
```csharp
|
||||
string addonsDirectory = Path.GetFullPath(Path.Combine(ModuleDirectory, "..", "..", ".."));
|
||||
string libraryPath = Path.Combine(addonsDirectory, "sendproxy", "bin", "linuxsteamrt64", "sendproxy.so");
|
||||
string libraryPath = Path.Combine(Server.GameDirectory, "addons", "sendproxy", "bin", "linuxsteamrt64", "sendproxy.so");
|
||||
var sendProxy = new SendProxyNative(libraryPath);
|
||||
|
||||
int ruleId = sendProxy.SetInt32(
|
||||
|
||||
Reference in New Issue
Block a user