forked from nusCS2113-AY1920S1/PersonalAssistant-Duke
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #219 from tzw0/FarmLogic
ascii art and minor changes
- Loading branch information
Showing
76 changed files
with
738 additions
and
101 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,19 @@ | ||
Day ends | ||
|
||
* * _ . | ||
_ . ( _ )_ * | ||
( _ )_ (_ _(_ ,) | ||
(_ _(_ ,) * | ||
|
||
* * | ||
, . .--. | ||
__|__ |____| | ||
/ \ |____| | ||
/ [] |____| | ||
|__________| | | ||
| ____ | | | ||
| |\ /| | | _[_]_ | ||
| | \/ | | | ( " ) | ||
| | /\ | | | ,(-)' | ||
|__|/__\|__|__| -"- | ||
_______________________________________________________ | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,16 @@ | ||
0 | ||
.______.__________________._________________. | ||
|-Task-|----CONDITION-----|------ACTION-----| | ||
|do | |gotoMarket | | ||
| | |buySeeds | | ||
| | |gotoWheatFarm | | ||
| | |plantSeeds | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
| | | | | ||
|______|__________________|_________________| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,16 @@ | ||
\ \ / /__| | ___ ___ _ __ ___ ___ | ||
\ \ /\ / / _ \ |/ __/ _ \| '_ ` _ \ / _ \ | ||
\ V V / __/ | (_| (_) | | | | | | __/ | ||
\_/\_/ \___|_|\___\___/|_| |_| |_|\___| | ||
_____ | ||
|_ _|__ | ||
| |/ _ \ | ||
| | (_) | | ||
_____ |_|\___/ _ | ||
| ___|_ _ _ __ _ __ ___ (_) ___ | ||
| |_ / _` | '__| '_ ` _ \| |/ _ \ | ||
| _| (_| | | | | | | | | | (_) | | ||
|_| \__,_|_| |_| |_| |_|_|\___/ | ||
|
||
|
||
|
||
\ \ / /__| | ___ ___ _ __ ___ ___ | ||
\ \ /\ / / _ \ |/ __/ _ \| '_ ` _ \ / _ \ | ||
\ V V / __/ | (_| (_) | | | | | | __/ | ||
\_/\_/ \___|_|\___\___/|_| |_| |_|\___| | ||
_____ | ||
|_ _|__ | ||
| |/ _ \ | ||
| | (_) | | ||
_____ |_|\___/ _ | ||
| ___|_ _ _ __ _ __ ___ (_) ___ | ||
| |_ / _` | '__| '_ ` _ \| |/ _ \ | ||
| _| (_| | | | | | | | | | (_) | | ||
|_| \__,_|_| |_| |_| |_|_|\___/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package commands; | ||
|
||
import farmio.Farmio; | ||
import farmio.Storage; | ||
|
||
public abstract class CommandChangeTask extends Command { | ||
|
||
protected void saveTask(Farmio farmio) { | ||
Storage storage = farmio.getStorage(); | ||
storage.storeFarmer(farmio.getFarmer()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package commands; | ||
|
||
import exceptions.FarmioFatalException; | ||
import farmio.Farmio; | ||
import farmio.Level; | ||
import frontend.Ui; | ||
|
||
public class CommandTaskAddReset extends Command { | ||
|
||
/** | ||
* Print hint or instructions for current level. | ||
* @param farmio the game which level is used to determine hint. | ||
* @throws FarmioFatalException if simulation file is not found. | ||
*/ | ||
@Override | ||
public void execute(Farmio farmio) throws FarmioFatalException { | ||
Ui ui = farmio.getUi(); | ||
Level level = farmio.getLevel(); | ||
farmio.getSimulation().simulate(level.getPath() ,level.getNarratives().size() - 1); | ||
ui.show("Enter [Start] if you are ready to complete the objective or Enter [HINT] if you get stuck!"); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.