⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 declares.bas

📁 VB编的小游戏
💻 BAS
字号:
Attribute VB_Name = "Declares"
Public Declare Function SleepEx Lib "kernel32" (ByVal dwMilliseconds As Long, ByVal bAlertable As Long) As Long
Private Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long

Const SND_SYNC = &H0
Const SND_ASYNC = &H1
Const SND_NODEFAULT = &H2
Const SND_LOOP = &H8
Const SND_NOSTOP = &H10
Public Type Game
    Playerss As Byte
    P1_Name As String
    P2_Name As String
    P1_Score As Double
    P2_Score As Double
    Curplayer As Byte
    CurrentChoice1 As Byte
    CurrentChoice2 As Byte
    FirstChoice As Integer
    SecondChoice As Integer
End Type

Public MyGame As Game
Public Sounds As Byte
Public Level As Byte
Public Players As Integer
Public Animation As Boolean
Public MainPath As String
Public SoundPath As String
Public Chrsep As String
Public Score As Long
Public Reveal As Byte
Public p2gametype As Byte

Public doigetGood As Integer
Public vaval As Integer
Public iv As Integer
Public pp As Boolean
Public op As String
Public vvv As Integer
Public eog As Integer
Public ef As Boolean
Public vvv1 As Integer
Public selcard As Integer

Public skill As Byte
Public skl As String
Public TTL As String
Public GameInProgress As Boolean
Public Paused As Boolean
Public ShowTabs As Boolean

Public Const NormWidth = 8175
Public Const NormHeight = 5910
Public Const ChatHeight = 7000
Public Const ChatWidth = 8175

Public Sub PlaySound(File As String)
    Flg = SND_ASYNC
    sndPlaySound File, Flg
End Sub


Public Function Parse(ByVal strString As String, lItemNum As Long) As String

    Dim arrItems() As String
    lItemNum = lItemNum - 1
    arrItems = Split(strString, Chrsep, , vbTextCompare)
    If lItemNum <= UBound(arrItems) Then
        Parse = arrItems(lItemNum)
    End If
    Erase arrItems
End Function

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -