1 decade ago by congwang0517
if i want to resize a entity's size by it's 80%,what i should do?
This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact
var factor = 0.8; // Increase size by 80% this.size.x += this.size.x * factor; this.size.y += this.size.y * factor; // Or... // Resize to 80% of original size. this.size.x = this.size.x * factor; this.size.y = this.size.y * factor;