forked from challenge-project/challenge-sandbox
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathInternet.Script.txt
More file actions
43 lines (34 loc) · 856 Bytes
/
Copy pathInternet.Script.txt
File metadata and controls
43 lines (34 loc) · 856 Bytes
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
/*
// Internet.Script.txt
// by BigBang1112
// part of Universe Library Set
// Easy library to check if you're in Online or Offline mode.
// This library does not depend on any other library from the Universe Library Set.
// You can use this library independently, although it's recommended to use the whole set.
*/
/*
// Compatible contexts:
// - CManiaApp
*/
/*
// Text[] GetZones()
// Boolean IsOnline()
// Boolean IsOffline()
*/
#Include "TextLib" as TextLib
/*
// Boolean IsOnline()
// Checks if you launched Maniaplanet in online mode.
// Returns True if you're in Online mode, otherwise False
*/
Boolean IsOnline() {
return LocalUser.ZonePath != "";
}
/*
// Boolean IsOffline()
// Checks if you launched Maniaplanet in offline mode.
// Returns True if you're in Offline mode, otherwise False
*/
Boolean IsOffline() {
return !IsOnline();
}