Jump to content

Callum

MTA Contributors
  • Posts

    865
  • Joined

  • Last visited

Everything posted by Callum

  1. To place something in the middle of the screen I usually do something like; local resX,resY = guiGetScreenSize() guiCreateWindow(resX/10*4,resY/10*3.5,resX/10*2,resY/10*3,"A window",false)
  2. What about toggleControl? You can set fire and aim_weapon to false.
  3. Callum

    [REL] InfoGUI

    Download Click here! Introduction I noticed the helpmanager resource was very awkward as it only made 1 tab per resource with a help.xml and was quite a long client-side code, so I tried making my own shorter, and more flexible version of it. The result is quite good, it's only a short client-side file plus the xml files you add. And it's quite easy to add new tabs/text. How to use 1. Add an XML file inside the infoGUI resource (it can be called whatever you like). 2. Go into meta.xml and insert a line as follows (where nameHere.xml = your file name); 3. Go into info-client.lua and at the root of the script you will see a table, insert at the end the following; "nameHere.xml;tabName" - of coruse nameHere.xml is the XML file, use a ; to seperate it, and then what you wish to name the tab. 4. Go into the XML file, and put at the root of the script a node, e.g.; 5. In between the nodes type your text. If you still don't understand the resource comes with rules.xml and commands.xml as an example.
  4. Callum

    Radio Bug

    It's not a "bug", it's part of GTA's engine. If you notice, this occurs in any of the GTA III era games. It's actually quite useful in-case you just want to skip the song, I think that's the whole idea Rockstar Games added it.
  5. Callum

    DD/DM WIN

    That event is not being triggered (I presume) so the function won't ever do anything. onPlayerWasted you could check how many players remain alive, if 1, then triggerEvent("onPlayerDestructionDerbyWin",winner,winner) (or the client-side equivalent).
  6. After line 14 insert a new line and add "end".
  7. To make it work with zombies use what you've done with players on peds also, but the zombie script will probably ignore the green zone's effect.
  8. There should be a removeGTAObject(objectID) and every GTA SA object has a unique ID.
  9. Callum

    ??

    Read it again, that's the most in-depth and detailed version of a how-to you could possibly get.
  10. "This video has been removed by the user."
  11. Presuming you have a ped defined as "ped", the script below should work (client-side): function invPed() cancelEvent() end addEventHandler("onClientPedDamage",ped,invPed)
  12. Do you get any errors? Check by typing "/debugscript 3" in-game. Also, on the event handler I recommend you change getRootElement() to getResourceRootElement()
  13. Callum

    coordinates

    local x,y,z = getElementPosition(theObject) Replace theObject with your objects variable. Or just try checking in a .map file for it, if it already exists at start.
  14. Yes, like JBoy said, type /debugscript 3, then tell us what error it returns.
  15. So this can't be publicly released for what reason? Would it allow people to make a work-around or something?
  16. In the meta.xml shouldn't have a type arg. It should only have an src arg. So
  17. Callum

    Gang zones

    Please understand that you can't just ask for a script to be made for you, don't you think we have better things to do in our time? You'll have to do it yourself, we can help you with some parts of it, but we won't do it for you. Refer to the wiki for more information on scripts and scripting.
  18. Callum

    Markers

    local blueMarker = createMarker ( 4000, -460, 25, "corona", 3, 0, 0, 255, 255 ) local redMarker = createMarker ( 4040, -460, 25, "corona", 3, 255, 0, 0, 255 ) function onHit(hitElement) if (source == blueMarker) then setPedGravity(hitElement,0.008) end if (source == redMarker) then setPedGravity(hitElement,0.004) end end addEventHandler("onMarkerHit",getRootElement(),onHit)
  19. wtf you on about? place the house really high.
  20. There is nothing wrong with peds at 0,0,0, it must be your script. But as a player spawns for a split-second they are located at 0,0,0.Try turning off every resource exept admin, runcode, and play. EDIT: Mr.Hankey beat me to it
  21. Are you still running it as administrator because if "memory could not be read" it sounds like the kind of thing that requires administrative rights.
  22. Callum

    car slots

    Well what exactly isn't happening. You can't just give us a whole script to look through and diagnose all on our own. You could help us a bit with it.
  23. Like Tim said, read the wiki (link on his post). If you don't get it, read it again! And you can't expect to get it right first time, Do some trial and error. Everybody has this problem with starting to learn lua, you've got to get used to it before things start working.
×
×
  • Create New...