-
Notifications
You must be signed in to change notification settings - Fork 1
/
DolphinTags.ahk
74 lines (72 loc) · 1.88 KB
/
DolphinTags.ahk
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#SingleInstance force
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#Persistent ; Stay open in background
SetTitleMatchMode, 2
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
file := FileOpen("user1.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user2.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user3.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user4.txt", "w")
file.Length := 0
file.Close()
while True
{
ControlGet, Names, List, , ListBox1, Dolphin NetPlay
If(Names == "")
{
file := FileOpen("user1.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user2.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user3.txt", "w")
file.Length := 0
file.Close()
file := FileOpen("user4.txt", "w")
file.Length := 0
file.Close()
}
Loop, Parse, Names, `n, `r
{
IfInString, A_LoopField, [1] :
{
StringReplace, TempName, A_LoopField, [1] :, ■
StringSplit, Player1Name, TempName, ■
file := FileOpen("user1.txt", "w")
file.Write(Player1Name1)
file.Close()
}
IfInString, A_LoopField, [2] :
{
StringReplace, TempName, A_LoopField, [2] :, ■
StringSplit, Player2Name, TempName, ■
file := FileOpen("user2.txt", "w")
file.Write(Player2Name1)
file.Close()
}
IfInString, A_LoopField, [3] :
{
StringReplace, TempName, A_LoopField, [3] :, ■
StringSplit, Player3Name, TempName, ■
file := FileOpen("user3.txt", "w")
file.Write(Player3Name1)
file.Close()
}
IfInString, A_LoopField, [4] :
{
StringReplace, TempName, A_LoopField, [4] :, ■
StringSplit, Player4Name, TempName, ■
file := FileOpen("user4.txt", "w")
file.Write(Player4Name1)
file.Close()
}
}
Sleep, 1000
}