Skip to content
This repository has been archived by the owner on Mar 3, 2024. It is now read-only.

Commit

Permalink
reduce performance hit, issue #10
Browse files Browse the repository at this point in the history
create a canvas to transite imagedata and reuse instead of realocating every instant.
  • Loading branch information
ericoporto committed Nov 6, 2016
1 parent 7b5f3c2 commit 98b33bd
Show file tree
Hide file tree
Showing 3 changed files with 286 additions and 288 deletions.
4 changes: 3 additions & 1 deletion src/battle.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,9 @@ battle.start = function(monsterlist, musicBattle, musicHuzzah) {
battle.xpreward = 0;

if (monsterlist.length > 1) {
dist.efnumb[0] = 31
dist.prepareBgEffect(31);
} else {
dist.prepareBgEffect(1);
}

for (var i = 0; i < player.party.length; i++) {
Expand Down
Loading

0 comments on commit 98b33bd

Please sign in to comment.