PHP code example of onody / gachagacha

1. Go to this page and download the library: Download onody/gachagacha library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

onody / gachagacha example snippets




$gachagacha = new \GachaGacha\Picker();

$gachagacha->set('Marks',    30.124);
$gachagacha->set('Daniel',   20);
$gachagacha->set('Schuster', 0);

$gachagacha->pick();        // single item
$gachagacha->pick(1000);    // array of items
bash
php composer.phar install