Jump to content

IIYAMA

Moderators
  • Posts

    6,063
  • Joined

  • Last visited

  • Days Won

    208

Everything posted by IIYAMA

  1. IIYAMA

    Toggle Warp

    I was nice in the beginning, But it looks like, you aren't willing to learn it on your self. In fact you don't even try to learn anything. The only thing you care about is having it as you want and skipping the learning part. That isn't going to work. I just did post the basic pages, really nice samples and easy to understand. You should start there and don't act like a kid that isn't old enough to learn. DO I MAKE MY SELF CLEAR? GOOD LUCK! and of course you can ask me anything that has related to scripting, as long it is a specific lua question and not about pathetic resources.
  2. Then you should not asking here on the scripting section. --> viewforum.php?f=108 shadow's are something from mta san, you can put them on and off in the main menu. Not sure if you can remove them with shaders.
  3. He must have because else it would start giving an error instead of a warning. ERROR: attempt to index a nil value. (title: Re: table index is nil) As far I know it is the same. runningStreaks[player].x runningStreaks[player]["x"] But I prefer ["x"]. When I use table.x, I always get confused that x is a not defined value.
  4. function triggerSwarm( player ) if not runningStreaks[player] then runningStreaks[player] = {} -- make it a table end runningStreaks[player]["name"] = getPlayerFromName (player ) -- insert name runningStreaks[player].x, runningStreaks[player].y, runningStreaks[player].z = getElementPosition ( runningStreaks[player] ) -- insert pos end
  5. It depends what you want to make. Be more specific. You mean something like this? addEvent("myEvent",true) addEventHandler("myEvent",root, function (x,y,z) if isElement(source) then -- make sure the player does still exist before the data reached the server. setElementPosition (source,x,y,z) end end)
  6. @Minotaur I did warn you about me reporting spam/begging topic's. https://forum.multitheftauto.com/viewtopic.php?f=91&t=60987 This one should be locked.
  7. Can't you read? other mistake script is starting? /debugscript 3 else show your meta.
  8. well as far I can see it have to work. You sure the sound is there?(and in the sound/ folder) I only see one other mistake(it is client not serverside): function lobby(player) Must be: function lobby(command) -- string commandName, [string arg1, string arg2, ...]
  9. @John. doesn't take any argument which would tell it who can see the nametag and who can not. SetPlayerNametagShowing at client side isn't synced and that is a good thing, so it is possible but only at client side.
  10. try this: (explosion will be created at the marker) SERVER local myMarker = createMarker(-3686, 1600.8000488281, 8.39, 'cylinder', 5, 255, 0, 0, 150) -- create myMarker function fakeBomb(element,d) if d then local x,y,z = getElementPosition(source) -- source = marker createExplosion(x, y, z, 0) end end addEventHandler( "onMarkerHit", myMarker, fakeBomb ) OR client -- for client side: "onClientMarkerHit" local myMarker = createMarker(-3686, 1600.8000488281, 8.39, 'cylinder', 5, 255, 0, 0, 150) -- create myMarker function fakeBomb(element,d) if d then local x,y,z = getElementPosition(source) -- source = marker createExplosion(x, y, z, 0, true, -1.0, false) end end addEventHandler( "onClientMarkerHit", myMarker, fakeBomb )
  11. You haven't wrote down a single line of code. So no, I won't make it for you. nobody will, unless you pay them. If you are going to beg players, to make it for you. I simply report the topic for closing.
  12. IIYAMA

    Toggle Warp

    and i put it this to fr_client so:* yes, but replaced it with the old functions. (else it probably going to be bugged) Minotaur, first learn the basic. You can say at every topic that you are a "noob scripter", but that isn't help you to learn it. You will always having the same problems and for 60% they are able to help you. But most of the time big resources get bugged after adding stuff. Simply because you change the system. You can start with some basic stuff, most of that you can find here: Client Scripting: https://wiki.multitheftauto.com/wiki/Cl ... _Functions https://wiki.multitheftauto.com/wiki/Cl ... ing_Events Server scripting: https://wiki.multitheftauto.com/wiki/Se ... _Functions https://wiki.multitheftauto.com/wiki/Se ... ing_Events
  13. math.random(1,255) ................................... tocolor (math.random(1,255),math.random(1,255),math.random(1,255))
  14. IIYAMA

    Toggle Warp

    maybe because you created something that isn't at the right place. and it is missing an "end" function warpTo(leaf) if not leaf then leaf = getSelectedGridListLeaf(wndWarp, 'playerlist') if not leaf then return end end local player = getPlayerFromNick(leaf.name) if player then if getElementData(player,"warp.status") then outputChatBox ( "This player has disabled warping.", player, 255, 0, 0 ) return end -- added server.warpMe(player) end closeWindow(wndWarp) end function warpToCommand(cmd, player) if player then player = getPlayerFromNick(player) if player then if getElementData(player,"warp.status") then outputChatBox ( "This player has disabled warping.", player, 255, 0, 0 ) return end --added server.warpMe(player) end else createWindow(wndWarp) showCursor(true) end end addCommandHandler('warpto', warpToCommand) addCommandHandler('wt', warpToCommand)
  15. or when you wrote it a lot of times on your script. (like 10 times etc.) Also possible, but not recommended. hiddenSpawn = {[0]=1093, -358, 74, 0}
  16. IIYAMA

    Toggle Warp

    Where is your code?
  17. https://wiki.multitheftauto.com/wiki/Sl ... setBotWait
  18. https://wiki.multitheftauto.com/wiki/Se ... tagShowing you have to make it your self,
  19. pictures aren't vectors, You can't scale or force them to a new resolution without making it ugly. (more then 20% scaling becomes unusable in the graphical industrial) btw:
  20. afk means that you don't play..... so he will kill you till you aren't afk. I never used that command, maybe you have to write it double to disable it.
  21. you sure the field does exist? Well this is happening: playerListLabels[1]= nil -- the problem. playerListLabels[1][4] -- cause the error. ------ to solve the error, but preventing it always better. if playerListLabels[1] --[[and isElement(playerListLabels[1][4])]] then guiSetText( playerListLabels[1][4], "woo" ) end I have no idea why it doesn't exist. It is probably is happing in another part. Can cause this: maxPlayersInCurList is nil/0
  22. Also possible. Maybe you have to learn lua a little bit more. We are here to help you, not to make it for you. Take a better look at the wiki mta samples. function A () end addEventHandler("onClientResourceStart",resourceRoot, function () setTimer (A,5000,1) --5000 = 5 seconds, 1 = one time executed. --add static image here end)
  23. Well the zombies get synced by the players. That means that every player sends information to the server about the closes zombies. If the player have lagg, the zombie that is synced by him also starts to lagg. With lagg I mean, low fps and high ping. Peds require much more bandwidth. What is the global ping in your server? If this is higher then 200, you probably have lagging bots. Not much you can do about it, the only thing you can do is paying for a closer host.
  24. addEventHandler("onClientResourceStart",resourceRoot, function () end) https://wiki.multitheftauto.com/wiki/DxDrawImage https://wiki.multitheftauto.com/wiki/OnClientRender https://wiki.multitheftauto.com/wiki/SetTimer or https://wiki.multitheftauto.com/wiki/GetTickCount
×
×
  • Create New...