On the tail end of the code with this new amendment; changing the MsgBox to a Send outputs a loop break where it repeats (3030303030303030303030303030303030). It reads: "/taxi accept 103". I tried to change what it reads to 295 and it's fine.
#SingleInstance, Force
SetBatchLines, -1
file = C:\Users\Joe\Documents\GTA San Andreas User Files\SAMP\chatlog.txt ; Replace with path to your chatlog.
return
GetLastNumber() {
global file
Loop, Read, %file%
{
Loop, Parse, A_LoopReadLine, `n
{
if RegExMatch(A_LoopField, "\d{1,}(?= )", i)
{
ret := i
}
}
}
return ret
}
1::
Send, % GetLastNumber()
return
!1::
rand = 0
random, rand, 1, 2
{
if(rand == 1)
{
Send t/me looks and acts to be of Indian decent.{enter}
return
}
if(rand == 2)
{
Send t/me vaguely looks and speaks like an Indian.{enter}
return
}
return
}
!E::
{
Send t/engine{enter}
return
}
!K::
{
Send t/lock{enter}
return
}
!home::
{
Send t/enter{enter}
return
}
!end::
{
Send t/exit{enter}
return
}
!L::
{
Send t/v lights{enter}
return
}
!M::
{
Send t/do There is a plexiglass barrier dividing the front and back seat. There is a slot to put money through.{enter}
return
}
-----------------
!=::
rand = 0
random, rand, 1, 2
{
if(rand == 1)
{
Send t/do The light on top of the taxi is on indicating that the cabbie is available.{enter}
return
}
if(rand == 2)
{
Send t/do The taxi topper on top the taxi is on indicating the cabbie is available.{enter}
return
}
return
}
-----------------
!-::
rand = 0
random, rand, 1, 2
{
if(rand == 1)
{
Send t/do The light on top of the taxi is off indicating that the cabbie is unavailable.{enter}
return
}
if(rand == 2)
{
Send t/do The taxi topper on top the taxi is off indicating the cabbie is unavailable.{enter}
return
}
return
}
-----------------
!C::
{
Send t/opentoll{enter}
return
}