rm-code / on-the-roadside Goto Github PK
View Code? Open in Web Editor NEWA turn-based ASCII strategy game.
Home Page: https://rmcode.itch.io/on-the-roadside
License: MIT License
A turn-based ASCII strategy game.
Home Page: https://rmcode.itch.io/on-the-roadside
License: MIT License
The player should be able to toggle the fullscreen mode on and off.
Grenades should follow somewhat realistic flying trajectories. When a grenade hits a world object it should be deflected correctly. It would also be nice to have some kind of bouncing / rolling behavior close to the target.
The (green) neutral faction is aggressive both towards the player's and the AI's faction. Neutral characters should only attack after they have been attacked.
OTR will include explosive weapons at some point in the future (rocket launchers, grenades and so on). The current system only handles projectile weapons and therefore needs to be extended.
An easy way to implement explosions for now would be to take all tiles in the radius of the explosion and hit them a certain amount of damage. This would however ignore walls and other objects which could block the blast.
Instead all tiles inside of the radius should be checked by shooting rays at them and only those which are reached by the ray will be hit by the explosion.
Some pseudo code I thought about today:
Hide it when switching back to the game screen.
The camera should stay focused on the character that just moved instead of going back to the original position.
Currently shots are quite accurate. It looks like there are some flaws in the current angle calculations which need to be addressed.
One of the most annoying parts of the inventory is that the player has to equip backpacks if he wants to look into them. It would be nicer if you could click on a backpack and it would open a new list (replacing the "current" item list).
By implementing this we could also get rid of the backpack list completely.
Currently, inventory containers have no restrictions on how many items they can contain.
I think the list-view is the right way to do the inventory for OTR (especially since I am not a fan of inventory tetris). A system like in Project Zomboid could work where items have a number which represents both weight and bulkiness of an item.
The goal for now should be to fully restore the battlescape. It'll be the first time for me to save any complex game state and therefore might prove quite challenging.
The game should only be saved in the planning state. This saves us the trouble of storing information about any explosions or projectiles or other simulations / actions that are going on.
Currently the camera can be moved offscreen by scrolling. It's not a big issue since it jumps back as soon as a new character is selected.
The mouse scrolling should be deactivated if the mouse cursor is no longer inside of the game's window.
The inventory windows need to be scrollable.
Error: src/SaveHandler.lua:100: attempt to index local 'item' (a nil value)
stack traceback:
src/SaveHandler.lua:100: in function 'createMagazine'
src/SaveHandler.lua:112: in function 'createWeapon'
src/SaveHandler.lua:122: in function 'fillInventory'
src/SaveHandler.lua:193: in function 'loadCharacters'
src/Game.lua:49: in function 'init'
src/screens/MainScreen.lua:40: in function 'init'
lib/screenmanager/ScreenManager.lua:110: in function 'push'
lib/screenmanager/ScreenManager.lua:68: in function 'init'
main.lua:35: in function 'load'
[string "boot.lua"]:439: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
When loading a savegame the state of all doors is reset to closed.
Once #44 is implemented inventory space can be limited by setting a maximum weight value for containers.
The game should communicate the costs of an action before the player takes it.
The camera doesn't start centered on a character when the game starts. This forces the player to either search for the character by hand or select the next or previous character to force camera movement.
Win: Kill all enemy characters
Lose: Lose all your characters
When a rocket hits an indestructible world object it just vanishes.
Error: src/items/weapons/ProjectileManager.lua:32: attempt to index local 'tile' (a nil value)
stack traceback:
src/items/weapons/ProjectileManager.lua:32: in function 'hitTile'
src/items/weapons/ProjectileManager.lua:84: in function 'update'
src/turnbased/states/ExecutionState.lua:26: in function 'update'
src/turnbased/states/StateManager.lua:13: in function 'update'
src/turnbased/TurnManager.lua:32: in function 'update'
src/Game.lua:77: in function 'update'
src/screens/MainScreen.lua:67: in function 'update'
lib/screenmanager/ScreenManager.lua:380: in function 'update'
main.lua:57: in function 'update'
[string "boot.lua"]:463: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
When a character kills himself (or generally is killed while being active) it is possible to move him to a different tile and basically resurrect him.
This wasn't an issue before because with guns only other characters could be killed, but not the one currently set as active by the game.
This is a bit tricky since dead characters currently aren't really removed from the Faction.
Error: src/characters/actions/Reload.lua:10: attempt to call method 'getMagazine' (a nil value)
stack traceback:
src/characters/actions/Reload.lua:10: in function 'perform'
src/characters/Character.lua:127: in function 'performAction'
src/turnbased/states/ExecutionState.lua:37: in function 'update'
src/turnbased/states/StateManager.lua:13: in function 'update'
src/turnbased/TurnManager.lua:32: in function 'update'
src/Game.lua:77: in function 'update'
src/screens/MainScreen.lua:67: in function 'update'
lib/screenmanager/ScreenManager.lua:380: in function 'update'
main.lua:57: in function 'update'
[string "boot.lua"]:463: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
The camera should only track movement of AI controlled characters if they are visible to one of the player's characters.
The game should continue to display the FOV for the player's faction.
This needs to be easy to control so we can disable it for easier AI debugging and development.
Currently the line of fire for a character creates red overlays for tiles outside of the field of view of the selected character:
Colors should be chosen like this:
The AI for 0.2.0 doesn't need to be smart, but shouldn't block the game (e.g. by trying to reload a weapon without having ammo in the inventory).
Draft:
Error: src/screens/InventoryScreen.lua:44: attempt to index a boolean value
stack traceback:
src/screens/InventoryScreen.lua:44: in function 'init'
lib/screenmanager/ScreenManager.lua:110: in function 'push'
src/screens/MainScreen.lua:75: in function 'keypressed'
lib/screenmanager/ScreenManager.lua:197: in function 'keypressed'
main.lua:71: in function <main.lua:70>
[string "boot.lua"]:454: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
There seems to be an issue where input is blocked after a world object has been hit. It's possible that the game is staying in the Execution state because it waits for the ProjectileManager to finish.
Looks like this happens when a projectile is passing through multiple world objects at once.
Error: src/characters/actions/Walk.lua:28: Character has to be adjacent to the target tile!
stack traceback:
[C]: in function 'assert'
src/characters/actions/Walk.lua:28: in function 'perform'
src/characters/Character.lua:112: in function 'performAction'
src/turnbased/states/ExecutionState.lua:23: in function 'update'
src/turnbased/states/StateManager.lua:13: in function 'update'
src/turnbased/TurnManager.lua:33: in function 'update'
src/Game.lua:83: in function 'update'
src/screens/MainScreen.lua:65: in function 'update'
lib/screenmanager/ScreenManager.lua:380: in function 'update'
main.lua:57: in function 'update'
[string "boot.lua"]:463: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
Spawn areas can primarily used to spawn the player's chars at a certain point of the map. They could easily be used to control the placement of NPCs as well though.
hello, i've been looking over this game and it seems really interesting, however the code is very confusing
could you please explain what tile.lua, tilefactory.lua and worldpainter.lua do?
A big part of the game is about scavenging for new items and weapons on the maps. For this purpose, some of the objects on the map should have container space (e.g. desks, closets, crates, etc.).
We simply need to check if the weapon is empty.
This will especially useful for ammo and other "small" items.
Fixing this should also fix #7.
Rocket and Grenade launchers are different from the current projectile weapons as they explode on impact.
The ProjectileManager could determine the type of damage a projectile does based on the ammunition type. If it encounters something like ammoType == "Explosive"
it will look for the blast strength of the attack and spawn a new explosion.
In games like Silent Storm and XCOM characters can interrupt the the turns of enemy characters when they have action points left and certain actions are triggered.
In interruption turns characters should be able to perform all actions they could usually perform in a normal turn.
Error: src/items/weapons/ProjectileManager.lua:89: attempt to call method 'getMagazine' (a nil value)
stack traceback:
src/items/weapons/ProjectileManager.lua:89: in function 'update'
src/turnbased/states/ExecutionState.lua:26: in function 'update'
src/turnbased/states/StateManager.lua:13: in function 'update'
src/turnbased/TurnManager.lua:32: in function 'update'
src/Game.lua:77: in function 'update'
src/screens/MainScreen.lua:67: in function 'update'
lib/screenmanager/ScreenManager.lua:380: in function 'update'
main.lua:57: in function 'update'
[string "boot.lua"]:463: in function <[string "boot.lua"]:435>
[C]: in function 'xpcall'
Currently there is no way to distinguish between the UI overlay for attacks and movement. It probably would be enough for now to simply change the cursor to indicate a different mode.
Melee attacks could work nice in stealth gameplay later on, but we also need them to simulate monster attacks. This could work as "equipping" monsters with "claw" items for example.
Happens because the explosion isn't created if the tile is hit due to loss of the projectile's energy.
The mouse pointer is visible for a short moment when the AI switches between planning and execution states.
Currently behavior trees are hardcoded. It would make sense to have some kind of simple visual editor or at least allow the creation of BTs via script files.
Shotguns should be quite easy to implement with the current System. Low accuracy and no delay between projectiles.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.