Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev #99

Merged
merged 31 commits into from
Feb 21, 2021
Merged

Dev #99

merged 31 commits into from
Feb 21, 2021

Conversation

wylyandrews
Copy link
Member

No description provided.

Anomalous-Creator and others added 30 commits February 20, 2021 12:52
* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Linked truck\'s node to map

* Added missing import

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* node json and typo fix

* fixed typo

* fixed duplicate from merge

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* percentage change

* organization and longer roads

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Removed old comment

* Map location changes

* road json changes

* illegal contracts initial commit

* illegal contracts initial

* illegal contract logs

* Fixed typo

* Map json size reduction

* fixed build.sh

* Map json fix and contract state

* Revert to old contract/map location

* base client, upgrade cost method, documentation, pass contract

* docs changes and fixes

* Minor changes to base client

* rebuilt docs

* add missing, rebuild

* Built sphinx

Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>
* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* Create 2020-10-27-byte-le-minutes.md

* EventHandler Logic

Method to randomly chose and execute an event.

* Working game!

* Removed print statement!

* Moved event_handler

Moved into controllers and renamed to event_controller

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Add files via upload

* Linked truck\'s node to map

* Added missing import

* Began work on upgrade controller

* Add files via upload

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* Progress update, stuff is actually getting done folks I'm not lying this time haha

* Add files via upload

* Update 2020-11-17-byte-le-minutes.md

* More upgrades and their tests! TODO add logic for only having one of each upgrade class

* Began work on changing upgrade logic to only allow for one upgrade of each type

* nearly to the pr state

* Add files via upload

* I'm a lazy bum for not having done any of this sooner. Happy Thanksgiving

* A bit late for Thanksgiving but I think I've got something here. Seems to work alright

* Add files via upload

* Completed the framework for upgrading objects.

* Added some comments.

* Finished body upgrade controller, objects and tests. Need to align tests so they are more similar

* Finished upgrade logic, changed classes so they all inherit baseUpgradeObject

* here this should run I think

* Add files via upload

* made tests similar to eachother, all passing

* here you go soph

* Fixed spelling mistakes

* Removed logic that only allowed you to buy gas at cities

* Fixes. Added inheritence for body objects so they all have gas levels. I think it works

* placeholder contract generation reimplemented, json modified

* Add files via upload

* fixes and region modifiers

* Added truck to/from json, logic to prevent contract selection being out of bounds

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* Began work on implementing how upgrades impact event damage and chance. Still thinking about the best way to do this

* Fixed node not calling to_json method in truck

* began changes to gamestats, event controller

* Fixed some json

* node json and typo fix

* fixed typo

* Finished changing the logic for events, will start creating tests for them

* fixed duplicate from merge

* basic json output

* Current node assignment fixes, typo

* 2021-01-05 minutes

* missing self in event_controller

* missing import

* quick fix

* more progress on the event controller tests, fixes

* percentage change

* organization and longer roads

* More progress on creating tests

* Merged Dev

* Finished event testing. Was unable to unit test move because it's too bulky/dependant to unit test

* Removed uneccesary assignement of event controller hapenning twice, commented out auto time reduction

* Add files via upload

* Add files via upload

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Add files via upload

* Began looking into broken upgrade controller

* Before pull dev

* Reverted changes to payment

* Fixes to health and gas actions so they work as intended

* Uncommented game map in contract for now

* Create CNAME

* Delete CNAME

* Add files via upload

* Add files via upload

* Added maximum speed gamestat. Also Fixed bad reference in heal controller. Added speed unit test

* Began work on documentation

* Began work on documentation

* Fix partial gas buy

* Fixed client, __speed variable was unnecessary

* Changes is not to !=

* Removed move unit tests

* Set upgrades to base objects. minor changes to base client

* Updated docs a bit

* Every turn now takes one tick of time. Pumping gas, repairing and upgrading also now take time with this time listed in gamestats. Updated docs but more work to do

* Fixed some formatting stuff

* More formatting junk

* Fixed mpg to be based on speed 'again'

* Added final score

