0.7.72 • Published 22 days ago

@urso/slot-base v0.7.72

Weekly downloads
-
License
MIT
Repository
github
Last release
22 days ago

URSO HTML5 Slot Machine

ursojs.io logo

About

This is slot machine game Engine. Main components for the slot machines creation.

  • Responsive (for mobile)
  • Fullscreen mode
  • Fast performance
  • Low bundle size
  • Spine support

Live Demo

Learn more

How to

  • create index.js with game dependencies and Urso.runGame call rules. We recommend calling this function on boot
  • put the loading config (load.js) in app/config and set up your app namespace there
  • put the main configuration (main.js) in app/config and configure your application there. extendingChain is used to extend names
  • in package.json add @urso/slot-base as a dependency
  • put an info file (_info.js) in app/templates to set up a sub-namespace
  • put an info file (_info.js) in app/templates/scenes to set up a sub-namespace
  • place the scene template file (play.js) in app/templates/scenes. The game scene will be used by default in our engine
  • in this.objects on the game scene in the file (play.js) put the necessary components from the slot base that you want to use
  • in the options of the 'slotMachine' component, set the 'id' option with one of the values ​​you need: 'basic', 'basicDrop', 'cascadeDrop', cascade', depending on what kind of rotation you want to use
  • start the game !!!

Or just clone ready game from THIS REPOSITORY, run 'npm install && npm run start' and enjoy

Components

autoSpin

Component for launching the machine slot in automatic mode. A kind of menu button to start the drum in the slot of the machine in automatic mode.

background

Component for setting the background of the game. The component changes the background depending on the event, for example, the type of game (bonus or basic) The template.js file of the component implements objects for the background of the game for the bonus version and for the base game.

betLines

A component that calculates the payline value based on the current bet.

loader

A component that implements the animation of the progress of loading resources before the start of the game.

paytable

The component that displays the paytable is a kind of menu with information on the game, which symbol and which combination is equivalent to a reward.

slotMachine

The component that is responsible for displaying characters.

In the options of the 'slotMachine' component, you can set the 'id' option with one of the values ​​you need, depending on what type of rotation you want to use. :

  • 'basic'. - the symbols on the reel are animated by scrolling and stop in turn starting from the left column after the stop, the winning symbols are shown with a flashing animation.
  • 'basicDrop'. - the symbols on the reel are animated by scrolling and stop in turn starting from the left column after stopping, the winning symbols are reset until the pay lines run out.
  • 'cascade' - symbols on the reel are animated by falling after completion, winning symbols are shown with a flashing animation.
  • 'cascadeDrop'. - the symbols on the reel are animated by falling after completion, the winning symbols are reset until the pay lines run out.

The template.js file contains assets and objects for the slot machine where you can set the symbol pictures we need for the slot machine. The file symbols.js - contains dependencies of symbols keys and their images. We can use symbol keys for any implementation of the functionality, for example, playing a sound when a certain key (symbol) appears

ui

A component for applying logic module actions to scene objects.

winCounter

A component for calculating and selecting the type of win. Contains methods for starting and ending the win animation.

In the config file there are 2 objects corresponding to 2 types of winnings Simple win - current Big win - special in the component's _runShowAnimation({ type }) method, the choice of launching the desired one to win is made. The type parameter is the type of win (current or bigwin)

winFrame

A component for implementing additional animation over symbols, for example, animation of pay lines in a game.

winLines

This component shows combinations of winning symbols (win lines) and the parameters corresponding to these lines.

Modules

logic

Main logic module. Here we can implement the logic of the elements depending on the state of the game. For example the behavior of buttons and sounds.

statesManager

Game state module. Based on the core component from Urso.Core Located along the path (see src\js\modules\statesManager) The list of actions is on the path (see src\js\modules\statesManager\actions)

slot-base - contains the required action set for slot games. All states are described by the configStates.js file, which is located along the path src\js\modules\statesManager\configStates.js

  • INIT_GAME - game initialization state. Here objects, a scene are created, game resources are loaded and a connection with the server is established.
  • IDLE is the state in which the game is waiting for action. Usually, this is showing the main scene and waiting for the slot machine to start working.
  • START_SPIN - state when the slot machine starts its work. Here there is a movement of symbols, receiving a response from the server along the pay lines.
  • FINISH_SPIN - states when the slot machine finishes its work. Here there is a stop and the display of the played symbols on the slot machine.
  • SHOW_WIN - the state in which we show the winning information.

