pokemon-showdown/sim/index.js
Quinton Lee a0b8228592 TypeScript: Improve Sim typing (#4069)
Also improves intellisense for Visual Studio and Visual Studio Code.
2017-10-20 07:53:26 -05:00

35 lines
818 B
JavaScript

/**
* Simulator process
* Pokemon Showdown - http://pokemonshowdown.com/
*
* This file is where the battle simulation itself happens.
*
* The most important part of the simulation happens in runEvent -
* see that function's definition for details.
*
* @license MIT license
*/
'use strict';
const Dex = require('./dex');
global.toId = Dex.getId;
const Battle = require('./battle');
const Side = require('./side');
const Pokemon = require('./pokemon');
const PRNG = require('./prng');
/**
* @param {string} format
* @param {boolean | string} rated
* @param {Function} send
* @param {PRNG} [prng]
*/
exports.construct = function (format, rated, send, prng) {
return new Battle(format, rated, send, prng);
};
exports.Pokemon = Pokemon;
exports.Side = Side;
exports.Battle = Battle;
exports.PRNG = PRNG;