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

Digitization (PSNS) and Application of Digitized Pressure (PUMP) #532

Merged
merged 4 commits into from Mar 4, 2018

Conversation

Novocain1
Copy link
Contributor

No description provided.

@@ -70,6 +72,43 @@ int Element_PSNS::update(UPDATE_FUNC_ARGS)
}
}
}
else if (parts[i].tmp == 1) {
parts[i].life = 0;
for (rx = -2; rx < 3; rx++)
Copy link
Member

Choose a reason for hiding this comment

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

This entire for loop is completely unnecessary. You are looping through particles just to set photonWl to the current pressure.

int r, rx, ry, rt, rd = parts[i].tmp2;
float photonWl = 0.0f;
bool setFilt = false;
if (parts[i].tmp == 0 && (sim->pv[y/CELL][x/CELL] > parts[i].temp-273.15f))
Copy link
Member

Choose a reason for hiding this comment

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

I don't think this needs to be locked behind .tmp = 0. Maybe have it always sense anyway?

@jacob1 jacob1 added the New feature not implemented but should be label Feb 24, 2018
@jacob1 jacob1 added this to New Features in 93.0 Feb 25, 2018
@jacob1 jacob1 merged commit 68efe49 into The-Powder-Toy:master Mar 4, 2018
93.0 automation moved this from New Features to Completed Mar 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
New feature not implemented but should be
Projects
No open projects
93.0
  
Completed
Development

Successfully merging this pull request may close these issues.

None yet

2 participants