This is a standard set of states that is being supplemented during the development process.

transport

Module for working with the server part of the game.

The component contains the base models that are located (see src\js\modules\transport\models). Here we receive information from the server side, as well as send the necessary requests to the server.

License

Built using Urso web engine.

By Lancecat Games

This content is released under the (http://opensource.org/licenses/MIT) MIT License.

0.7.72

22 days ago

0.7.71

29 days ago

0.7.70

2 months ago

0.7.69

2 months ago

0.7.68

2 months ago

0.7.67

2 months ago

0.6.7-dev

4 months ago

0.7.66

4 months ago

0.7.62

4 months ago

0.7.61

4 months ago

0.7.60

4 months ago

0.7.59

5 months ago

0.7.57

5 months ago

0.7.58

5 months ago

0.7.35

10 months ago

0.7.34

10 months ago

0.7.37

10 months ago

0.7.36

10 months ago

0.7.39

10 months ago

0.7.38

10 months ago

0.7.55

6 months ago

0.7.54

6 months ago

0.7.56

6 months ago

0.7.51

7 months ago

0.7.50

7 months ago

0.7.53

7 months ago

0.7.52

7 months ago

0.7.44

9 months ago

0.7.43

9 months ago

0.7.46

7 months ago

0.7.45

8 months ago

0.7.40

10 months ago

0.7.42

9 months ago

0.7.41

10 months ago

0.7.48

7 months ago

0.7.47

7 months ago

0.7.49

7 months ago

0.7.33

12 months ago

0.7.32

12 months ago

0.7.31

12 months ago

0.7.30

12 months ago

0.7.29

12 months ago

0.7.26

1 year ago

0.7.25

1 year ago

0.7.28

12 months ago

0.7.27

1 year ago

0.7.22

1 year ago

0.7.21

1 year ago

0.7.24

1 year ago

0.7.23

1 year ago

0.7.20

1 year ago

0.7.23-m-dev-2

1 year ago

0.7.23-m-dev-1

1 year ago

0.7.23-m-dev-3

1 year ago

0.7.23-m-dev

1 year ago

0.7.2

1 year ago

0.7.20-dev

1 year ago

0.7.4

1 year ago

0.7.3

1 year ago

0.7.11

1 year ago

0.7.10

1 year ago

0.7.9

1 year ago

0.7.13

1 year ago

0.7.12

1 year ago

0.7.5

1 year ago

0.7.8

1 year ago

0.7.7

1 year ago

0.7.19

1 year ago

0.7.18

1 year ago

0.7.15

1 year ago

0.7.14

1 year ago

0.7.23-dev2

1 year ago

0.7.20-dev1

1 year ago

0.7.17

1 year ago

0.7.23-dev3

1 year ago

0.7.16

1 year ago

0.7.23-dev

1 year ago

0.6.6

1 year ago

0.6.4-dev

1 year ago

0.7.1

1 year ago

0.5.0

2 years ago

0.7.0

1 year ago

0.5.2

2 years ago

0.5.1

2 years ago

0.6.3

2 years ago

0.6.2

2 years ago

0.6.5

1 year ago

0.6.1

2 years ago

0.6.0

2 years ago

0.4.1

2 years ago

0.4.0

2 years ago

0.3.0

2 years ago

0.3.1

2 years ago

0.3.0-dev16

2 years ago

0.3.0-dev13

2 years ago

0.3.0-dev12

2 years ago

0.3.0-dev15

2 years ago

0.3.0-dev14

2 years ago

0.3.0-dev2

2 years ago

0.3.0-dev11

2 years ago

0.3.0-dev10

2 years ago

0.3.0-dev5

2 years ago

0.3.0-dev6

2 years ago

0.3.0-dev3

2 years ago

0.3.0-dev4

2 years ago

0.3.0-dev9

2 years ago

0.3.0-dev7

2 years ago

0.3.0-dev8

2 years ago

0.3.0-dev1

2 years ago

0.2.1

3 years ago

0.2.3

2 years ago

0.2.2

2 years ago

0.2.4

2 years ago

0.1.10

3 years ago

0.2.0

3 years ago

0.1.9

3 years ago

0.1.8

3 years ago

0.1.7

3 years ago

0.1.6

3 years ago

0.1.5

3 years ago

0.1.4

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago