• Content Count

  • Joined

  • Last visited

  • Days Won


WorthlessCynomys last won the day on November 12 2017

WorthlessCynomys had the most liked content!

Community Reputation

74 Popular

About WorthlessCynomys

  • Rank


  • Gang
  • Location
    A barely known country in the middle of Europe
  • Occupation
  • Interests
    Mostly, helping people here and making scripts. Also video games and girls.

Recent Profile Visitors

1,479 profile views
  1. Hy! You have to put the dx functions in an onClientRender event. dx draws only live for a frame, therefor you have to draw them on every frame. That's what the onClientRender event does. If you need further help, send me a PM and I'll help in hungarian.
  2. Hy. Try: #getPedWeapons On number indexed tables/arrays # returns the count of values in an array.
  3. Hy! It is probably a custom function. startRollMessage is not a default MTA function. If it is used in that form, then It's definition must be in the same resource in a file that is either shared or client sided.
  4. Hali! Legközelebb használd a code beszúrást (<> jel fent). local sound1 = playSound3D("abc.mp3",1871.4547119141, -1372.5979003906, 16.135135650635, true) setSoundVolume(sound1, 30.0) setSoundSpeed(sound1, 1.0) setSoundMaxDistance (sound1, 700) setElementDimension( sound1, 0 ) setElementInterior( sound1 , 0 ) local sound2 = playSound3D("abc.mp3",1887.8804931641, -1372.5979003906, 16.135135650635, true) setSoundVolume(sound2, 30.0) setSoundSpeed(sound2, 1.0) setSoundMaxDistance (sound2, 700) setElementDimension( sound2, 0 ) setElementInterior( sound2 , 0 ) Na de a problémádra a megoldás, hogy le tudod kérdezni a hangnak a jelenlegi időpontját, hogy hol tart. Így össze tudod hangolni a hangokat. getSoundPosition() setSoundPosition()
  5. I do not understand what you want to achieve. Please provide further explanation of your goal so I/others can understand It and become able to help you!
  6. setElementData() getElementData() You should set the element data of the vehicle and chech that. Like: setElementData(veh, "trunkTires" 1); -- later local tires = getElementData(veh, "trunkTires"); if tires > 0 then setElementData(veh, "trunkTires", tires-1); -- Your get the tire from trunk code else -- No tire in car, handle that too end
  7. @ChrisT Ez nem egy script kéregető részleg. Be van kapcsolva a debugscript 3 és úgy nincs hiba? Ha ide rakod code mezőbe (<> ikon) a scripted, akkor esetleg tudunk segíteni. Nem fogunk neked adni egy teljesen másik új scriptet, de segítünk megírni ha meg akarod tanulni a scriptelést...
  8. You were helpful AF, bro Keep up the good work! @Hugos Use the getElementSpeed function from WIKI to get the current speed. It works quite well. For the arrow of the speedometer: You know that the speedo can show 260 max. You know the degree for the 0 on the speedo and the degree for 260. Now you can divide the current speed of the vehicle by 260 and then you get the relative number to multiply the degrees with. So like: local arrowRotation = 0; -- This will be the actual rotation of the arrow. local vehicleSpeed = 180; -- This will serve as the current speed of your vehicle. You get this with getElementSpeed local speedoMaxSpeed = 260; local degreesFromZeroToMax = 180; -- This is the degrees between 0 and 260 for example arrowRotation = (vehicleSpeed/speedoMaxSpeed)*degreesFromZeroToMax; I hope it works. It's been a long time since I made something like this. About dx. Yup! You HAVE to use dx for this.
  9. Erre vannak jobb, dx-es megoldások. De ha ragaszkodsz ehhez, akkor a kirajzolásnál vágd meg a stringet a megfelelő karakterszámra.
  10. Ezzel mit szeretnél elérni? Mit akarsz megvalósítani?
  11. There's two basic solutions for this problem. You either check the position of the player, GTA map is 6000x6000 which means that it's from -3000 to 3000 on both axis. OR You create a map sized colShape and add an event handler to check if the player exits it. That's the worse solution in my opinion.
  12. Hali! Az a helyzet, hogy ez nem egy ilyen írd le egy szövegben dolog. Itt a fórumon rengeteg eligazító téma van. Ha tudsz angolul, akkor szintén az angol fórumon nagyon sokat meg lehet tudni, illetve a WIKI nagyon hasznos. Odáig kell eljutnod, hogy létre tudsz hozni és elindítani egy scriptet. Utána már csak végtelen bohóckodás.
  13. local screenW,screenH = guiGetScreenSize() local resW,resH = 1366,768 local x,y = (screenW/resW), (screenH/resH) local font = dxCreateFont("fonts/font.ttf", 10) local MaxFuel = 100 function getVehicleFuel(v) local fuel = getElementData(v, "fuel") if (fuel) then return fuel end return 0 end addCommandHandler("fueladm",fuel) Hello! You can insert code blocks with the <> sign. Use it next time. Your problem is that this code does not set any value. In order to set the "amount of fuel" you have to use setElementData to set the value for fuel. Also functions can get parameters/arguments from command calls. You can catch those arguments in the paramter list after the function's name. -- Catch parameters of command call -- On server-side function funcName(player, command, value1, value2) end addCommandHandler("testCall", funcName) -- When you type /testCall it will call the funcName function, providing the calling player, the command that has been used for the call, and additional values typed in alongside the command. In command calls, additional values are seperated with spaces. For example: /testCall value1 value2 -- On client-side function funcName(command, value1, value2) end addCommandHandler("testCall", funcName) -- The same playbook here, except that client-side calls do not provide the calling player, because it is obvious that the calling player is the client itself. The localPlayer. Now your function should look somehow like this: -- Client-side function setVehFuel(cmd, fuel) local veh = getPedOccupiedVehicle(localPlayer); -- Gets the currently occupied vehicle of the player, returns false if the player is not in a vehicle. if (veh) then -- Translates to if (veh ~= false/nil) then setElementData(veh, "fuel", tonumber(fuel)); -- Sets the fuel element data of the vehicle to the value that the caller provided converted into a number from string. end end addCommandHandler("setFuel", setVehFuel);