From f9c887d629b76a8c28ca807fc6fe3a7dadfc3071 Mon Sep 17 00:00:00 2001 From: Daniel Date: Mon, 4 Dec 2023 20:21:32 -0500 Subject: [PATCH 1/3] added docs --- docs/.obsidian/app.json | 1 + docs/.obsidian/appearance.json | 3 + docs/.obsidian/core-plugins-migration.json | 30 ++++ docs/.obsidian/core-plugins.json | 20 +++ docs/.obsidian/hotkeys.json | 1 + docs/.obsidian/workspace.json | 162 +++++++++++++++++++++ docs/Level 1.md | 5 + 7 files changed, 222 insertions(+) create mode 100644 docs/.obsidian/app.json create mode 100644 docs/.obsidian/appearance.json create mode 100644 docs/.obsidian/core-plugins-migration.json create mode 100644 docs/.obsidian/core-plugins.json create mode 100644 docs/.obsidian/hotkeys.json create mode 100644 docs/.obsidian/workspace.json create mode 100644 docs/Level 1.md diff --git a/docs/.obsidian/app.json b/docs/.obsidian/app.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/docs/.obsidian/app.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/docs/.obsidian/appearance.json b/docs/.obsidian/appearance.json new file mode 100644 index 0000000..c8c365d --- /dev/null +++ b/docs/.obsidian/appearance.json @@ -0,0 +1,3 @@ +{ + "accentColor": "" +} \ No newline at end of file diff --git a/docs/.obsidian/core-plugins-migration.json b/docs/.obsidian/core-plugins-migration.json new file mode 100644 index 0000000..436f43c --- /dev/null +++ b/docs/.obsidian/core-plugins-migration.json @@ -0,0 +1,30 @@ +{ + "file-explorer": true, + "global-search": true, + "switcher": true, + "graph": true, + "backlink": true, + "canvas": true, + "outgoing-link": true, + "tag-pane": true, + "properties": false, + "page-preview": true, + "daily-notes": true, + "templates": true, + "note-composer": true, + "command-palette": true, + "slash-command": false, + "editor-status": true, + "bookmarks": true, + "markdown-importer": false, + "zk-prefixer": false, + "random-note": false, + "outline": true, + "word-count": true, + "slides": false, + "audio-recorder": false, + "workspaces": false, + "file-recovery": true, + "publish": false, + "sync": false +} \ No newline at end of file diff --git a/docs/.obsidian/core-plugins.json b/docs/.obsidian/core-plugins.json new file mode 100644 index 0000000..9405bfd --- /dev/null +++ b/docs/.obsidian/core-plugins.json @@ -0,0 +1,20 @@ +[ + "file-explorer", + "global-search", + "switcher", + "graph", + "backlink", + "canvas", + "outgoing-link", + "tag-pane", + "page-preview", + "daily-notes", + "templates", + "note-composer", + "command-palette", + "editor-status", + "bookmarks", + "outline", + "word-count", + "file-recovery" +] \ No newline at end of file diff --git a/docs/.obsidian/hotkeys.json b/docs/.obsidian/hotkeys.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/docs/.obsidian/hotkeys.json @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/docs/.obsidian/workspace.json b/docs/.obsidian/workspace.json new file mode 100644 index 0000000..c683f17 --- /dev/null +++ b/docs/.obsidian/workspace.json @@ -0,0 +1,162 @@ +{ + "main": { + "id": "c3b677b484e906ad", + "type": "split", + "children": [ + { + "id": "fc48818b65cbf4b1", + "type": "tabs", + "children": [ + { + "id": "5093580e43452847", + "type": "leaf", + "state": { + "type": "empty", + "state": {} + } + }, + { + "id": "fce50c575c89a4b5", + "type": "leaf", + "state": { + "type": "markdown", + "state": { + "file": "Level 1.md", + "mode": "source", + "source": false + } + } + } + ], + "currentTab": 1 + } + ], + "direction": "vertical" + }, + "left": { + "id": "111700e2d75b975d", + "type": "split", + "children": [ + { + "id": "a3085c0b85030b6f", + "type": "tabs", + "children": [ + { + "id": "b18342ed8266f48d", + "type": "leaf", + "state": { + "type": "file-explorer", + "state": { + "sortOrder": "alphabetical" + } + } + }, + { + "id": "276c6f0e87ce1b64", + "type": "leaf", + "state": { + "type": "search", + "state": { + "query": "", + "matchingCase": false, + "explainSearch": false, + "collapseAll": false, + "extraContext": false, + "sortOrder": "alphabetical" + } + } + }, + { + "id": "b451d453747a6ae6", + "type": "leaf", + "state": { + "type": "bookmarks", + "state": {} + } + } + ] + } + ], + "direction": "horizontal", + "width": 300 + }, + "right": { + "id": "49f6c1aa8bf5c5e1", + "type": "split", + "children": [ + { + "id": "f8b97180adc28552", + "type": "tabs", + "children": [ + { + "id": "62bc200aa6769bb4", + "type": "leaf", + "state": { + "type": "backlink", + "state": { + "file": "Level 1.md", + "collapseAll": false, + "extraContext": false, + "sortOrder": "alphabetical", + "showSearch": false, + "searchQuery": "", + "backlinkCollapsed": false, + "unlinkedCollapsed": true + } + } + }, + { + "id": "98a550bcc8f7b176", + "type": "leaf", + "state": { + "type": "outgoing-link", + "state": { + "file": "Level 1.md", + "linksCollapsed": false, + "unlinkedCollapsed": true + } + } + }, + { + "id": "8c1256f4be0cc8cf", + "type": "leaf", + "state": { + "type": "tag", + "state": { + "sortOrder": "frequency", + "useHierarchy": true + } + } + }, + { + "id": "3caebc2ca88144af", + "type": "leaf", + "state": { + "type": "outline", + "state": { + "file": "Level 1.md" + } + } + } + ] + } + ], + "direction": "horizontal", + "width": 300, + "collapsed": true + }, + "left-ribbon": { + "hiddenItems": { + "switcher:Open quick switcher": false, + "graph:Open graph view": false, + "canvas:Create new canvas": false, + "daily-notes:Open today's daily note": false, + "templates:Insert template": false, + "command-palette:Open command palette": false + } + }, + "active": "fce50c575c89a4b5", + "lastOpenFiles": [ + "Level 1.md" + ] +} \ No newline at end of file diff --git a/docs/Level 1.md b/docs/Level 1.md new file mode 100644 index 0000000..1da1ab9 --- /dev/null +++ b/docs/Level 1.md @@ -0,0 +1,5 @@ +The bees are hungry and need to fuel their way back home + + + +Objective: Harvest enough flowers to fill the colony's energy level. Once the energy level surpasses the hive energy requirement threshold, welcome home bees. \ No newline at end of file From 097d4a12bf378740e0224e0474bcb635bbc1409c Mon Sep 17 00:00:00 2001 From: Daniel Date: Mon, 4 Dec 2023 20:24:40 -0500 Subject: [PATCH 2/3] fix: objective --- docs/Level 1.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Level 1.md b/docs/Level 1.md index 1da1ab9..cc951a0 100644 --- a/docs/Level 1.md +++ b/docs/Level 1.md @@ -2,4 +2,4 @@ The bees are hungry and need to fuel their way back home -Objective: Harvest enough flowers to fill the colony's energy level. Once the energy level surpasses the hive energy requirement threshold, welcome home bees. \ No newline at end of file +Objective: Get enough pollen to be able to lift the flag out of the literal ground as bees and bring it back to the hive. \ No newline at end of file From ecf3903aeaad9e6a5e3130e259d6db6bfc949624 Mon Sep 17 00:00:00 2001 From: Carson Webster Date: Tue, 5 Dec 2023 11:08:20 -0800 Subject: [PATCH 3/3] A todo list and gameplay ideas file --- docs/.obsidian/workspace.json | 29 +++++++++++------------------ docs/Gameplay.md | 29 +++++++++++++++++++++++++++++ docs/Todos.md | 30 ++++++++++++++++++++++++++++++ 3 files changed, 70 insertions(+), 18 deletions(-) create mode 100644 docs/Gameplay.md create mode 100644 docs/Todos.md diff --git a/docs/.obsidian/workspace.json b/docs/.obsidian/workspace.json index c683f17..741c68f 100644 --- a/docs/.obsidian/workspace.json +++ b/docs/.obsidian/workspace.json @@ -4,31 +4,22 @@ "type": "split", "children": [ { - "id": "fc48818b65cbf4b1", + "id": "260f01404e0fb104", "type": "tabs", "children": [ { - "id": "5093580e43452847", - "type": "leaf", - "state": { - "type": "empty", - "state": {} - } - }, - { - "id": "fce50c575c89a4b5", + "id": "09a660b2d2a74b3d", "type": "leaf", "state": { "type": "markdown", "state": { - "file": "Level 1.md", + "file": "Todos.md", "mode": "source", "source": false } } } - ], - "currentTab": 1 + ] } ], "direction": "vertical" @@ -94,7 +85,7 @@ "state": { "type": "backlink", "state": { - "file": "Level 1.md", + "file": "Todos.md", "collapseAll": false, "extraContext": false, "sortOrder": "alphabetical", @@ -111,7 +102,7 @@ "state": { "type": "outgoing-link", "state": { - "file": "Level 1.md", + "file": "Todos.md", "linksCollapsed": false, "unlinkedCollapsed": true } @@ -134,7 +125,7 @@ "state": { "type": "outline", "state": { - "file": "Level 1.md" + "file": "Todos.md" } } } @@ -155,8 +146,10 @@ "command-palette:Open command palette": false } }, - "active": "fce50c575c89a4b5", + "active": "09a660b2d2a74b3d", "lastOpenFiles": [ - "Level 1.md" + "Gameplay.md", + "Level 1.md", + "Todos.md" ] } \ No newline at end of file diff --git a/docs/Gameplay.md b/docs/Gameplay.md new file mode 100644 index 0000000..21dea6d --- /dev/null +++ b/docs/Gameplay.md @@ -0,0 +1,29 @@ + +# Objective +- Discover more of the map around you, covered by fog of war + - Bees must **explore** into the fog for those tiles to become visible and targeted in the future +- Interact with entities / points of interest in discovered view + - Some useful like *Flowers* whose pollen will help spawn more bees + - Some harmful which may kill bees + - Some act as objectives, which must be brought back to base to advance +- Balance between having some bees explore the map, interacting with entities, and and protecting the home hive from other threats? + +# Player Actions +- Highlight in a region bee to control + - Left / Right click and drag spawns a highlight box +- Selected bees can then preform bee specific actions + - Click on ground = move towards that world coordinate + - Click on level entity = group up at and interact with entity + - Click on wonder button = bees slowly disperse in local area + - Click on **explore** button = bees more aggressively + +# Bee Behavior + +```rust +enum BeeBehaviorState { + Traveling (Move twoards players location), + Wondering (Stay put in radius around self), + Exploring (Prioritize fog of war), + Amalgamate (Waiting for other bees to interact with an entity) +} +``` \ No newline at end of file diff --git a/docs/Todos.md b/docs/Todos.md new file mode 100644 index 0000000..3619543 --- /dev/null +++ b/docs/Todos.md @@ -0,0 +1,30 @@ +## Debug boids +- [ ] Spawn a debug boid after loading level. It should have a different texture and still considered a bee +- [ ] Show it's sight radius around it with a 2D shape +```rust +// Circle + commands.spawn(MaterialMesh2dBundle { + mesh: meshes.add(shape::Circle::new(50.).into()).into(), + material: materials.add(ColorMaterial::from(Color::PURPLE)), + transform: Transform::from_translation(Vec3::new(-150., 0., 0.)), + ..default() + }); +``` +- [ ] Verify that it's sight is only in a cone in front of the boid + - `Dot product(ourDirection, otherBoidDirection) > visionConeThreshold` + +- [ ] Verify separation works as intended. This may fix our stacking problem + - All boids in range exert an opposing direction, intensity that decreases with the distance of the two + +- [ ] How hard would it be to display the edges of our QuadTree as part of a toggable debug ui? + +## Boid gameplay +- [ ] Each boid should have a destination position that it tries to navigate towards, if in traveling state, instead of just forwards + +- [ ] Introduce collision avoidance for walls and fog of war if not exploring + - Fetch overlapping colliders in a radius and just like the separation rule, colliders exert an opposed direction + +- [ ] Steering / Fog of war rule + - Each tile has a discovered boolean, determining if it is in fog or not + - If an exploring bee touches an undiscovered tile, it toggles preeminently to discovered + - Add a separation rule just like for collisions, but attracted to undiscovered tiles \ No newline at end of file