amnesia-spelos / amnesia-spelos/amnesia-tdd-tcp

Return script compilation result on exec:

Offen
#8 3 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
beginner-friendly enhancement first-timers-only good first issue help wanted
Vorherrschende Sprache
C++
Sterne
1
Forks
0
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

> 🏝️ **Want to work on this issue?**
> _Comment down below and we'll gladly assign it for you. No rush, no worries, we'll help you out if you get stuck._ 🌞
>
> If this is your first time contributing, see the [setting up the development environment](https://github.com/amnesia-spelos/amnesia-tdd-tcp/wiki/dev-env-setup) for a quick start.

## Summary

Currently, the `exec:` command returns `RESPONSE:exec:script executed`. If the script fails for whatever reason, the client is never told about the reason and the script fails silently.

Amnesia already has a feature to compile the script file with output:

```cpp
mpEngine->GetResources()->GetScriptManager()->CreateScript(sScriptFile, apOutput);
```

You can see this line along with its usage in [LuxMap.cpp#L421](https://github.com/amnesia-spelos/amnesia-tdd-tcp/blob/main/src/amnesia/src/game/LuxMap.cpp#L421).

We should be returning the output as part of `RESPONSE:exec`.

## Current Implementation

You can find the current implementation in the following file:

https://github.com/amnesia-spelos/amnesia-tdd-tcp/blob/c17c8b05f6d03249e844dd753405654f8412a713/src/amnesia/src/game/LuxSocketServer.cpp#L199-L211

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.