mirror of https://github.com/MingweiSamuel/Riven
32 lines
827 B
Plaintext
32 lines
827 B
Plaintext
{{
|
|
const dotUtils = require('./dotUtils.js');
|
|
const queues = require('./.queues.json');
|
|
}}{{= dotUtils.preamble() }}
|
|
|
|
use serde_repr::{ Serialize_repr, Deserialize_repr };
|
|
use num_enum::{ IntoPrimitive, TryFromPrimitive };
|
|
|
|
/// League of Legends matchmaking queue.
|
|
#[cfg_attr(feature = "nightly", non_exhaustive)]
|
|
#[derive(Debug, Copy, Clone)]
|
|
#[derive(Eq, PartialEq)]
|
|
#[derive(Serialize_repr, Deserialize_repr)]
|
|
#[derive(IntoPrimitive, TryFromPrimitive)]
|
|
#[repr(u16)]
|
|
pub enum Queue {
|
|
{{
|
|
for (const e of queues) {
|
|
const desc = e['x-desc'] ? e['x-desc'].split('\n') : [];
|
|
}}
|
|
{{~ desc :line }}
|
|
/// {{= line }}
|
|
{{~}}
|
|
{{? e['x-deprecated'] }}
|
|
/// {{= e.notes }}
|
|
#[deprecated(note="{{= e.notes }}")]
|
|
{{?}}
|
|
{{= e['x-name'] }} = {{= e['x-value'] }},
|
|
{{
|
|
}
|
|
}}
|
|
} |