-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathstdlib.ps
52 lines (44 loc) · 962 Bytes
/
stdlib.ps
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/*
* PawnScript
* Standard Library
*
* (c) Brace Inc.
*/
#pragma:reqref,true; // We should embrace return references.
using system
using console
using files
using data
using math
using pawn
using misc
using iter
using vector
using samp; // Deprecated.
constexpr namespace std
{
// Some PAWNSCRIPT constants:
const*new.str,nullstr=" "
const*new.char,nullchar=' '
// Simpler keywords to create variables with:
typedef,new.int,int
typedef,new.bool,bool
typedef,new.str,string
typedef,new.double,double
typedef,new.double,float
typedef,new.char,char
typedef,new.int.unsigned,uint
typedef,new.int.short,sint
// Default return references:
new.int,intretref=0
new.bool,boolretref=false
new.str,strretref="null"
new.char,charretref='0'
new.double,doubleretref=0.0
// Some constants:
const*new.double,pi=3.14
const*new.double,euler=2.71
const*new.double,gravacc=9.81
template<console.println.log>writeln
template<console.cout.log>writec
}