Archipelago - Addition of pirate ships and forts v0.8

Some new updates for Archipelago - the seafaring and trading turn-based strategy game that I have been working on: forts and pirate ships!

Pirate ships roam the seas, attacking and raiding cargo ships for their treasures. Keep away from them if you want to fulfil your contracts!

Forts are stronger settlements with cannons and will provide a safe sea harbour into which pirate ships cannot enter.

This contribution includes:

  • Addition of pirate ships to the board and inclusion of pirates within the sequence of turns
  • Automation of pirate ship activity when their turn is reached
  • Pirate ships target any cargo ships within their reach
  • Otherwise pirate ships move the maximum distance possible with the wind on each turn
  • The capability to turn off visibility of activated tiles so pirate ship moves can be seen to be autonomous
  • The CSS design of forts and their inclusion on the board


Screen Shot 2018-03-28 at 23.45.36.png


For a full view of the current state of the game see my github-hosted page:
https://miniature-tiger.github.io/archipelago/

Background details of the project and a list of previous updates can be found at the end of this contribution post.


New Features covered by this Contribution


Addition of pirate ships

The main new complexity added by the pirate ships is that their movement is automated rather than based on user input. This required some automated decision making so that the pirate ship movements are logical. As a starting point for this methods were written to:

  • Capture the positions of all pirate ships on the board
  • Determine if any cargo ships are within range for capture
  • Determine to which tile the pirate ships should sail if no cargo ship is in range (based on maximum distance with the minimum cost of wind)
  • Loop through each pirate ship and determine which action should be carried out (capture ship takes priority then move)
  • Automate the existing "manual turn" code to run the pirate turns without user inputs

Screen Shot 2018-03-29 at 00.01.36.png

Pirate ships about to capture a cargo ship


The code changes for this part of the update are covered here:
https://github.com/miniature-tiger/archipelago/pull/23/commits/0200fd2d6d6d4718f7b6a66c94cc5512c319cbfd

The main code to manage automated movement of pirate ships has been added in a new javascript file: pirates.js


CSS design of forts

Forts are stronger settlements with cannons and will provide a safe sea harbour into which pirate ships cannot enter.

This contribution includes the CSS design of the fort. Future work will cover the harbour and the restriction of pirate ships from entering.



Screen Shot 2018-03-29 at 00.12.22.png

A fort with a cannon!


The forts code is covered within this commit:
https://github.com/miniature-tiger/archipelago/pull/22/commits/04b40c3b9df51cce8f04b9ae505f474d9c1413ec

It is mainly CSS design within the pieces.css file.


That is all for this update. If you have any queries please drop them in the comments or contact me on discord.


Details of the Archipelago Project

What is the Project About?

Archipelago is a new project that I have been working on. The aim is to develop a seafaring and trading turn-based strategy game. Players will guide their ships around the islands, searching for goods to aid construction of ships and their bases, trading with the central market and each other, and avoiding hazards like pirates and whirlpools.

Technology Stack

The project is a browser based game:

  • Mechanics: Javascript
  • Visuals: HTML and CSS initially but will be revisited later once I'm happy with the basic gameplay

Previous Updates

Roadmap

For the short term roadmap the first main goal of getting ships on the board and moving at different speeds under the influence of the compass is COMPLETE!

Work has already begun on the second stage which is land squares and goods discovery and delivery contracts including the player dashboards. Work has also begun on adding pirates and conflicts.

Phase 1 - Board and ship movement: COMPLETE!!!
  • Board set up - COMPLETE
  • Basic ship creation: functionality and graphics - COMPLETE
  • Manual ship movement and board updating - COMPLETE
  • Basic compass creation: functionality and graphics - COMPLETE
  • Turn based activity of ship movement - COMPLETE
  • Logic of length of longer moves around obstacles - COMPLETE
  • Chaining together transitions to allow graphics of longer moves - COMPLETE
  • Refactoring to allow CSS transitions layer above "refresh" layer - may not now be necessary - for consideration in future.
Phase 2
Land Squares and Resources:
  • Dashboard of player pieces and resources - COMPLETE
  • Resource tiles (forest, iron, flax, gold etc) - in progress: forest and ironworks added
  • Summaries of produce and populations and functioning for each Resource
Contracts for delivery:
  • Semi-random (equitable) generation of trade delivery contracts
  • Creation of trade settlements
  • Dashboard for contracts
  • Mechanics for contract sign-up
  • Mechanics for contract delivery
The long term roadmap is still to be fully fleshed out but includes:
  • Building: (recipes, times etc)
  • Islands (naming: for describing location ot pieces, trading settlements)
  • Central trading centre:
  • Conflicts:
  • Pirates:
  • Scoring:

Contact / Contribute

You can get in touch with me on discord if you would like to contribute.

You can find the current state of the game here:
https://miniature-tiger.github.io/archipelago/

The repository for the project is here:
https://github.com/miniature-tiger/archipelago

Have fun!



Posted on Utopian.io - Rewarding Open Source Contributors

H2
H3
H4
3 columns
2 columns
1 column
6 Comments