API Basic Windows ko - LIHACHTETAN/ClassicUO-BadNewbie-BasicIDE GitHub Wiki
Windows.bas
ClassicUO โข Basic
Windows.bas๋ ํ๋ก์ธ์ค ์ ๋ณด, ์งง์ ์๊ฐ ์ธก์ , ๋ฐ์คํฌํฑ ํฌ๊ธฐ๋ฅผ ์ํ ๊ณต๊ฐ ํจ์ 6๊ฐ๋ฅผ ์ ๊ณตํ๋ ํธ์ง ๊ฐ๋ฅํ Basic ๋ชจ๋์ ๋๋ค. ์ ์ฒด ์ฝ๋์ Private Declare๋ฅผ ์๋์ ํ์ํฉ๋๋ค. Main๋ง ๋ณต์ฌํ๋ฉด ์คํ๋์ง ์์ต๋๋ค.
์ ํํ ๊ตฌ๋ฌธ
Include "Windows.bas"
Windows.ProcessId() As Integer
Windows.Milliseconds() As Double
Windows.ElapsedMilliseconds(ByVal startMilliseconds As Double) As Double
Windows.ScreenWidth() As Integer
Windows.ScreenHeight() As Integer
Windows.DesktopBounds() As Object
๋งค๊ฐ๋ณ์
Include / Windows.basโ Include "Windows.bas"๋ Scripts/Include/Windows.bas๋ฅผ ์ฐ๊ฒฐํฉ๋๋ค. ๋ณ๋ ์คํฌ๋ฆฝํธ ํด๋์์๋ Include ํ์ ํด๋์ ๋ณต์ฌํ์ธ์. ์์ ์๋ Main.bas์ Include/Windows.bas๊ฐ ํฌํจ๋ฉ๋๋ค. Windows.๋ก ํธ์ถํ๋ฉฐ UO.๋ ๋ถ์ด์ง ์์ต๋๋ค.ProcessId()โ ProcessId()๋ ์ธ์ ์์ด ํ์ฌ ํด๋ผ์ด์ธํธ์ Windows ํ๋ก์ธ์ค ID๋ฅผ Integer๋ก ๋ฐํํฉ๋๋ค. ์บ๋ฆญํฐยท์์ดํ ์๋ฆฌ์ผ์ด๋ ์๋ฒ ์ฐ๊ฒฐ ID๊ฐ ์๋๋๋ค.Milliseconds()โ Milliseconds()๋ ์ธ์ ์์ด 0..4294967295์ Double์ ๋ฐํํ๋ฉฐ ๋ถํธ ์๋ 32๋นํธ GetTickCount๋ฅผ ๋ํ๋ ๋๋ค. ์์์ธ ๋ค์ดํฐ๋ธ ๊ฒฐ๊ณผ์๋ 4294967296.0์ ๋ํฉ๋๋ค. ์ฝ 49.7์ผ๋ง๋ค ์ํํ๋ฉฐ ๋ฌ๋ ฅ ์๊ฐ์ด๋ ๊ณ ์ ๋ฐ ํ์ด๋จธ๊ฐ ์๋๋๋ค.ElapsedMilliseconds(startMilliseconds)โ ElapsedMilliseconds(startMilliseconds)๋ ์ ์ฅํ Milliseconds() ๊ฐ์ Double๋ก ๋ฐ์ ์ง๋ ๋ฐ๋ฆฌ์ด๋ฅผ Double๋ก ๋ฐํํฉ๋๋ค. 0..4294967295 ๋ฐ์ด๋ฉด ์ค๋ฅ์ ๋๋ค. ์์ ์ฐจ์ด์ 4294967296.0์ ๋ํด ํ ๋ฒ์ ์ํ๋ง ์ฒ๋ฆฌํฉ๋๋ค. ์ธก์ ์ ํ ์ฃผ๊ธฐ๋ณด๋ค ์งง์์ผ ํ๋ฉฐ ํจ์ ์์ฒด๋ ๊ธฐ๋ค๋ฆฌ์ง ์์ต๋๋ค.ScreenWidth() / ScreenHeight()โ ScreenWidth()/ScreenHeight()๋ ์ธ์ ์์ด ๋ฉํธ๋ฆญ 0/1๋ก ๊ธฐ๋ณธ ๋ชจ๋ํฐ์ Integer ํฌ๊ธฐ๋ฅผ ๋ฐํํฉ๋๋ค. ํ๋ก์ธ์ค DPI ํ๊ฒฝ์ Windows ์ขํ์ด๋ฉฐ UO ํ์ผ์ด๋ ๊ฒ์ ์ฐฝ ํฌ๊ธฐ๊ฐ ์๋๋๋ค.DesktopBounds()โ DesktopBounds()๋ ๋ฌธ์์ด ํค X, Y, Width, Height์ Integer ๊ฐ์ ๊ฐ์ง ์ Dictionary๋ฅผ ๋ฐํํฉ๋๋ค. Item("X") ๋ฑ์ผ๋ก ์ฝ์ต๋๋ค. ๋ฉํธ๋ฆญ 76~79๋ ๋ชจ๋ ๋ชจ๋ํฐ๋ฅผ ๋๋ฌ์ผ ์ฌ๊ฐํ์ด๋ฉฐ X/Y๋ ์์์ผ ์ ์์ต๋๋ค. ์ฌ์ ์์ ์ ์ฐฝ์ ์ด๋ํ๊ฑฐ๋ ํฌ๊ธฐ๋ฅผ ๋ฐ๊พธ์ง ์์ต๋๋ค.
๋ฐํ๊ฐ
ID์ ํ๋ฉด ํฌ๊ธฐ๋ Integer ์๋, ์๊ฐ์ Double ๋ฐ๋ฆฌ์ด๋ก Boolean์ด ์๋๋๋ค. DesktopBounds๋ Integer ๊ฐ์ ๊ฐ์ง Object(Dictionary)์ ๋๋ค. Include์ ์ ์ธ์๋ ๊ฒฐ๊ณผ๊ฐ ์์ต๋๋ค. ๊ฐ ์์ Main์ ๋ฐ์ดํฐ ๊ฒ์ฌ ์ฑ๊ณต ์ 1/True, ์คํจ ์ 0/False๋ฅผ ๋ฐํํ๋ฉฐ ๋ชจ๋ ๋ค์ดํฐ๋ธ ์ซ์๊ฐ ์ฑ๊ณต ํ๋๊ทธ๋ผ๋ ๋ป์ ์๋๋๋ค.
๋์
- Windows x64๊ฐ ํ์ํฉ๋๋ค. NativeTicks, NativeProcessId, NativeMetric์ ์๋์ Private Declare 3๊ฐ์ ๋๋ค. DLL ๋์์ Basic.Declare๋ฅผ ์ฐธ๊ณ ํ์ธ์. ๊ฒ์ ํจํท, ์ค์ ๋ณ๊ฒฝ, ์บ๋ฆญํฐ ์ด๋์ ์์ต๋๋ค.
- ๋งค๋ฒ ํ์ฌ ๊ฐ์ ์ฝ์ต๋๋ค. Milliseconds๋ ๋ณดํต 10~16ms๋ง๋ค ๊ฐฑ์ ๋๋ฉฐ ์ฌ๋ฌ ์ํ์ด๋ ๋ค๋ฅธ Windows ์ธ์ ์ ๊ฐ์ ๊ตฌ๋ถํ ์ ์์ต๋๋ค. ์งง์ ์์ ์ ์ฌ์ฉํ์ธ์. Wait์ ์ ํํ ์๊ฐ์ ๋ณด์ฅํ์ง ์์ต๋๋ค.
- Main.bas์ Include/Windows.bas๋ฅผ ํจ๊ป ๋ณต์ฌํ๋ฉด IDE์์ ํธ์งํ ์ ์์ต๋๋ค. DesktopBounds๋ ๋งค๋ฒ ๋ ๋ฆฝ๋ ์ค๋ ์ท์ด๋ฉฐ ๋ชจ๋ํฐ ๊ตฌ์ฑ์ด๋ DPI ๋ณ๊ฒฝ์ ๋ค์ ๊ฒฐ๊ณผ์ ์ํฅ์ ์ค ์ ์์ต๋๋ค.
์์
1. ํ๋ก์ธ์ค์ ์นด์ดํฐ
# Main์ Windows.bas๋ฅผ ์ฐ๊ฒฐํ๊ณ ProcessId()๋ฅผ ์ฝ์ผ๋ฉฐ Milliseconds()๋ฅผ startedAt์ ์ ์ฅํฉ๋๋ค. AndAlso๋ก ์์ ID์ 0..4294967295 ๋ฒ์๋ฅผ ๊ฒ์ฌํด 1/True๋ฅผ ๋ฐํํฉ๋๋ค. ์ค์ ์ซ์๋ ์ปดํจํฐ๋ง๋ค ๋ค๋ฆ
๋๋ค.
Option Explicit On
Include "Windows.bas"
Sub Main()
Dim processId = Windows.ProcessId()
Dim startedAt = Windows.Milliseconds()
Return processId > 0 AndAlso startedAt >= 0 AndAlso startedAt <= 4294967295.0
End Sub
๋งค๊ฐ๋ณ์ ๋ฐ ์คํ ์ค๋ช :
Main์ Windows.bas๋ฅผ ์ฐ๊ฒฐํ๊ณ ProcessId()๋ฅผ ์ฝ์ผ๋ฉฐ Milliseconds()๋ฅผ startedAt์ ์ ์ฅํฉ๋๋ค. AndAlso๋ก ์์ ID์ 0..4294967295 ๋ฒ์๋ฅผ ๊ฒ์ฌํด 1/True๋ฅผ ๋ฐํํฉ๋๋ค. ์ค์ ์ซ์๋ ์ปดํจํฐ๋ง๋ค ๋ค๋ฆ ๋๋ค.
Include/Windows.bas
Option Explicit On
' Windows x64 helpers. Include "Windows.bas" from the main script.
' These declarations use the Windows ABI, not VB6 Integer/Long widths.
Module Windows
Private Declare Function NativeTicks Lib "kernel32.dll" Alias "GetTickCount"() As Integer
Private Declare Function NativeProcessId Lib "kernel32.dll" Alias "GetCurrentProcessId"() As Integer
Private Declare Function NativeMetric Lib "user32.dll" Alias "GetSystemMetrics"(ByVal index As Integer) As Integer
' Returns the current client process ID. This is not a character/item serial.
Public Function ProcessId() As Integer
Return NativeProcessId()
End Function
' Unsigned 32-bit milliseconds since Windows started, represented as Double.
' Wraps every 4294967296 ms (about 49.7 days); this is not a calendar time.
Public Function Milliseconds() As Double
Dim value As Double = NativeTicks()
If value < 0 Then
value += 4294967296.0
End If
Return value
End Function
' startMilliseconds must come from Milliseconds(). Handles one wrap only.
' Use for intervals shorter than 49.7 days; no waiting is performed here.
Public Function ElapsedMilliseconds(ByVal startMilliseconds As Double) As Double
If Not (startMilliseconds >= 0 AndAlso startMilliseconds <= 4294967295.0) Then
Throw "Windows.ElapsedMilliseconds requires a tick value in 0..4294967295."
End If
Dim elapsed As Double = Milliseconds() - startMilliseconds
If elapsed < 0 Then
elapsed += 4294967296.0
End If
Return elapsed
End Function
' Primary monitor dimensions in the process's Windows DPI coordinate space.
' These are desktop dimensions, not the UO game viewport size.
Public Function ScreenWidth() As Integer
Return NativeMetric(0)
End Function
Public Function ScreenHeight() As Integer
Return NativeMetric(1)
End Function
' Returns a new Dictionary: X, Y, Width, Height of the whole virtual desktop.
' X/Y may be negative when monitors are to the left/above the primary one.
Public Function DesktopBounds() As Object
Dim bounds = Dictionary()
bounds.Set("X", NativeMetric(76))
bounds.Set("Y", NativeMetric(77))
bounds.Set("Width", NativeMetric(78))
bounds.Set("Height", NativeMetric(79))
Return bounds
End Function
End Module
2. ๋๊ธฐ ์๊ฐ ์ธก์
# MeasureWait(delayMilliseconds)๋ ์์๋ฅผ ๊ฑฐ๋ถํ๊ณ ์นด์ดํฐ๋ฅผ ์ ์ฅํ ๋ค Wait๋ฅผ ์คํํ๊ณ ElapsedMilliseconds(startMilliseconds:=startedAt)๋ฅผ ๋ฐํํฉ๋๋ค. Main์ 15๋ฅผ ์ ๋ฌํ๊ณ elapsed >= 0์ ๊ฒ์ฌํฉ๋๋ค. ์ค์ ์๊ฐ์ 15ms๋ณด๋ค ๊ธธ ์ ์์ต๋๋ค. ๋ชจ๋ ๋ณด์กฐ ํจ์์ ํ ๋ฒ์ ์ํ ์ฒ๋ฆฌ๋ฅผ ์๋์ ํ์ํฉ๋๋ค.
Option Explicit On
Include "Windows.bas"
Function MeasureWait(ByVal delayMilliseconds As Integer) As Double
If delayMilliseconds < 0 Then
Throw "delayMilliseconds must be non-negative"
End If
Dim startedAt = Windows.Milliseconds()
Wait(delayMilliseconds)
Return Windows.ElapsedMilliseconds(startMilliseconds:=startedAt)
End Function
Sub Main()
Dim elapsed = MeasureWait(15)
Return elapsed >= 0
End Sub
๋งค๊ฐ๋ณ์ ๋ฐ ์คํ ์ค๋ช :
MeasureWait(delayMilliseconds)๋ ์์๋ฅผ ๊ฑฐ๋ถํ๊ณ ์นด์ดํฐ๋ฅผ ์ ์ฅํ ๋ค Wait๋ฅผ ์คํํ๊ณ ElapsedMilliseconds(startMilliseconds:=startedAt)๋ฅผ ๋ฐํํฉ๋๋ค. Main์ 15๋ฅผ ์ ๋ฌํ๊ณ elapsed >= 0์ ๊ฒ์ฌํฉ๋๋ค. ์ค์ ์๊ฐ์ 15ms๋ณด๋ค ๊ธธ ์ ์์ต๋๋ค. ๋ชจ๋ ๋ณด์กฐ ํจ์์ ํ ๋ฒ์ ์ํ ์ฒ๋ฆฌ๋ฅผ ์๋์ ํ์ํฉ๋๋ค.
Include/Windows.bas
Option Explicit On
' Windows x64 helpers. Include "Windows.bas" from the main script.
' These declarations use the Windows ABI, not VB6 Integer/Long widths.
Module Windows
Private Declare Function NativeTicks Lib "kernel32.dll" Alias "GetTickCount"() As Integer
Private Declare Function NativeProcessId Lib "kernel32.dll" Alias "GetCurrentProcessId"() As Integer
Private Declare Function NativeMetric Lib "user32.dll" Alias "GetSystemMetrics"(ByVal index As Integer) As Integer
' Returns the current client process ID. This is not a character/item serial.
Public Function ProcessId() As Integer
Return NativeProcessId()
End Function
' Unsigned 32-bit milliseconds since Windows started, represented as Double.
' Wraps every 4294967296 ms (about 49.7 days); this is not a calendar time.
Public Function Milliseconds() As Double
Dim value As Double = NativeTicks()
If value < 0 Then
value += 4294967296.0
End If
Return value
End Function
' startMilliseconds must come from Milliseconds(). Handles one wrap only.
' Use for intervals shorter than 49.7 days; no waiting is performed here.
Public Function ElapsedMilliseconds(ByVal startMilliseconds As Double) As Double
If Not (startMilliseconds >= 0 AndAlso startMilliseconds <= 4294967295.0) Then
Throw "Windows.ElapsedMilliseconds requires a tick value in 0..4294967295."
End If
Dim elapsed As Double = Milliseconds() - startMilliseconds
If elapsed < 0 Then
elapsed += 4294967296.0
End If
Return elapsed
End Function
' Primary monitor dimensions in the process's Windows DPI coordinate space.
' These are desktop dimensions, not the UO game viewport size.
Public Function ScreenWidth() As Integer
Return NativeMetric(0)
End Function
Public Function ScreenHeight() As Integer
Return NativeMetric(1)
End Function
' Returns a new Dictionary: X, Y, Width, Height of the whole virtual desktop.
' X/Y may be negative when monitors are to the left/above the primary one.
Public Function DesktopBounds() As Object
Dim bounds = Dictionary()
bounds.Set("X", NativeMetric(76))
bounds.Set("Y", NativeMetric(77))
bounds.Set("Width", NativeMetric(78))
bounds.Set("Height", NativeMetric(79))
Return bounds
End Function
End Module
3. ๋ฐ์คํฌํฑ ํฌ๊ธฐ
# Main์ ๋
๋ฆฝ๋ Dictionary์์ Item์ผ๋ก X/Y/Width/Height๋ฅผ ์ฝ๊ณ ๊ธฐ๋ณธ ๋ชจ๋ํฐ์ ๋น๊ตํฉ๋๋ค. ๊ธฐ๋ณธ ํฌ๊ธฐ๋ ์์์ด๊ณ ์ ์ฒด ๋ฐ์คํฌํฑ์ด ๋ ์์ง ์์์ผ ํฉ๋๋ค. left/top์ ์์์ผ ์ ์์ผ๋ฉฐ UO ์ด๋ ๋ช
๋ น์ผ๋ก ์ ๋ฌํ์ง ์์ต๋๋ค.
Option Explicit On
Include "Windows.bas"
Sub Main()
Dim desktop = Windows.DesktopBounds()
Dim left = desktop.Item("X")
Dim top = desktop.Item("Y")
Dim width = desktop.Item("Width")
Dim height = desktop.Item("Height")
Dim primaryWidth = Windows.ScreenWidth()
Dim primaryHeight = Windows.ScreenHeight()
Return width >= primaryWidth AndAlso height >= primaryHeight AndAlso primaryWidth > 0 AndAlso primaryHeight > 0
End Sub
๋งค๊ฐ๋ณ์ ๋ฐ ์คํ ์ค๋ช :
Main์ ๋ ๋ฆฝ๋ Dictionary์์ Item์ผ๋ก X/Y/Width/Height๋ฅผ ์ฝ๊ณ ๊ธฐ๋ณธ ๋ชจ๋ํฐ์ ๋น๊ตํฉ๋๋ค. ๊ธฐ๋ณธ ํฌ๊ธฐ๋ ์์์ด๊ณ ์ ์ฒด ๋ฐ์คํฌํฑ์ด ๋ ์์ง ์์์ผ ํฉ๋๋ค. left/top์ ์์์ผ ์ ์์ผ๋ฉฐ UO ์ด๋ ๋ช ๋ น์ผ๋ก ์ ๋ฌํ์ง ์์ต๋๋ค.
Include/Windows.bas
Option Explicit On
' Windows x64 helpers. Include "Windows.bas" from the main script.
' These declarations use the Windows ABI, not VB6 Integer/Long widths.
Module Windows
Private Declare Function NativeTicks Lib "kernel32.dll" Alias "GetTickCount"() As Integer
Private Declare Function NativeProcessId Lib "kernel32.dll" Alias "GetCurrentProcessId"() As Integer
Private Declare Function NativeMetric Lib "user32.dll" Alias "GetSystemMetrics"(ByVal index As Integer) As Integer
' Returns the current client process ID. This is not a character/item serial.
Public Function ProcessId() As Integer
Return NativeProcessId()
End Function
' Unsigned 32-bit milliseconds since Windows started, represented as Double.
' Wraps every 4294967296 ms (about 49.7 days); this is not a calendar time.
Public Function Milliseconds() As Double
Dim value As Double = NativeTicks()
If value < 0 Then
value += 4294967296.0
End If
Return value
End Function
' startMilliseconds must come from Milliseconds(). Handles one wrap only.
' Use for intervals shorter than 49.7 days; no waiting is performed here.
Public Function ElapsedMilliseconds(ByVal startMilliseconds As Double) As Double
If Not (startMilliseconds >= 0 AndAlso startMilliseconds <= 4294967295.0) Then
Throw "Windows.ElapsedMilliseconds requires a tick value in 0..4294967295."
End If
Dim elapsed As Double = Milliseconds() - startMilliseconds
If elapsed < 0 Then
elapsed += 4294967296.0
End If
Return elapsed
End Function
' Primary monitor dimensions in the process's Windows DPI coordinate space.
' These are desktop dimensions, not the UO game viewport size.
Public Function ScreenWidth() As Integer
Return NativeMetric(0)
End Function
Public Function ScreenHeight() As Integer
Return NativeMetric(1)
End Function
' Returns a new Dictionary: X, Y, Width, Height of the whole virtual desktop.
' X/Y may be negative when monitors are to the left/above the primary one.
Public Function DesktopBounds() As Object
Dim bounds = Dictionary()
bounds.Set("X", NativeMetric(76))
bounds.Set("Y", NativeMetric(77))
bounds.Set("Width", NativeMetric(78))
bounds.Set("Height", NativeMetric(79))
Return bounds
End Function
End Module
๋ด๋ถ ํจ์: ํธ์ถ๋ถํฐ ๊ฒฐ๊ณผ๊น์ง
Windows.bas๋ ํ๋ก์ธ์ค ์ ๋ณด, ์งง์ ์๊ฐ ์ธก์ , ๋ฐ์คํฌํฑ ํฌ๊ธฐ๋ฅผ ์ํ ๊ณต๊ฐ ํจ์ 6๊ฐ๋ฅผ ์ ๊ณตํ๋ ํธ์ง ๊ฐ๋ฅํ Basic ๋ชจ๋์ ๋๋ค. ์ ์ฒด ์ฝ๋์ Private Declare๋ฅผ ์๋์ ํ์ํฉ๋๋ค. Main๋ง ๋ณต์ฌํ๋ฉด ์คํ๋์ง ์์ต๋๋ค.
1. ProcessId / Milliseconds
Milliseconds()๋ ์ธ์ ์์ด 0..4294967295์ Double์ ๋ฐํํ๋ฉฐ ๋ถํธ ์๋ 32๋นํธ GetTickCount๋ฅผ ๋ํ๋ ๋๋ค. ์์์ธ ๋ค์ดํฐ๋ธ ๊ฒฐ๊ณผ์๋ 4294967296.0์ ๋ํฉ๋๋ค. ์ฝ 49.7์ผ๋ง๋ค ์ํํ๋ฉฐ ๋ฌ๋ ฅ ์๊ฐ์ด๋ ๊ณ ์ ๋ฐ ํ์ด๋จธ๊ฐ ์๋๋๋ค.
GetTickCount -> signed Integer -> if negative add 4294967296.0 -> Double
ํ๋ก์ ํธ ์์ค: src/ClassicUO.Client/Scripts/Include/Windows.bas; ํจ์ ProcessId / Milliseconds.
2. ElapsedMilliseconds
ElapsedMilliseconds(startMilliseconds)๋ ์ ์ฅํ Milliseconds() ๊ฐ์ Double๋ก ๋ฐ์ ์ง๋ ๋ฐ๋ฆฌ์ด๋ฅผ Double๋ก ๋ฐํํฉ๋๋ค. 0..4294967295 ๋ฐ์ด๋ฉด ์ค๋ฅ์ ๋๋ค. ์์ ์ฐจ์ด์ 4294967296.0์ ๋ํด ํ ๋ฒ์ ์ํ๋ง ์ฒ๋ฆฌํฉ๋๋ค. ์ธก์ ์ ํ ์ฃผ๊ธฐ๋ณด๋ค ์งง์์ผ ํ๋ฉฐ ํจ์ ์์ฒด๋ ๊ธฐ๋ค๋ฆฌ์ง ์์ต๋๋ค.
validate start -> now - start -> if negative add one wrap -> Double
ํ๋ก์ ํธ ์์ค: src/ClassicUO.Client/Scripts/Include/Windows.bas; ํจ์ ElapsedMilliseconds.
3. ScreenWidth / ScreenHeight / DesktopBounds
DesktopBounds()๋ ๋ฌธ์์ด ํค X, Y, Width, Height์ Integer ๊ฐ์ ๊ฐ์ง ์ Dictionary๋ฅผ ๋ฐํํฉ๋๋ค. Item("X") ๋ฑ์ผ๋ก ์ฝ์ต๋๋ค. ๋ฉํธ๋ฆญ 76~79๋ ๋ชจ๋ ๋ชจ๋ํฐ๋ฅผ ๋๋ฌ์ผ ์ฌ๊ฐํ์ด๋ฉฐ X/Y๋ ์์์ผ ์ ์์ต๋๋ค. ์ฌ์ ์์ ์ ์ฐฝ์ ์ด๋ํ๊ฑฐ๋ ํฌ๊ธฐ๋ฅผ ๋ฐ๊พธ์ง ์์ต๋๋ค.
metrics 0, 1: primary; 76, 77, 78, 79: desktop X, Y, Width, Height
ํ๋ก์ ํธ ์์ค: src/ClassicUO.Client/Scripts/Include/Windows.bas; ํจ์ ScreenWidth / ScreenHeight / DesktopBounds.
ID์ ํ๋ฉด ํฌ๊ธฐ๋ Integer ์๋, ์๊ฐ์ Double ๋ฐ๋ฆฌ์ด๋ก Boolean์ด ์๋๋๋ค. DesktopBounds๋ Integer ๊ฐ์ ๊ฐ์ง Object(Dictionary)์ ๋๋ค. Include์ ์ ์ธ์๋ ๊ฒฐ๊ณผ๊ฐ ์์ต๋๋ค. ๊ฐ ์์ Main์ ๋ฐ์ดํฐ ๊ฒ์ฌ ์ฑ๊ณต ์ 1/True, ์คํจ ์ 0/False๋ฅผ ๋ฐํํ๋ฉฐ ๋ชจ๋ ๋ค์ดํฐ๋ธ ์ซ์๊ฐ ์ฑ๊ณต ํ๋๊ทธ๋ผ๋ ๋ป์ ์๋๋๋ค.