Skip to content

Commit

Permalink
add check if null to ComponentSimulator
Browse files Browse the repository at this point in the history
  • Loading branch information
Siocnarff committed Nov 5, 2020
1 parent d12d896 commit e9605de
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 3 additions & 0 deletions src/eng/buildings/ComponentSimulator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
using namespace eng;

void ComponentSimulator::testComponent(Component* component) {
if (!component) {
return;
}
int label = component->quality;
label += (rand()%5)-2;
if (label > 100) {
Expand Down
6 changes: 3 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ void proto_FinalMain();

int main() {

logDeptTesting();
//logDeptTesting();
//engTeamTesting();
//seasonRun();
// proto_FinalMain();
// testTyres();
proto_FinalMain();
//testTyres();



Expand Down

0 comments on commit e9605de

Please sign in to comment.