StealthBot.net: gamespam - StealthBot.net

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

gamespam gamespam

#1 User is offline   ytdulu Icon

  • Newbie
  • Pip
  • Group: Members
  • Posts: 2
  • Joined: August-18 10

Posted September 22, 2010 - 07:19 PM

Hello,

Im using gamespam script:

Script("Name") = "gamespam"
Script("Author") = "Style"
Script("Major") = 1
Script("Minor") = 2
Script("Revision") = 3
Script("Description") = "announces games"

'v1.23
'multible bot support

'v1.2
'added getgames command
'added message if the hosthot is offline

'v1.1
'delayed announcement by 15sec

'//Important
'//The User has to be mutal friend with the Bot

Private Const Hostbot_name = "Hiden"       '//put your bot's username here
Private Const Hostbot_trigger = "!"                '//put your bot's trigger here
Private check_running
Private is_new_game
Private last_host

Sub Event_Load()
   
   Dim Command, Parameter
   
   Set Command = OpenCommand("getgames")
   If Command Is Nothing Then
      Set Command = CreateCommand("getgames")
      With Command
         .RequiredRank = 60
                        .Description = "retrieves the gamename and available slots for a running game"
         Set Parameter = .NewParameter("BotName", False, "Word")
                        With Parameter
                                .Description = "the Bot's name"
                        End With
                        .Parameters.Add Parameter
         .Save
      End With
   End If
   Set Command = Nothing
   
   check_running = false
   is_new_game = false
   
   Call CreateObj("LongTimer", "slotCheck")
   slotCheck.Interval = 15
   slotCheck.Enabled = False
   
End Sub

Sub Event_Command(Command)
   If lcase(Command.Name) = "getgames" then
      botnames = split(Hostbot_name,",")
      if LenB(Command.Args) > 0 then
         For i = 0 to UBound(botnames)
            if lcase(Command.Args) = lcase(botnames(i)) then 
               AddQ "/w " & botnames(i) & " " & Hostbot_trigger & "getgames"
               check_running = true
               Exit Sub
            End If
         next
         AddQ "Please enter a valid botname"
      else
         AddQ "/w " & last_host & " " & Hostbot_trigger & "getgames"
         check_running = true
      end if
   End If
End Sub

Sub Event_ServerError(Message)
   if check_running then
      if Message = "That user is not logged on." then
         check_running = false
         AddQ "That hostbot not online"
      End If
   End If
End sub


Sub Event_WhisperFromUser(Username, Flags, Message, Ping)
   botnames = split(Hostbot_name,",")
   For i = 0 to UBound(botnames)
      If lcase(Username) = lcase(botnames(i)) then
         If left(lcase(message),60) = left(lcase("Your friend " & Username & " entered a Warcraft III The Frozen Throne game called "),60) then
            last_host = Username
            slotCheck.Enabled = True
         end If
         if check_running then
            if instr(Message, "There is no game in the lobby") > 0 then
               AddQ "ERROR: " & Username & " is online, but there is no game in the lobby at the moment! Please try again later!"
            elseif instr(Message, "is in the lobby") > 0 then
               gamename = split(split(Message,"[",2)(1)," : ",2)(0)
               slots = split(Message, " : ")(2)
               if is_new_game then
                  AddQ "Clan ETU Game <= (" & slots & ")=> " & gamename
                  is_new_game = false
               else
                  AddQ "CLan Extilume Game <= (" & slots & ")=> " & gamename
               end If
            end If
            check_running = false
         end If
      End If
   next
End Sub

Sub slotCheck_Timer()
   AddQ "/w " & last_host & " " & Hostbot_trigger & "getgames"
   check_running = true
   is_new_game = true
   slotCheck.Enabled = False
End Sub


And the problem is that it only spams one time. I want what it keep spamming then the game hosted and turn off then the game started. Continue on spamming then again hosting.

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users