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

Add vent carbon dioxide function in Zirnox for OpenComputers #1873

Merged
merged 3 commits into from
Jan 20, 2025

Conversation

Agarmal
Copy link
Contributor

@Agarmal Agarmal commented Jan 16, 2025

yes,
took me like 5 minutes (too much work ik).
image

The function is called ventCarbonDioxide.

Copy link
Contributor

@BallOfEnergy1 BallOfEnergy1 left a comment

Choose a reason for hiding this comment

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

Other than the changes requested, this seems to be in working order. Hope to see it in the mod soon.

… also no longer writes the value before correcting if it's negative.
@Agarmal
Copy link
Contributor Author

Agarmal commented Jan 17, 2025

Other than the changes requested, this seems to be in working order. Hope to see it in the mod soon.

Changes commited, just tell me if there are other issues. (BTW, the control function used by the gas vent valve in the GUI corrects the fill value after setting it, which is the reason mine also was like that)

@Agarmal
Copy link
Contributor Author

Agarmal commented Jan 17, 2025

I used Math.min(...) and Math.max(...), but I can use conditionals if it gets too complicated.

@HbmMods
Copy link
Owner

HbmMods commented Jan 17, 2025

You can use MathHelper.clamp_int(value, min, max) for stuff like that

@Agarmal
Copy link
Contributor Author

Agarmal commented Jan 17, 2025

You can use MathHelper.clamp_int(value, min, max) for stuff like that

Oh, ty for the tip

@HbmMods HbmMods merged commit 2d007e8 into HbmMods:master Jan 20, 2025
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.

3 participants