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

Emitter panel revision #346

Merged
merged 34 commits into from
Jun 12, 2020
Merged

Emitter panel revision #346

merged 34 commits into from
Jun 12, 2020

Conversation

nightm4re94
Copy link
Member

@nightm4re94 nightm4re94 commented Jun 8, 2020

This resolves #298 .
Instead of the entirely broken popup panel for Emitter manipulation, I introduced a hierarchy of PropertyPanels to modify Emitters on the fly and with more comprehensible controls.
Highlights:

  • Added a tabbed PropertyPanel to manipulate Emitters
  • Enhanced MapObjectInspector.
  • Introduced default values for EmitterData.
  • Introduced AntiAliasing for particles.
  • Introduced Rotation for all particles (Implement Particle rotation. #345).
  • Introduced Animation for SpriteParticles.
  • Streamlined ParticleTypes and introduced generic PolygonParticles.
  • Fixed particle bounding boxes.
  • Fixed emitter spawn rate
  • Renamed some Particle parameters.
  • Deprecated Spritesheet Emitters and Animation Emitters (functionality now available for all custom emitters).

Try a tabbed approach for the emitter panel.
Rename particleX to particleOffsetX.
Provide default emitter values.
Remove COLOR tab from emitter panel (will be found under STYLE).
Add ParticleType control.
Rename emitter's colorDeviation and alphaDeviation to colorVariance and alphaVariance.
Allow editing color and alpha variance in utiLITI.
…y particle parameters.

Remove RANDOM property for Particle parameters (always use given min/max values).
Re-enable EllipseOutlineParticles.
Rename ParticleType "DISC" to "ELLIPSE".
…lineOnly" for ShapeParticles.

Add Particle type TriangleParticle.
Add "outlineOnly" toggle button to emitter style panel.
Rename particle deltaX and deltaY to velocityX and velocityY.
Rename particle gravityX and gravityY to AccelerationX and AccelerationY.
Rename some particle MapObjectProperties to follow a universal naming convention.
Merge Velocity and Acceleration Panels in EmitterPropertyPanel to a single Motion panel.
Add Motion controls EmitterPropertyPanel.
…ticle ttl.

Make particle ttl a ParticleParameter.
Remove ttl from particle constructors as we always choose a random value between min and max.
Rename remaining instances of particle deltaX/deltaY and gravityX/gravityY to velocityX/velocityY and accelerationX/accelerationY.
Switch static step size data type for whole numbers to int in the EmitterPropertyPanel.
Add particle TTL controls to EmitterPropertyPanel.
Add collision controls to EmitterPropertyPanel.
Add particle fade on collision control to EmitterPropertyPanel.
Switch edit color icon in particle style panel.
Add tabbed panel for emitter style controls (color, text, sprite)
Allow adding multiple possible texts for particles to randomly choose from.
Remove emitter color probabilities.
Fix TextParticle collision and alignments.
Disable mutually exclusive panels in the Emitter Style Panel upon changing particle type.
Fix SpriteParticle bounding boxes.
Prevent null pointer when particle color is null while rendering.
Remove MapObjectProperty.Particle.SPRITE (use the generic MapObjectProperty.SPRITESHEETNAME instead)
Add loop controls to Emitter sprite panel.
Initialize SpriteParticles with a Spritesheet instead of a single image so that they can be animated.
Deprecate Spritesheet Emitters and Animation Emitters.
Remove LightParticle.
Support rotation and rotation over time for all particles.
Add AntiAliasing particle Parameter.
Override getBoundingBox for Shape particles to ensure correct collision.
Add Rotation tab to EmitterPropertyPanel.
Add particle AntiAliasing controls to EmitterPropertyPanel
Fix origin location for PolygonParticles.
Rename ParticleParameterModifier to DualSpinner as we're going to make it reusable for other purposes.
Group transform and scale controls in the MapObjectInspector.
Utilize createLayout to simplify MapObjectInspector's layout.
Grey out RenderType combobox for anything that's not a creature, prop, or emitter.
Prevent null reference when calling MopObject.toString().
Fix some code smells.
@nightm4re94 nightm4re94 merged commit 4e8afc4 into master Jun 12, 2020
@nightm4re94 nightm4re94 deleted the EmitterPanelRevision branch June 12, 2020 17:14
@steffen-wilke
Copy link
Contributor

Deprecated Spritesheet Emitters and Animation Emitters (functionality now available for all custom emitters).

Please consider removing these and provide a description on how to migrate/ how the new API looks like. I'd like to add this to the Release notes.

The goal is to not have any deprecated API as long as we're in alpha state. Once we reach the first stable version, changing the existing API will become more gracefully. And our version strategy will ensure a certain consistency within the API.

@steffen-wilke
Copy link
Contributor

The recent changes also introduced lots of new CODE_SMELLS. Please attempt to resolve them where possible.

https://sonarcloud.io/project/issues?id=de.gurkenlabs%3Alitiengine&resolved=false&sinceLeakPeriod=true&types=CODE_SMELL

@nightm4re94
Copy link
Member Author

Deprecated Spritesheet Emitters and Animation Emitters (functionality now available for all custom emitters).

Please consider removing these and provide a description on how to migrate/ how the new API looks like. I'd like to add this to the Release notes.

The goal is to not have any deprecated API as long as we're in alpha state. Once we reach the first stable version, changing the existing API will become more gracefully. And our version strategy will ensure a certain consistency within the API.

I am very aware of this 👌

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.

Fix Emitter editing
2 participants