-
Notifications
You must be signed in to change notification settings - Fork 115
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
Standardised explosives #113
Conversation
The explode-function does not yet actually blow anything up, but the particles are pretty
Added back the cannon, using the functionality provided by the rewrite.
Added screenshake to cannon. Resolved conflicts and made cannon work with newest codebase
Currently used by cannonballs, should work for grenades and mines as well
Is this intended to be merged on top or instead #104 ? |
Well, all the previous pulls are based of each other. I'll close those |
Removed utils.rs for now, and moved the containing code to explosive.rs. Also formatting
I tested this and it appears to me that setting |
Resolve fishfolk#99. * Checked out from 3ba21b6 — the last commit where this weapon existed. * Uses work in progress from fishfolk#113 for explosive projectiles.
Resolve fishfolk#99. * Checked out from 3ba21b6 — the last commit where this weapon existed. * Uses work in progress from fishfolk#113 for explosive projectiles.
I realise I never actually tested that... Options are probably the cleanest way to handle it. I'm fairly busy the next days but I might be able to sneak in some work tonight and fix it. |
Added options to fuse and trigger radius, fixed unfused explosives detonating immediately. Also restructured explosive.rs so that it is not a mod.
1ca906a
to
b96742b
Compare
There we go. This should be done now, unfused explosives work correctly. Also I figured out how imports and stuff works so explosive.rs doesn't use a mod any more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works for me!
- With
fuse: Some (0.)
, the explosive explodes immediately. - With
fuse: None
, the explosive stays around indefinitely, waiting to be triggered.
This aligns with my expectations.
I did not look at the rest of the code thoroughly — I do not really know Rust anyway.
With a pedant hat on, I should suggest splitting the pull request into 2:
- Add standardized explosives. (This pull request, with changes pertinent to the cannon left out.)
- Add the cannon. (Another pull request, containing the changes left out of this one.)
I should also suggest squash merging.
Alright, the commits contain changes for both cannon and explosive so I'll just squash it all. But I'll keep it in mind for next time! |
Resolve fishfolk#99. * Checked out from 3ba21b6 — the last commit where this weapon existed. * Uses work in progress from fishfolk#113 for explosive projectiles.
Resolve fishfolk#99. * Checked out from 3ba21b6 — the last commit where this weapon existed. * Uses work in progress from fishfolk#113 for explosive projectiles.
Draft for a generic explosive node. Used by cannonballs, should be easily repurposed for grenades and mines.