* Dev to master (#54)

* Create select_route.py

* Moved changes to action

* Revert "Merge remote-tracking branch 'origin/dev' into quinn"

This reverts commit 97aae8d, reversing
changes made to b8034a6.

* Revert "Revert "Merge remote-tracking branch 'origin/dev' into quinn""

This reverts commit 5e4075f.

* Properly merged with Chris's changes

* Added destination to json in action

* Made movement controller

* Removed pip files

* Fixed stupid fix

* Reworked moevment logic

Reworked movement controller for new map
Added speed to truck object
Added distance to truck object
Added length to road object
Renamed destination to route

* Added new variables to jsons

* Made movement time based

* Removed speed from parameter

* Simple changes

* Added default road length to GameStats

* Sean (#32)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>

* Reworked controllers to ActionController

All methods are currently in ActionController. No controllers have been deleted yet.

* Various bug fixes

Oh boy it's a swarm of bugs out here. Run for your lives!

* deleted print statement

Accidentally left a print statement in engine.py

* Reworked controllers to ActionController. Lots of bug fixes (#34)

* Reworked controllers to ActionController

All methods are currently in ActionController. No controllers have been deleted yet.

* Various bug fixes

Oh boy it's a swarm of bugs out here. Run for your lives!

* deleted print statement

Accidentally left a print statement in engine.py

* Sean (#35)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Working game!

* Removed print statement!

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>

* Deleted ActionType change_speed

change_speed is already a function in Truck and doesn't need to be an action_type since it's just changing a value on the truck. Therefore, it's not necessary and is deleted from the ActionType enum and from the Action_Controller

* current_speed ActionType deleted (#38)

* Reworked controllers to ActionController

All methods are currently in ActionController. No controllers have been deleted yet.

* Various bug fixes

Oh boy it's a swarm of bugs out here. Run for your lives!

* deleted print statement

Accidentally left a print statement in engine.py

* Deleted ActionType change_speed

change_speed is already a function in Truck and doesn't need to be an action_type since it's just changing a value on the truck. Therefore, it's not necessary and is deleted from the ActionType enum and from the Action_Controller

* ActionType choose_speed (again)

My previous PR said this wasn't needed since the Truck had the set_current_speed method. However, this will not work because the user client is given a copy of the truck and cannot directly change its values.

* ActionType choose_speed (again) (#39)

* Reworked controllers to ActionController

All methods are currently in ActionController. No controllers have been deleted yet.

* Various bug fixes

Oh boy it's a swarm of bugs out here. Run for your lives!

* deleted print statement

Accidentally left a print statement in engine.py

* Deleted ActionType change_speed

change_speed is already a function in Truck and doesn't need to be an action_type since it's just changing a value on the truck. Therefore, it's not necessary and is deleted from the ActionType enum and from the Action_Controller

* ActionType choose_speed (again)

My previous PR said this wasn't needed since the Truck had the set_current_speed method. However, this will not work because the user client is given a copy of the truck and cannot directly change its values.

* Events (#36)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Moved event weights to GameStats

* Truck upgrades now prevent certain events

Adjusted stats implementations of weighting for roads
Truck now contains bonuses for each events.

* event_chance method

Added method to call to determine if event is happening
Added required index for random choices

* Moved adjusted event weights to event controller

* Added comments for event weights

* Update master_controller.py

Co-authored-by: Christopher Parks <[email protected]>

* Map creation (#40)

* Progress update, stuff is actually getting done folks I'm not lying this time haha

* nearly to the pr state

* I'm a lazy bum for not having done any of this sooner. Happy Thanksgiving

* A bit late for Thanksgiving but I think I've got something here. Seems to work alright

* here this should run I think

* here you go soph

* Action controller fix (#42)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Moved event weights to GameStats

* Truck upgrades now prevent certain events

Adjusted stats implementations of weighting for roads
Truck now contains bonuses for each events.

* event_chance method

Added method to call to determine if event is happening
Added required index for random choices

* Moved adjusted event weights to event controller

* Added comments for event weights

* Update master_controller.py

* Updated move action for new map

* Event trigger added to movement

* Added gas usage to move

Co-authored-by: Christopher Parks <[email protected]>

* fixing the broken lego blocks

there's so much going on here and I gotta switch branches so yeet

* Sean (#41)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Working game!

* Removed print statement!

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

* Began work on upgrade controller

* More upgrades and their tests! TODO add logic for only having one of each upgrade class

* Began work on changing upgrade logic to only allow for one upgrade of each type

* Completed the framework for upgrading objects.

* Added some comments.

* Finished body upgrade controller, objects and tests. Need to align tests so they are more similar

* Finished upgrade logic, changed classes so they all inherit baseUpgradeObject

* made tests similar to eachother, all passing

* Fixed spelling mistakes

* Removed logic that only allowed you to buy gas at cities

* Fixes. Added inheritence for body objects so they all have gas levels. I think it works

* Added truck to/from json, logic to prevent contract selection being out of bounds

* Fixed node not calling to_json method in truck

* Fixed some json

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>

* Contracts, map json, player changes (#43)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Linked truck\'s node to map

* Added missing import

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* node json and typo fix

* fixed typo

* fixed duplicate from merge

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* percentage change

* organization and longer roads

Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>

* Push for Sean and Chris's next changes

* Contract selection fixes

* Sean (#44)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Create 2020-10-27-byte-le-minutes.md

* Working game!

* Removed print statement!

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

* Add files via upload

* Began work on upgrade controller

* Add files via upload

* Add files via upload

* Update 2020-11-17-byte-le-minutes.md

* More upgrades and their tests! TODO add logic for only having one of each upgrade class

* Began work on changing upgrade logic to only allow for one upgrade of each type

* Add files via upload

* Add files via upload

* Completed the framework for upgrading objects.

* Added some comments.

* Finished body upgrade controller, objects and tests. Need to align tests so they are more similar

* Finished upgrade logic, changed classes so they all inherit baseUpgradeObject

* Add files via upload

* made tests similar to eachother, all passing

* Fixed spelling mistakes

* Removed logic that only allowed you to buy gas at cities

* Fixes. Added inheritence for body objects so they all have gas levels. I think it works

* Added truck to/from json, logic to prevent contract selection being out of bounds

* Began work on implementing how upgrades impact event damage and chance. Still thinking about the best way to do this

* Fixed node not calling to_json method in truck

* began changes to gamestats, event controller

* Fixed some json

* Finished changing the logic for events, will start creating tests for them

* basic json output

* more progress on the event controller tests, fixes

* More progress on creating tests

* Merged Dev

* Finished event testing. Was unable to unit test move because it's too bulky/dependant to unit test

* Removed uneccesary assignement of event controller hapenning twice, commented out auto time reduction

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>

* Quick move fixes.

Need to get new dev changes

* Final fixes

* Better town names (#46)

* Created better town names

* Deleted outdated city name test

* Contract renown and deadline, truck from json, money moved to truck (#47)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Linked truck\'s node to map

* Added missing import

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* node json and typo fix

* fixed typo

* fixed duplicate from merge

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* percentage change

* organization and longer roads

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Removed old comment

Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>

* Damage balance changes (#48)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Moved event weights to GameStats

* Truck upgrades now prevent certain events

Adjusted stats implementations of weighting for roads
Truck now contains bonuses for each events.

* event_chance method

Added method to call to determine if event is happening
Added required index for random choices

* Moved adjusted event weights to event controller

* Added comments for event weights

* Update master_controller.py

* Updated move action for new map

* Event trigger added to movement

* Added gas usage to move

* Changed damage and time values to be based on how often events happen

* Removed unnecessary event type bonuses

Co-authored-by: Christopher Parks <[email protected]>

* Sphinx docs (#50)

* Created better town names

* Deleted outdated city name test

* Sphinx

* oopsie

* Update conf.py

Updated conf py

Co-authored-by: Sean Hagen <[email protected]>

* Upgrade implementation and fix (#49)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* Create 2020-10-27-byte-le-minutes.md

* EventHandler Logic

Method to randomly chose and execute an event.

* Working game!

* Removed print statement!

* Moved event_handler

Moved into controllers and renamed to event_controller

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Add files via upload

* Linked truck\'s node to map

* Added missing import

* Began work on upgrade controller

* Add files via upload

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* Add files via upload

* Update 2020-11-17-byte-le-minutes.md

* More upgrades and their tests! TODO add logic for only having one of each upgrade class

* Began work on changing upgrade logic to only allow for one upgrade of each type

* Add files via upload

* Add files via upload

* Completed the framework for upgrading objects.

* Added some comments.

* Finished body upgrade controller, objects and tests. Need to align tests so they are more similar

* Finished upgrade logic, changed classes so they all inherit baseUpgradeObject

* Add files via upload

* made tests similar to eachother, all passing

* Fixed spelling mistakes

* Removed logic that only allowed you to buy gas at cities

* Fixes. Added inheritence for body objects so they all have gas levels. I think it works

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* Added truck to/from json, logic to prevent contract selection being out of bounds

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* Began work on implementing how upgrades impact event damage and chance. Still thinking about the best way to do this

* Fixed node not calling to_json method in truck

* began changes to gamestats, event controller

* Fixed some json

* node json and typo fix

* fixed typo

* Finished changing the logic for events, will start creating tests for them

* fixed duplicate from merge

* basic json output

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* more progress on the event controller tests, fixes

* percentage change

* organization and longer roads

* More progress on creating tests

* Merged Dev

* Finished event testing. Was unable to unit test move because it's too bulky/dependant to unit test

* Removed uneccesary assignement of event controller hapenning twice, commented out auto time reduction

* Created better town names

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Began looking into broken upgrade controller

* Before pull dev

* Reverted changes to payment

* Fixes to health and gas actions so they work as intended

* Uncommented game map in contract for now

* Added maximum speed gamestat. Also Fixed bad reference in heal controller. Added speed unit test

* Fix partial gas buy

* Fixed client, __speed variable was unnecessary

* Changes is not to !=

* Removed move unit tests

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>
Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>

* Upgrades balance pass (#51)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Moved event weights to GameStats

* Truck upgrades now prevent certain events

Adjusted stats implementations of weighting for roads
Truck now contains bonuses for each events.

* event_chance method

Added method to call to determine if event is happening
Added required index for random choices

* Moved adjusted event weights to event controller

* Added comments for event weights

* Update master_controller.py

* Updated move action for new map

* Event trigger added to movement

* Added gas usage to move

* Changed damage and time values to be based on how often events happen

* Removed unnecessary event type bonuses

* Added base for high speed-risk

* Balance pass on upgrades

Added Monster truck tires to mitigate damage from bandits

* added monster truck to enums

* Fixed issues with last PR

* Refactored event controller

Co-authored-by: Christopher Parks <[email protected]>

* Dynamic Event Chance (#52)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Moved event weights to GameStats

* Truck upgrades now prevent certain events

Adjusted stats implementations of weighting for roads
Truck now contains bonuses for each events.

* event_chance method

Added method to call to determine if event is happening
Added required index for random choices

* Moved adjusted event weights to event controller

* Added comments for event weights

* Update master_controller.py

* Updated move action for new map

* Event trigger added to movement

* Added gas usage to move

* Changed damage and time values to be based on how often events happen

* Removed unnecessary event type bonuses

* Added base for high speed-risk

* Balance pass on upgrades

Added Monster truck tires to mitigate damage from bandits

* added monster truck to enums

* Fixed issues with last PR

* Refactored event controller

* Event chance now scales with truck speed

* added set_speed action

* Bug fixes

Co-authored-by: Christopher Parks <[email protected]>

* Sean (#53)

* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Merged Chris

* Merged dev

* began work on time function

* Gas Controller changes

* Buy controller?

* Moved time to player

* Resolved sophies suggestions

* removed locationTypes File

* Added file for effort controller

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* Create 2020-10-27-byte-le-minutes.md

* EventHandler Logic

Method to randomly chose and execute an event.

* Working game!

* Removed print statement!

* Moved event_handler

Moved into controllers and renamed to event_controller

* removed controllers

* Removed imports

* Other minor changes

* Okay guys it really works this time

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Add files via upload

* Linked truck\'s node to map

* Added missing import

* Began work on upgrade controller

* Add files via upload

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* Add files via upload

* Update 2020-11-17-byte-le-minutes.md

* More upgrades and their tests! TODO add logic for only having one of each upgrade class

* Began work on changing upgrade logic to only allow for one upgrade of each type

* Add files via upload

* Add files via upload

* Completed the framework for upgrading objects.

* Added some comments.

* Finished body upgrade controller, objects and tests. Need to align tests so they are more similar

* Finished upgrade logic, changed classes so they all inherit baseUpgradeObject

* Add files via upload

* made tests similar to eachother, all passing

* Fixed spelling mistakes

* Removed logic that only allowed you to buy gas at cities

* Fixes. Added inheritence for body objects so they all have gas levels. I think it works

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* Added truck to/from json, logic to prevent contract selection being out of bounds

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* Began work on implementing how upgrades impact event damage and chance. Still thinking about the best way to do this

* Fixed node not calling to_json method in truck

* began changes to gamestats, event controller

* Fixed some json

* node json and typo fix

* fixed typo

* Finished changing the logic for events, will start creating tests for them

* fixed duplicate from merge

* basic json output

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* more progress on the event controller tests, fixes

* percentage change

* organization and longer roads

* More progress on creating tests

* Merged Dev

* Finished event testing. Was unable to unit test move because it's too bulky/dependant to unit test

* Removed uneccesary assignement of event controller hapenning twice, commented out auto time reduction

* Created better town names

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Deleted outdated city name test

* Began looking into broken upgrade controller

* Before pull dev

* Reverted changes to payment

* Fixes to health and gas actions so they work as intended

* Uncommented game map in contract for now

* Sphinx

* oopsie

* Added maximum speed gamestat. Also Fixed bad reference in heal controller. Added speed unit test

* Began work on documentation

* Began work on documentation

* Fix partial gas buy

* Fixed client, __speed variable was unnecessary

* Changes is not to !=

* Removed move unit tests

* Set upgrades to base objects. minor changes to base client

* Updated docs a bit

* Every turn now takes one tick of time. Pumping gas, repairing and upgrading also now take time with this time listed in gamestats. Updated docs but more work to do

* Fixed some formatting stuff

* More formatting junk

* Fixed mpg to be based on speed 'again'

* Added final score

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>
Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>

Co-authored-by: Quinton Stanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Spencer Fjelstad <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>
Co-authored-by: qastanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>

* slight changes to stats. Fixed tire switching not working

* fixed max turn time

* Add files via upload

* Added scrimage server

* Began work on scrimage server

* Upped buffer size

* a bunch of stuff

* Updated git ignore to have vID

* Added log removal after new game is run

* More client changes

* Update build.sh

Changed back to 3

* Added new scrimmage server

* Added scrimmage temp folders to git ignore

* Fixed bug where runs would go past max runs

* Updated client, added time subtraction for no actiontype chosen

* Added url resolver. CSS style

* Fixed formatting issues

* Built documentation

* Moved test client, changed docs

* 2021-02-16-byte-le-minutes.md

* Revert "Add files via upload"

This reverts commit c8fed01.

* Moved some stuff around within the docs

* hey look it'sa website er something maybe

* Considerable changes to documentation

* made some edits to the wrapper. updating should now be possible once we start working with versions which I'd really like to have started doing by now but that's neither here nor there at this point. happy face, happy thoughts happy face happy thoughts

* Tiny little itty bitty change because I'm a smarty pants. Also not sure who put that semi-colon there, Riley.

* Changes

* Built docs, added new command

* More merge conflicts that don't show up in rst files

* Updated server

* Resolved conflict in html, unneeded files

* Added great image

* Removed map comment

* Fixed issue with __main__

* Getting Started Doc Update (#82)

* Fast forwarding

* Competition ready visualizer

* Moved clients back to correct places

* Fixed issue with .exe not running

* Updated visualizer after Chris's changes

* Initial visualizer changes to be fixed for merge

* Edited docs and added Visualizer documentation

* Added more clarification about roads

* Visualizer changes

* Doc changes, contract selection update, removed risk from illegal contract (#83)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Linked truck\'s node to map

* Added missing import

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* node json and typo fix

* fixed typo

* fixed duplicate from merge

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* percentage change

* organization and longer roads

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Removed old comment

* Map location changes

* road json changes

* illegal contracts initial commit

* illegal contracts initial

* illegal contract logs

* Fixed typo

* Map json size reduction

* fixed build.sh

* Map json fix and contract state

* Revert to old contract/map location

* base client, upgrade cost method, documentation, pass contract

* docs changes and fixes

* Minor changes to base client

* rebuilt docs

* add missing, rebuild

* Built sphinx

* Base client, truck upgrade cost method, docs (#80)

* Added RoadType and DisasterType to enums

* Added length modifier to road

* Added road_type as parameter for road

* Connect road types to event types

* EventHandler Logic

Method to randomly chose and execute an event.

* Moved event_handler

Moved into controllers and renamed to event_controller

* Changed possible event types from sets to lists (for weighting)

* Added missing name in get city by name

* Linked truck\'s node to map

* Added missing import

* Revert "Linked truck\'s node to map"

This reverts commit 660b051.

* placeholder contract generation reimplemented, json modified

* fixes and region modifiers

* json fixes, player current node, selection modification

* fixes, comments, removed redundancy

* more fixes

* minor fixes

* node json and typo fix

* fixed typo

* fixed duplicate from merge

* Current node assignment fixes, typo

* missing self in event_controller

* missing import

* quick fix

* percentage change

* organization and longer roads

* truck from json, contract deadline/renown, moved money to truck

* removed broken is equal method

* reimplement contract == method

* deadline stat changes

* Fixed test cases

* Removed old comment

* Map location changes

* road json changes

* illegal contracts initial commit

* illegal contracts initial

* illegal contract logs

* Fixed typo

* Map json size reduction

* fixed build.sh

* Map json fix and contract state

* Revert to old contract/map location

* base client, upgrade cost method, documentation, pass contract

* docs changes and fixes

* Minor changes to base client

* rebuilt docs

* add missing, rebuild

* Built sphinx

Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>

* Fixed body object toString()

* I apologize in advance

* fixed visualizer.exe not found

* Sphinx build

* upped version

* Built docs

* removed bad docs

Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Sean Hagen <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>
Co-authored-by: PixPanz <[email protected]>
Co-authored-by: Spencer Fjelstad <[email protected]>

* added back missing files

* Added back index.html

sometimes those random files are there for a reason.

* Documentation fixes

* Fixed gas exploit, bumped max time to .5

* Merged

* removed time bump

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Anomalous-Creator <[email protected]>
Co-authored-by: [Sean Hagen] <[email protected]>
Co-authored-by: qstanley <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: PixPanz <[email protected]>
Co-authored-by: Spencer Fjelstad <[email protected]>
Co-authored-by: Sophie Noel <[email protected]>
Co-authored-by: qastanley <[email protected]>
* Saving work on road

* Commit for safety in case of reversion.

Needs fixing and cleanup, but saving to branch in case of future problems.

* Reversion Point

Not ready for pull request.

* New action and other changes.

Still not ready to pull.

* Action object changed and selection modified

Contract list added to action object constructor in order to allow for pre-tick contract generation that is accessible by the client without exposing player.

* Changed location type to region

* Delete singleton_controller.py

Removed unused Singleton

* Cleanup and memes

* Changed from_json and added copy

Needs review

* Removed deprecated client property

* Fixed active contract assignment

* Added comments

* Fixes

* More fixes

Changed equals to equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* More fixes

Changed equals to __eq__  to fit python conventions and added isinstance check. Also fixed typo in contract saving.

* Quick fix

* Design Changes

Moved functionality to truck as suggested by Wyly

* Rework

Saving before potentially working on contract generation.

* Comments and fix

* Minor change

* Fixed outdated comment

* Update stats.py

* Update contract_controller.py

* Update action.py

* Fixed multiple outputs

* Initial commit, contract generation

* Added missing method

Data loss

* Missing money variable in player

Data loss

* fixed branch

* Police and speed bugfixes

Co-authored-by: Christopher Parks <[email protected]>
Co-authored-by: Christopher Parks <[email protected]>
* visualizer automatically stops and team name added

* Fixed issue with repairs and slowed down police
* fixedi import validation and allowed math

* big bummer
Copy link
Collaborator

@HagenSR HagenSR left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approve

@GrimQuagle GrimQuagle merged commit ca9048d into master Feb 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants