Coder Social home page Coder Social logo

motherload-clone's People

Contributors

h1ddengames avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

mnasir786

motherload-clone's Issues

[Story] Implement Block Generation

Acceptance Criteria

  • Blocks will be generated according to a list of block zones.
  • Blocks can be generated during edit mode.
  • Blocks can be generated during the start of play mode.
  • Blocks can be saved as JSON data.
  • Blocks can be generated from JSON data.

Test Scenarios

[Story] Implement Block Zones

Acceptance Criteria

  • A block zone is defined by a low/negative x value, a high/positive x value, and a positive depth, y value that looks like a rectangle.
    • Example: BlockZone(-10, 10, 10) => Will be a zone that starts at -10 on the x axis, goes to +10 on the x axis in a row, then has 10 rows total going down. This will spawn 20 (abs(-10) + abs(10)) x 10 blocks = 200 blocks.
  • A block zone contains a Dictionary that gives a Block Type (Dirt, Silver, Gold, etc) as a key and the percentage change for it spawning in a given (x,y) position as an integer between 0 and 100.
  • Example: <key: dirt-block>:<90> (dirt block will spawn with a 90% rate) <key: silver-block>:<4> (silver block will spawn at a 4% rate) key:gold-block:<1> (gold block will spawn at a 1% rate)

Test Scenarios

  • Block Zone Size
    • Verify that block zone low x value can be a minimum of -30.
    • Verify that block zone low x value can be a maximum of -1.
    • Verify that block zone high x value can be a minimum of 1.
    • Verify that block zone high x value can be a maximum of 30.
    • Verify that block zone Dictionary size is at least 1.

Add a WeightedRandomizer for spawning blocks, traps, and loot.

  • Using a dictionary, supply an object as the key and an integer as the value that dictates the percentage that the given object will be chosen.
  • Example Definition: public Dictionary<Sprite, int> blockProbability = new Dictionary<Sprite, int>();
  • Example Usage:
    sprite = WeightedRandomizer.From(listOfBlockZones[currentBlockZone].blockProbability).TakeOne();
  • Example Usage:
    <dirt-block-16x16.png, 90> // 90% chance of being chosen.
    <empty-block-16x16.png, 8> // 8% chance of being chosen.
    <ruby-block-16x16.png, 2> // 2% chance of being chosen.

Move "Setting up the project" section in the README.md to a Wiki page.

  • Create a Wiki page.
  • Rename "Setting up the project" to "Creating a Unity Project with CI/CD pipeline"
  • Copy the contents of "Setting up the project" from README.md to "Creating a Unity Project with CI/CD pipeline" Wiki page.
  • Remove the contents of "Setting up the project" from the README.md

[Story] Implement Blocks

Acceptance Criteria

  • Block prefab will have an empty GameObject (script holder) with a Sprite as the first child.
  • Blocks have a sprite.
  • Blocks have a level.
  • Blocks give experience when destroyed.
  • Blocks take a certain amount of time to destroy based on the rarity of the block.
  • Blocks play a sound when destroyed.
  • Blocks show an animation when destroyed.
  • Blocks will be added to the player's inventory.

Test Scenarios

  • Block Sprite
    • Verify each block will have one sprite. [Manual]
    • Verify blocks without a sprite will generate a log error. [Manual]

  • Block Levels
    • Verify blocks can have a minimum level of 1. [Auto]
    • Verify blocks can have a maximum level of 100. [Auto]
    • Verify blocks set to a lower level than 1 will automatically be set to 1 and generate a log error. [Manual]
    • Verify blocks set to a level higher than 100 will automatically be set to 100 and generate a log error. [Manual]

  • Block Experience
    • Verify blocks can give a minimum of -999999 experience. [Auto]
    • Verify blocks can give a maximum of 999999 experience. [Auto]

  • Block Destruction Time => Calculation moved to another script.
    • Verify if the block has a higher level compared to the player, the block will take less time to destroy.
    • Verify if the block has a lower level compared to the player, the block will take less time to destroy.
    • Verify if the block is the same level compared to the player, the time to destroy the block will be determined by the player's equipment.

  • Block Destruction Sound
    • Verify a sound plays when a block is being destroyed. [Manual]
    • Verify a sound plays when a block has been destroyed. [Manual]

  • Block Destruction Animation
    • Verify an animation plays when a block is being destroyed. [Manual]
    • Verify an animation plays when a block has been destroyed. [Manual]

  • Temporary Player Inventory => Moved to another script.
    • Verify block is added to a list of blocks when that block has been destroyed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.