Skip to content

Commit

Permalink
Add a waypoint to the tutorial quest master upon starting a new game
Browse files Browse the repository at this point in the history
+ Add 4 new items
+ Add paragraph (`{p}`) tag to text substitutor
+ Bump version to v0.49.20
  • Loading branch information
Hitonoriol committed Jun 10, 2023
1 parent e1a9df7 commit f2d5e57
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 17 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ gradle.startParameter.showStacktrace = org.gradle.api.logging.configuration.Show
/* App metadata */
ext {
appName = "MadSand"
versionCode = '0.49.19'
versionCode = '0.49.20'
author = 'Hitonoriol'
}

Expand Down
28 changes: 28 additions & 0 deletions core/assets/items.json
Original file line number Diff line number Diff line change
Expand Up @@ -1917,5 +1917,33 @@
"@type" : "Consumable",
"weight" : 0.35,
"category" : {"Food":3}
},
"199" : {
"name" : "Fish Eggs",
"satiationAmount" : 5,
"staminaAmount" : 1,
"healAmount" : 5,
"cost" : 15,
"@type" : "Consumable",
"weight" : 0.025,
"category" : {"Food":2}
},
"200" : {
"@type" : "Item",
"name" : "Wrench",
"cost" : 20,
"weight" : 0.75
},
"201" : {
"@type" : "Item",
"name" : "Cloth",
"cost" : 3,
"weight" : 0.03
},
"202" : {
"@type" : "Item",
"name" : "Tattered Cloth",
"cost" : 1,
"weight" : 0.001
}
}
7 changes: 5 additions & 2 deletions core/assets/scripts/structure/plain-camp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@ local map = world:getCurLoc();
structure:clear();
map:fillTile(structure.x, structure.y, structure.width, structure.height, 23); -- Fill & erode camp tiles
map:erodeTileRectangle(structure.x, structure.y, structure.width, structure.height, 1, 0);
map:spawnNpc(5, structure.x + 5, structure.y + 5); -- Spawn tutorial quest branch NPC
map:addObject(structure.x + 5, structure.y + 4, 6); -- Add campfire
map:addObject(structure.x + 5, structure.y + 4, 6); -- Add campfire

local nx, ny = structure.x + 5, structure.y + 5;
map:spawnNpc(5, nx, ny); -- Spawn tutorial questline NPC
map:addWaypoint(nx, ny):setDestinationName("Stranger");

return true;
26 changes: 13 additions & 13 deletions core/assets/tutorial.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,25 @@
"GameStart" : "
%Tutorial%
Welcome to MadSand, {PLAYER}![What? How do you know my name?]=>
This game *someday will be* an open-world survival sandbox RPG.{br}
It's in the early stage of development, so feel free to explore and provide feedback and suggestions
about what you see in the game or what you want to see in the future.[Mkaaay...]=>
This game *someday will be* an open-world survival sandbox RPG.
{p}It's in the early stage of development, so feel free to explore and provide feedback and suggestions
about what you see in the game or what you want to see in the future.[Mkaaay...]=>
If I were you, I'd start by exploring and interacting with things. [Oh, ok]=>
To interact with an Object or NPC, approach it and click on it with LMB or click on it with RMB and choose the \"interact\" option, or,
for keyboard lovers - turn your character to it using arrow keys and press enter. [Understood]=>
for keyboard lovers - turn your character to it using arrow keys and press enter. [Understood]=>
Via interaction with objects you can gather resources that can be crafted into something or sold to a trader.
You'll have to gather all the needed components for a certain item to unlock a craft recipe for it.[Cool, I'll try it out]=>
You'll have to gather all the needed components for a certain item to unlock a craft recipe for it.[Cool, I'll try it out]=>
And if you decide to interact with an NPC, you can talk to them by left clicking. Some NPCs can give you various tasks and some can trade with you.=>
And almost forgot, here are the controls:[Show 'em to me!]=>
#Controls#
* WASD or LMB click - walk around{br}
* Middle mouse button or Arrow keys - turn around without moving{br}
* LMB click or Enter - interact with an object/NPC{br}
* LMB click - attack a hostile creature{br}
* Arrows or \"Attack\" option in RMB menu - attack a neutral creature (be careful, they'll become hostile and will fight back){br}
* LMB click on yourself or Space - rest for a turn{br}
* U or LMB click on the \"Hand\" equip slot - use currently held placeable block or placeable tile (or a special tool, for example, hoe){br}
* G or \"Save game\" button in ESC menu - save current world{br}
* WASD or LMB click - walk around{br}
* Middle mouse button or Arrow keys - turn around without moving{br}
* LMB click or Enter - interact with an object/NPC{br}
* LMB click - attack a hostile creature{br}
* Arrows or \"Attack\" option in RMB menu - attack a neutral creature (be careful, they'll become hostile and will fight back){br}
* LMB click on yourself or Space - rest for a turn{br}
* U or LMB click on the \"Hand\" equip slot - use currently held placeable block or placeable tile (or a special tool, for example, hoe){br}
* G or \"Save game\" button in ESC menu - save current world{br}
[Woah, thanks!]
",

Expand Down
2 changes: 1 addition & 1 deletion core/src/hitonoriol/madsand/dialog/TextSubstitutor.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public class TextSubstitutor {
static {
add(LINEBREAK, Resources.LINEBREAK);
add(TAB, Resources.Tab);
add("PAR", Resources.LINEBREAK + Resources.Tab);
add("p", Resources.LINEBREAK + Resources.LINEBREAK);
add("PLAYER", () -> MadSand.player().getName());
add(RAND_NAME, () -> JRand.firstname().gen());
add(RAND_NAME_M, () -> JRand.firstname().gender(Gender.MALE).gen());
Expand Down

0 comments on commit f2d5e57

Please sign in to comment.