Skip to content

Commit

Permalink
completed ranger sean
Browse files Browse the repository at this point in the history
  • Loading branch information
xjyribro committed Feb 27, 2024
1 parent a4991ff commit 845a334
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/game/npcs/ranger.dart
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,11 @@ class Ranger extends Npc with HasGameReference<GomilandGame> {
YarnProject yarnProject = YarnProject();

int bagSize = game.gameStateBloc.state.bagSize;
yarnProject.strictCharacterNames = false;

yarnProject
..variables.setVariable('\$coins', game.gameStateBloc.state.coinAmount)
..commands.addCommand0('upgradeBag', upgradeBag)
..parse(await rootBundle.loadString(Assets.assets_yarn_friend_yarn));
..parse(await rootBundle.loadString(Assets.assets_yarn_ranger_yarn));
DialogueRunner dialogueRunner = DialogueRunner(
yarnProject: yarnProject, dialogueViews: [dialogueControllerComponent]);
await dialogueRunner
Expand All @@ -85,7 +84,7 @@ class Ranger extends Npc with HasGameReference<GomilandGame> {
}

void upgradeBag() {
game.gameStateBloc.add(const SetBagSize(20));
game.gameStateBloc.add(const SetBagSize(mediumBagSize));
deductCoins(game, 500);
}
}

0 comments on commit 845a334

Please sign in to comment.