Giter VIP home page Giter VIP logo

dicegame-2's Introduction

PROJECT 2

Project 2

Responsive Images

Features

This is classic American dice game played on the streets of New York City. The rules are simple, Roll 4 5 6 you win , 1 2 3 you lose and you must roll either 2 die the same and one different XXY. YYX, or all the same XXX, YYY to have a valid roll, then scores are determined by who rolls the biggest number. p1win

  1. Options
  • This game is up to two players or you can play against the CPU OPTIONS
  1. Styling
  • I styled the game in the 1980s 2-bit gaming fashion and tried to give a genuine 80s arcade game feel.
  • I found the 2-bit font ("2-Player" in google fonts) first and that slowly inspired the rest of the project. things kind of fell into place. STYLE
  • The color way is supposed to invoke snakes and the like to give the game a street/ unfair look, like you playing dice with a snake.
  1. Gradient
  • I added this cool gradient feature to the title that gives it the effect of a flashing sign.
  • gradient image 1
  • gradient image 2
  1. Cool Function I. Roll/Kompare Fucntion
  • This function is essentially my whole project, you delete everyhting and leave this and I would be happy. This funtion "spin"/changes the die faces ,generates the random integers and compares the values.
  • kompare
  1. Snake Eyes
  • Depending on what the user rolls he or she will get a different dispaly at the top, the most common being "Snake Eyes" snake eyes

Testing

*The testing was difficult. I had a lot of bugs in my javascript I couldnt figure out. Actually I spent about five days on a problem with the "Roll" fucntion I created. example1

  • Already this fucntion is a difficult to explain in words but makes sense in my head, in the beginning the dice would "roll" once and then not work again even though my fucntion worked well in the cosnole ( random number between 1-6 were generated but the image/dice face wouldnt change) so first I went to google , I thought something like this would was common place but I was wrong....kinda. I couldnt find the solution online so I wnet the tutors and they couldnt figure it out. I was not happy to say the least so I decided to rewrite my JS and just by placing certain variables at the top and elminatining CONST on things that are actualy going change it all wokred out but really was quite the headache. example2

HTML/CSS Validator

  • No errors were returned when passing through the official CSS W3 validator CSS

  • No errors were returned when passing through the official HTML W3 validator HTML

Bugs

  • All bugs have been fixed. I had a problem with an icon but a quick google search cleared it up.
  • Problem & Solution problem solution

Deployment

Credits

Content

  • The font came from Google Fonts .
  • The changing die face img idea came from YouTube
  • The Gradient idea came from YouTube as well.
  • The layout CSS I got the inspiration from the STREET FIGHTER game and page like THIS & THIS

Media

  • All images came from Google.

dicegame-2's People

Contributors

bibi78 avatar

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.