aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorAlan Alpert <alan.alpert@nokia.com>2011-10-20 16:58:06 +1000
committerQt by Nokia <qt-info@nokia.com>2011-10-24 12:36:29 +0200
commit34cefb69b3f36d7eed9f50a2190459fbae0681de (patch)
tree11c3727eb27f8bb02df1f63d779ad4ede6ee1a7c /examples
parent89fb0fb65d0071e88f24b8022eb7070956a7a1a7 (diff)
Affectors now simulate with a minimum granularity
Since all time is sourced from the ParticleSystem, the easiest way is to alter the common time point while doing the multiple simulation runs. Also removes the experimental TargetAffector. Change-Id: Ieb52f8990445fe95f94070175a0f9beb6686324a Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/declarative/particles/affectors/attractor.qml48
1 files changed, 25 insertions, 23 deletions
diff --git a/examples/declarative/particles/affectors/attractor.qml b/examples/declarative/particles/affectors/attractor.qml
index d6660d6a0d..c5bc4fdd5f 100644
--- a/examples/declarative/particles/affectors/attractor.qml
+++ b/examples/declarative/particles/affectors/attractor.qml
@@ -178,29 +178,31 @@ Rectangle {
drag.axis: Drag.XandYAxis
drag.target: ship
}
- Emitter {
- group: "engine"
- system: particles
- emitRate: 200
- lifeSpan: 1000
- size: 10
- endSize: 4
- sizeVariation: 4
- speed: PointDirection { x: -128; xVariation: 32 }
- height: parent.height
- width: 20
- }
- Emitter {
- group: "shot"
- system: particles
- emitRate: 32
- lifeSpan: 2000
- enabled: spacePressed
- size: 40
- speed: PointDirection { x: 256; }
- x: parent.width
- y: parent.height/2
- }
+ }
+ Emitter {
+ group: "engine"
+ system: particles
+ emitRate: 200
+ lifeSpan: 1000
+ size: 10
+ endSize: 4
+ sizeVariation: 4
+ speed: PointDirection { x: -128; xVariation: 32 }
+ height: ship.height
+ y: ship.y
+ x: ship.x
+ width: 20
+ }
+ Emitter {
+ group: "shot"
+ system: particles
+ emitRate: 32
+ lifeSpan: 2000
+ enabled: spacePressed
+ size: 40
+ speed: PointDirection { x: 256; }
+ x: ship.x + ship.width
+ y: ship.y + ship.height/2
}
Text {