Skip to content

Commit

Permalink
Merge pull request #53 from bitfeed-project/v2.3.3
Browse files Browse the repository at this point in the history
2.3.3 pre-release changes
  • Loading branch information
mononaut authored Jun 11, 2022
2 parents 6fb78ec + aa8f1cc commit e3b5e75
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 10 deletions.
12 changes: 6 additions & 6 deletions client/src/models/TxBlockScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export default class TxBlockScene extends TxMondrianPoolScene {
color: tx.getColor('block', this.colorMode).color
},
duration: this.laidOut ? 1000 : 2000,
delay: 50,
delay: 200,
jitter: this.laidOut ? 500 : 1500,
smooth: true,
state: 'block'
Expand Down Expand Up @@ -125,14 +125,14 @@ export default class TxBlockScene extends TxMondrianPoolScene {
state: 'ready'
})
} else {
const jitter = (Math.random() * 1200)
const jitter = (Math.random() * 1500)
tx.view.update({
display: {
position: {
r: oldRadius + Math.max(2, oldRadius * 0.2)
},
},
delay: 50 + jitter,
delay: 200 + jitter,
start: now,
duration: 750,
smooth: true,
Expand All @@ -143,7 +143,7 @@ export default class TxBlockScene extends TxMondrianPoolScene {
color: ice(tx.colors[this.colorMode].block.color),
},
start: now,
delay: 50 + jitter,
delay: 200 + jitter,
duration: 500,
})
}
Expand Down Expand Up @@ -180,7 +180,7 @@ export default class TxBlockScene extends TxMondrianPoolScene {
},
start,
duration: 2000,
delay: 100,
delay: 200,
jitter: 500,
smooth: true,
})
Expand Down Expand Up @@ -217,7 +217,7 @@ export default class TxBlockScene extends TxMondrianPoolScene {
alpha: 0
}
},
delay: 100,
delay: 200,
start,
jitter: 500,
duration: 2000,
Expand Down
6 changes: 3 additions & 3 deletions client/src/models/TxPoolScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ export default class TxPoolScene {
}

clearOffscreenTx (tx) {
if (tx.pixelPosition && (tx.pixelPosition.y + tx.pixelPosition.r) < -(this.scene.offset.y + 100)) {
if (tx.pixelPosition && (tx.pixelPosition.y + tx.pixelPosition.r) < -(this.scene.offset.y + 50)) {
this.controller.destroyTx(tx.id)
}
}
Expand All @@ -114,9 +114,9 @@ export default class TxPoolScene {
position: tx.screenPosition
},
duration: 1000,
minDuration: 500,
minDuration: 200,
start: now,
delay: 50,
delay: 0,
smooth: true,
adjust: true
})
Expand Down
11 changes: 10 additions & 1 deletion client/src/models/TxSprite.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,16 @@ function interpolateAttributeStart(attribute, now, modular) {
// transition in progress
// (interpolate)
const progress = (now - attribute.t)
const delta = attribute.e ? smootherstep(progress / attribute.d) : (progress / attribute.d)
let delta = progress / attribute.d
if (attribute.boom) {
delta *= 2
if (delta > 1) {
delta = 2 - delta
}
}
if (attribute.e) {
delta = smootherstep(delta)
}
if (modular && Math.abs(attribute.a - attribute.b) > 0.5) {
if (attribute.a > 0.5) {
attribute.a -= 1
Expand Down

0 comments on commit e3b5e75

Please sign in to comment.