Jump to content

50p

Retired Staff
  • Posts

    2,973
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by 50p

  1. Remember! If you want to save an image and its transparency you'll need to save it as a .png.
  2. 50p

    Commands

    So how come I can't start resource until I create zip file of the resource?! I have got folder of my resource in resourcecache and I try to start resource, what I get back is: How can you explain that? Is there some setting in mtaserver.conf which is responsible for that? I guess no, so...?
  3. Parameters for functions are: - oldnick - newnick and source returned is the player who changed his nick. This is not a function! This is an Event! The way function works is different to the way event works. Function gets attached to event.
  4. Jeeeez function spawnThePlayer ( player ) local spawnset = randInt( 1, #spawnPositions ) spawnPlayer ( player, spawnPositions[spawnset].posX+randInt(1,5), spawnPositions[spawnset].posY+randInt(5,9), spawnPositions[spawnset].posZ, spawnPositions[spawnset].rotation, randInt(9,288) ) fadeCamera( player, true ) end
  5. addEventHandler( "onClientResourceStart", g_root, function ( ) timerID = setTimer( g_root, 1000, 0, function ( ) if isPlayerInVehicle( g_Player ) then showSpeedometer() killTimer ( timerID ) end end ) end )
  6. There where you spawnPlayer, so you spawn player and show him the "world".
  7. 50p

    Money scripting

    You'll always have 0 until you give yourself money. It saves you money to the bank instead of giving you the money from bank.
  8. Kinda... Try this: timerID = setTimer( g_root, 1000, 0, function ( ) if isPlayerInVehicle( g_Player ) then showSpeedometer() killTimer ( timerID ) end end ) Replace code in onClientResourceStart with this above.
  9. And don't forget that random value can be the same even 100 times one after another, since there are only 2 values that randInt can choose from, so be patient and try killing yourself more times.
  10. 1st question: Try to change image's properties in Flash library: - tick Allow smoothing - change compression: Lossless (PNG/GIF) May help. 2nd question: Make a function which will be called by a timer. The function should check if the client is in a vehicle. If he is then showSpeedometer and kill the timer. In updateTheSpeed function (on the line where hideSpeedometer is) add the same timer. That should work.
  11. 50p

    Player Map Math

    If you still haven't got the formula then here is a LUA function: function convertWorldXYToMapXY( x, y, imageSize_x, imageSize_y ) return ((x*512)/6000)+(imageSize_x/2), ((-1*y*512)/6000)+(imageSize_y/2) end returns: converted x and y of the "game's world" coords to map's image coords PS. the conversion "stolen" from Xtream's Vehicle Map Plotter
  12. 50p

    Player Map Math

    There is a formula which gives you the value for the "world" position. If nobody will give you that in time I won't be here I'll post it in the evening (I'm going to work now).
  13. Try to open .col file (which you created) with CollEditor (also available on gtaforums.com) and see if collision exist. If 'Skip Col' doesn't help, try to export the object mesh to .col and then attach it to dff while exporting to .dff. I tried with a simple box and it works, but couldn't load the textures. I've posted about it somewhere in other topic.
  14. I made a needle in Photoshop and animated it in Flash 8, then exported every frame. Quickly and simply.
  15. lol'd That is weird I know, but I was asleep when I was exporting every single image manually, it took me 3 hours, LOL. The next day I was fresh minded and then it took me only 30 mins with all of the images exported using other method (automatic)! I skipped it in the meta.xml and in the code, maybe because it's a special number, ROFL.
  16. I have posted that I missed it because I've been exporting the images 1 by 1 manually. https://community.multitheftauto.com/index.php?p= ... tails&id=5
  17. I thought of adding such features before, but I didn't have much time so I couldn't do anything. I will script those or some of those features as soon as I'll have some time, probably on Thursday.
  18. DazzaJay, as I previously said: If there was a function like guiRotate or guiSetRotation I'd use them.
  19. I'll re-make the speedometer as soon as we'll be able to use that function.
  20. Is this what you want? You can set it to true whenever you want. When you change it to false it will simply disappear. I don't actually get your question.
  21. 50p

    xmlCreateFile

    2nd argument must me a string! So try this: xmlNodeSetValue ( bank, "0" )
  22. Try to use getRootElement() as the 2nd param. I used it and it worked for me.
  23. Don't use onClientClick, use onClientGUIClick instead.
  24. Re-enter the vehicle. Probably you started the speedo when you were in a vehicle.
  25. Have you placed the .zip in your server's "resources" folder? Make sure to "refresh" your resources if the resource was installed while server was running. Just type "refresh" in the console (no quotation marks), you must be logged in as an admin. Then try to "start speedo_disc" again.
×
×
  • Create New...