Merge pull request #83 from thecodingmachine/cleanup_rename_frame

Cleanup: renaming "frame" to "character"
This commit is contained in:
David Négrier 2020-05-08 16:21:16 +02:00 committed by GitHub
commit c59d693f6e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 49 additions and 49 deletions

View file

@ -83,12 +83,12 @@ export class Player extends PlayableCaracter implements CurrentGamerInterface, G
}
if (x !== 0 || y !== 0) {
this.move(x, y);
this.emit(hasMovedEventName, {direction, x: this.x, y: this.y, frame: this.PlayerTexture});
this.emit(hasMovedEventName, {direction, x: this.x, y: this.y, character: this.PlayerTexture});
} else {
if (this.previousMove !== PlayerAnimationNames.None) {
direction = PlayerAnimationNames.None;
this.stop();
this.emit(hasMovedEventName, {direction, x: this.x, y: this.y, frame: this.PlayerTexture});
this.emit(hasMovedEventName, {direction, x: this.x, y: this.y, character: this.PlayerTexture});
}
}