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

Create local dropoff if the situation warrants #14

Open
dgets opened this issue Nov 9, 2018 · 3 comments
Open

Create local dropoff if the situation warrants #14

dgets opened this issue Nov 9, 2018 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@dgets
Copy link
Owner

dgets commented Nov 9, 2018

If the shipyard isn't within a certain # of squares (requiring 2x # of squares to return to), then we should probably just create a dropoff. Be aware that creating a dropoff requires 4,000 halite, so other factors should probably be taken into account as well (surrounding halite, # of ships in the vicinity, etc).

@dgets dgets added the enhancement New feature or request label Nov 9, 2018
@dgets dgets added this to the beta - halite pathfinding milestone Nov 9, 2018
@dgets dgets self-assigned this Nov 9, 2018
@dgets
Copy link
Owner Author

dgets commented Nov 9, 2018

Okay, for what it's worth, creating a local dropoff if there isn't anything within 5 squares is going to be massive overkill. It takes 4k halite to create a dropoff point, after all. So we're going to have to do several things here...

  • determine the amount of halite we have in relation to the 4k needed
  • determine how long it's taken us to accrue this
  • determine whether or not it is worthwhile to create another one (ie will other ships be using it, as well?)
  • create the new dropoff point only iff the above criteria indicate that it is a good choice

dgets added a commit that referenced this issue Nov 9, 2018
… Note that this is untested. Also removed bogus try/except from nightMiner.py (yeah, not related to this branch-- oopsie).
@dgets
Copy link
Owner Author

dgets commented Nov 9, 2018

This is going to be much easier after the MapChunk functionality is implemented, in order to better determine the local concentration of halite. Waiting on this until then... Er, well, at least waiting on that to handle the 3rd checkbox above...

@dgets dgets changed the title Create local dropoff if there is nothing w/in 5 squares Create local dropoff if the situation warrants Nov 9, 2018
@dgets dgets mentioned this issue Nov 20, 2018
4 tasks
@dgets
Copy link
Owner Author

dgets commented Nov 20, 2018

As the above issue reference was creation of a duplicate issue, I'm simply pasting that information into this thread. NOTE: there are new factors taken into account...

New (and probably some duplicate) information & factors follow:

Now that we've got some bots out that are a bit better about spawning and mining, we're ending up with a lot of ships that have almost full halite that are unable to return to the shipyard, due to clogging of the main route & the pawn formation issue (#33). It would be very beneficial to pick those that are congested, and farther away from the shipyard than the others, and create a new dropoff in order to facilitate easier collection of halite.

This will necessitate, at least, the following:

  • analysis of the ShipHistory for more than just the last turn, or at least proper turnstamp setting and analysis; however, being as more ShipHistory is going to be required at some point soon, anyway, it'd make sense to just Do It Right(tm) the first time here (or second time, as it were)
  • analysis of the game_map in order to determine the proper [full] ship to create a dropoff with; this will be based upon ships surrounding it (at least those in pawn formation and/or full of halite) and distance from the shipyard or other dropoffs
  • how long any pawn formation blockade has existed (potentially negating the above factor)
  • (at some point) analysis of the closest local maxima to determine if it may be most efficient to create a dropoff anyway

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant