forked from fefekpodloga/tick
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathloading.go
More file actions
43 lines (39 loc) · 1.7 KB
/
loading.go
File metadata and controls
43 lines (39 loc) · 1.7 KB
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
package main
import (
"fmt"
"time"
)
//i don't have the code that actually does stuff, so i'll just add random tasks
func loading_screen(port string) {
clear()
progress := ProgressBar{
total: 100,
length: 50,
last_suffix: 0,
enabled: true,
}
time.Sleep(1 * time.Second)
progress.change(0, "Loading ...", "Initializing\n")
time.Sleep(500 * time.Millisecond)
progress.change(20, "Loading ...", "Connecting to "+"Localhost:"+port+"\n")
time.Sleep(1 * time.Second)
progress.change(40, "Loading ...", "We will be done soon\n")
time.Sleep(1 * time.Second)
progress.change(60, "Loading ...", "Welcome to Tick\n")
time.Sleep(1 * time.Second)
progress.change(80, "Loading ...", "Downloading Assests\n")
time.Sleep(1 * time.Second)
progress.change(100, "Loading ...", "Final task\n")
time.Sleep(1 * time.Second)
progress.clean()
clear()
}
func PrintTitle() {
fmt.Println(Cyan + "████████ ██ ██████ ████████ █████ ██████ ████████ ██████ ███████")
fmt.Println(" ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ")
fmt.Println(" ██ ██ ██ ██ ███████ ██ ██ ██ ██ █████")
fmt.Println(" ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██")
fmt.Println(" ██ ██ ██████ ██ ██ ██ ██████ ██ ██████ ███████" + Reset)
fmt.Println()
fmt.Println()
}