Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implementation of spy action #292

Merged
merged 10 commits into from
Jun 1, 2020
Merged

Implementation of spy action #292

merged 10 commits into from
Jun 1, 2020

Conversation

authaldo
Copy link
Contributor

@authaldo authaldo commented May 30, 2020

fixes #264
fixes #140

@authaldo authaldo requested review from ottojo, Marco5de and csacro May 30, 2020 20:56
@authaldo authaldo self-assigned this May 30, 2020
src/gameLogic/execution/ActionExecutor_Spy.cpp Outdated Show resolved Hide resolved
src/gameLogic/execution/ActionExecutor_Spy.cpp Outdated Show resolved Hide resolved
@ottojo
Copy link
Member

ottojo commented May 30, 2020

bitte den grad der verschachtelung reduzieren durch hilfsfunktionen

@authaldo authaldo requested a review from ottojo May 31, 2020 08:14
@authaldo authaldo marked this pull request as ready for review May 31, 2020 08:23
Copy link
Member

@csacro csacro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Den maxSafeIndex könnte man als zusätzlichen member von State machen und im Konstruktor mit initialisieren, denn der Wert ändert sich während des gesamten Spiels nicht (zumindest für mein Verständnis). Um die Komplexität rauszunehmen, könntest du die bereits existierende GameLogicUtils Methode getAllFieldsWith(...) nutzen und dann die Länge des return Vektors als maxSafeIndex setzen.

Genauso könnte collarOnMap ein member von State sein, der initial false ist und in der execute im case // first character gets diamond collar auf true gesetzt wird.

src/gameLogic/execution/ActionExecutor_Spy.cpp Outdated Show resolved Hide resolved
src/gameLogic/execution/ActionExecutor_Spy.cpp Outdated Show resolved Hide resolved
src/gameLogic/execution/ActionExecutor_Spy.cpp Outdated Show resolved Hide resolved
@ottojo
Copy link
Member

ottojo commented May 31, 2020

Bin kein fan von den member variablen - das passiert schnell dass die info divergiert vom eigentlichen zustand. Momentan wird das z.b. nicht updated wenn der State deserialisiert wird...

@authaldo authaldo requested review from ottojo and csacro May 31, 2020 15:00
@authaldo authaldo requested a review from ottojo May 31, 2020 15:27
@sonarcloud
Copy link

sonarcloud bot commented May 31, 2020

SonarCloud Quality Gate failed.

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@authaldo authaldo merged commit 6e85927 into develop Jun 1, 2020
@authaldo authaldo deleted the featureSecrets branch June 1, 2020 14:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ausführung der Spy Action Action execution doesn't convert secrets to ip
3 participants