Jump to content

stupid error


toxicsmoke11

Recommended Posts

Posted

hello im trying to make a script but mta hates me and doesnt want to load it

paidVehicles = { 
{"Infernus",411,50000} 
} 
  
function buyVehicle(thePlayer,commandName,theVehicle) 
   if getPlayerMoney(thePlayer) >= 50000 then 
      for i,pvehicles in ipairs(paidVehicles) do 
         if string.find(pvehicles[2],tostring(theVehicle)) then 
            outputChatBox("You bought: #FF0033"..tostring(pvehicles[1]),thePlayer,255,255,255,true) 
            local px,py,pz = getElementPosition(thePlayer) 
            createVehicle(tonumber(theVehicle),px,py,pz) 
        else outputChatBox("#FFFFFF"..tostring(theVehicle).."#FF0000 did not find any match in the vehicle shop.",thePlayer,255,0,true) end 
      end 
   else outputChatBox("#FF0000You need #FFFFFF 50000$ #FF0000 in order to buy a vehicle!",thePlayer,255,0,true) end 
end 
addCommandHandler("buyvehicle",buyVehicle) 

when i use /buyvehicle 411 then i get message "nil did not find any match in the vehicle shop."

also you might wonder why i got only 2 number arguments in outputChatBox,well the reason is

that mta is talking crap and not allowing me to script because its just evil little shit

before i have used

else outputChatBox("#FF0000You need #FFFFFF 50000$ #FF0000 in order to buy a vehicle!",thePlayer,255,0,0,true) end 

but stupid mta said that fifth argument (number 0) must be a fucking boolean which doesnt make any sense

does anyone know a solution to this ridicilous madness made by mta?

  • Moderators
Posted
no i dont want to have that then i would get an ugly colored text

i had to restart my server to fix this issue,im dissapointed by mta

lol, restart the server, mta is disappointed in you.

Posted
no i dont want to have that then i would get an ugly colored text

i had to restart my server to fix this issue,im dissapointed by mta

lol, restart the server, mta is disappointed in you.

it's not my fault that mta developers aren't fixing this kind of ridiculous bugs.

  • Moderators
Posted

refresh

Refresh resource list to find new resources

refreshall

Refresh resources and restart any changed resources

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...