-
Posts
563 -
Joined
-
Last visited
Posts posted by Perfect
-
-
Resource :- https://community.multitheftauto.com/ind ... ls&id=9253
Reason:-
1) They are many resource like the above one.
2) They are also resources which are way better than the above one.
-
Any good example for call remote function ? I can't understand the wiki one.
And Really, There is no way to know if server is on or off ?
-
Hello, I am trying to make an Script, Which will redirect Players to My friend server with command /ServerP And /ServerV.
Their servers are local servers (including mine), So when Their servers are off the command should output 'Servername Off'.
Is there is anyway to detect When Servers are 'On' Or 'Off' ?
Here is Script:-
(This Is script which i just modified a bit right now. Not tested but i am sure it will not work)
function Servers (cmd) if (cmd == 'Serverp') then redirectPlayer (source, "1xxx.xxx.xx.xx",22003 ) elseif (cmd == 'ServerV') then redirectPlayer (source, "xxx.xxx.xx.xx",22003 ) end end addCommandHandler (cmd, Servers)
Also how can i output a Message 'Connect from Server K'' in friend server.
Can You Guys Please Help Me ?
-
Oh btw sprinting now is nothing, but i didn't get something whats the problem with it ? we players enjoyed it so why ruining the fun by lowering it ? its really a shameThank god it's finally prevented.. I hated those cheaters who 'coincidently' run faster than everyone.
That what made newbies with no skills win the game, if so what's the point of playing ? without a goal ? i used to play daily to learn new skills that what makes people play the game for hours, plus since everyone can run faster by pressing space too much times why disabling ? it isn't even a unfair feature, honestly updates used to promote the game but you guys are demoting it, with respect i suggest re-adding it,
Kind regards Rounder.
1) Still Many Players don't know that and can confuse it with Hack/Cheat,
Which can decrease the reputation/Population of the Server (Including MTA Sa).
2) Its really in Server Owner's View. (Perspective )
3) MTA Sa Always try to Promote gta sa and Almost always succeed in doing it.
4) And the main problem is Auto-Spammer Bot, Which can be program to press spacebar for every 5 mili-seconds.
5) If its disable in One of your favorite Server. You can ask the owner for it.
And Most likely, The answer would be 'NO'.
-
Try this, Didn't Test.
function Buy() local veh = getPedOccupiedVehicle(localPlayer) local id = getElementModel(veh) setVehicleOverrideLights ( veh, 2 ) if ( not isTimer(timer)) then timer = setTimer( function() setVehicleLightState ( veh, 1, 0) setVehicleLightState ( veh, 2, 0) setVehicleLightState ( veh, 0, 1) setVehicleLightState ( veh, 3, 1) setVehicleHeadLightColor(veh, 0, 0, 255) else setVehicleLightState ( veh, 3, 0) setVehicleLightState ( veh, 0, 0) setVehicleLightState ( veh, 1, 1) setVehicleLightState ( veh, 2, 1) setVehicleHeadLightColor(veh, 255, 0, 0) end, 500, 0) else killTimer(timer) setVehicleLightState ( veh, 0, 0) setVehicleLightState ( veh, 1, 0) setVehicleLightState ( veh, 2, 0) setVehicleLightState ( veh, 3, 0) setVehicleHeadLightColor(veh, 255, 255, 255) setVehicleOverrideLights ( veh, 1 ) end end addEvent("P",true) addEventHandler("P", root, Buy)
-
Great but the wiki is not clear... On the wiki it says: "fastsprint - Stop speed advantage by tapping sprint button". So if you set it to true (enable glitch) it will stop the advantage? Because glitches are disabled by default and the description suggests that by enabling it you will stop it.
Well, It is.
It Says :- fastsprint - Stop 'speed advantage by tapping sprint button'
Which means 'Stop the advantage of speeding, which can be activated by pressing Sprint Key(Button)'
It has little confusion and is hard to understand at first for some players because of no use of commas But you can get it with little common sense. (But still, It should be more clear)
-
Thank You So Much, Tosfera And TAPL!
-
Oh, I didn't know that there is something like table.remove exist.
I just have to put
table.remove(vehicles[myPlayer][1])
in replace of table.sort ?
And Every other thing is fine ?
-
Hello, I was trying to make players can only spawn 5 vehicles and If they spawned the 6th one.
Then the 1st will get destroy and The Table will reset.
Here is my Script:-
vehicles = { } function spawnVehicle ( myPlayer ) if ( not vehicles[myPlayer] ) then vehicles[myPlayer] = {} end local x,y,z = getElementPosition ( myPlayer ) local car = createVehicle ( 560, x, y, z ) table.insert(vehicles[myPlayer],car) for k,v in pairs(vehicles[myPlayer] do if (#vehicles[myPlayer] >= 5) then destroyElement(vehicles[myPlayer][1]) table.sort[k] else warpPedIntoVehicle ( myPlayer, car ) outputChatBox("Vehicle Spawned",myPlayer, 0, 255, 0, true) setVehicleLocked ( car, true ) end end end addCommandHandler ( "vehCar", spawnVehicle )
Can You Guys Please Help Me ?
-
Oh, Thats the trick.
I saw many players running faster them me and i was blaming my computer configuration and internet for that.
Greatly MTA catch it and update it.
Thank You For The Update Information.
-
Thank You Very Much, I really appreciate your help but I think you didn't notice that there is a Saddle Which is attached to 'cow' Object (Is it really necessary ?).
Another thing is, I want it to output 'Cow' in chatbox and command will be 'cow'.
And there is also a command which will turn you too human being. I should add that too in tables ?
Well, The table you made for me is too complicated for me.
Can You Please Make It Less Complicated ?
-
Any Help Please ?
-
Hello, Just a few days ago, I download download an community resource named 'Animals'.
You can find it here :- https://community.multitheftauto.com/in ... ls&id=6904
But soon after playing for a while with my friends, i found a bug. Which is,
When we change into an animal and then another player change into animal, We Automatically change back to human.
Noting that the script is bit old and is less likely to seen by the Author (I still post a bug report there).
In Meanwhile I tried to fixed it myself (As Denny199 suggested in Comments box) but no Success (As I am in Practice-Mode For Tables).
Here is the Full Script:-
local Cows = {} local Fishes = {} local Jellyfishes = {} local Dolphins = {} local Sharks = {} local Turtles = {} local Chickens = {} local Humans = {} local Saddles = {} function makeCow(player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Cows[player] = createObject( 16442, x, y, z, rx, ry, rz, false) -- Saddles[player] = createVehicle(441, x, y, z, rx, ry, rz) setObjectScale(Cows[player], 0.4) attachElements(Cows[player], Humans[player], 0, 0, -0.1, 0, 0, 90) -- attachElements(Caddles[player], Cows[player], 0, 0, 0.4, 0, 0, 90) cam = setCameraMatrix(Humans[player], x, y, z + 3 ) attachElements(cam, Cows[player]) setElementAlpha(Humans[player], 0) setElementAlpha(Saddles[player], 0) outputChatBox("You are now a Cow!", Humans[player], 0, 255, 0) destroyElement(Chickens[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Fishes[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,5000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil end addCommandHandler("cow", makeCow) function makeFish(player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Fishes[player] = createObject( 1606, x, y, z, rx, ry, rz ) attachElements(Fishes[player], Humans[player]) setElementAlpha(Humans[player], 0) outputChatBox("You are now a Fish!", Humans[player], 0, 255, 0) setCameraTarget( Humans[player], Fishes[player] ) destroyElement(Saddles[player]) destroyElement(Cows[player]) destroyElement(Chickens[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("fish", makeFish) function makeJellyfish(player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Jellyfishes[player] = createObject( 1602, x, y, z, rx, ry, rz ) attachElements(Jellyfishes[player], Humans[player]) setElementAlpha(Humans[player], 0) outputChatBox("You are now a Jellyfish!", Humans[player], 0, 255, 0) setCameraTarget( Humans[player], Jellyfishes[player]) destroyElement(Cows[player]) destroyElement(Saddles[player]) destroyElement(Chickens[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Sharks[player]) destroyElement(Fishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("jellyfish", makeJellyfish) function makeDolphin (player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Dolphins[player] = createObject( 1607, x, y, z, rx, ry, rz ) attachElements(Dolphins[player], Humans[player]) setElementAlpha(Humans[player], 0) outputChatBox("You are now a Dolphin!", Humans[player], 0, 255, 0) setCameraTarget( Humans[player], Dolphins[player] ) destroyElement(Cows[player]) destroyElement(Chickens[player]) destroyElement(Saddles[player]) destroyElement(Fishes[player]) destroyElement(Turtles[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("dolphins[player]", makeDolphin) function makeShark (player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Sharks[player] = createObject( 1608, x, y, z, rx, ry, rz ) attachElements(Sharks[player], Humans[player]) setElementAlpha(Humans[player], 0) outputChatBox("You are now a Shark!", Humans[player], 0, 255, 0) setCameraTarget( Humans[player], Sharks[player]) destroyElement(Saddles[player]) destroyElement(Cows[player]) destroyElement(Chickens[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Fishes[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("shark", makeShark) function makeTurtle (player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Turtles[player] = createObject( 1609, x, y, z, rx, ry, rz ) attachElements(Turtles[player], Humans[player]) setElementAlpha(Humans[player], 0) outputChatBox("You are now a Turtle!", Humans[player], 0, 255, 0) setCameraTarget( player, Turtles[player] ) destroyElement(Cows[player]) destroyElement(Saddles[player]) destroyElement(Chickens[player]) destroyElement(Dolphins[player]) destroyElement(Fishes[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("turtle", makeTurtle) function makeChicken (player) local x, y, z = getElementPosition(Humans[player]) local rx, ry, rz = getElementRotation(Humans[player]) Chickens[player] = createObject( 16776, x, y, z, rx, ry, rz ) setObjectScale(Chickens[player], 0.19) attachElements(Chickens[player], Humans[player], 0, -1.4, -1.6, 0, 0, 180) setElementAlpha(Humans[player], 0) destroyElement(Cows[player]) destroyElement(Saddles[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Fishes[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) outputChatBox("You are now a Chicken!", Humans[player], 0, 255, 0) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("chicken", makeChicken) function makeHuman (player) setElementAlpha(Humans[player], -1) destroyElement(Cows[player]) destroyElement(Chickens[player]) destroyElement(Saddles[player]) destroyElement(Dolphins[player]) destroyElement(Turtles[player]) destroyElement(Fishes[player]) destroyElement(Sharks[player]) destroyElement(Jellyfishes[player]) setCameraTarget(Humans[player], Humans[player]) outputChatBox("You are now a Human!", Humans[player], 0, 255, 0) setTimer(function() Humans[player] = nil end,1000,1) Chickens[player] = nil Dolphins[player] = nil Turtles[player] = nil Fishes[player] = nil Sharks[player] = nil Jellyfishes[player] = nil Saddles[player] = nil end addCommandHandler("human", makeHuman)
Can You Guys Please Help Me ?
-
Oh, Thank You So Much!!
-
Hello, I recently got an Idea of making a Custom Damages Script, Which will replace Default Gta sa Damages with Custom Damages. Can You Please Tell Me, How Can I Do That ?
-
Nope, you're correct, that you need to fill all the parameters to get to the one you want give a non-default value for.
Oh, Thanks For Information!
-
use root as the forelement..
Yeah, I was thinking the same but when Alex17 said "If you want all players to see same columns as everybody else, then just don't add forElement argument at all." It confuses me.
Well, can i just skip forelement and jump to other argument?
-
exports.scoreboard:addScoreboardColumn('money',getRootElement(),2,45,'money') -- the first number is the order the second column size -- function updatePlayersMoney ( ) for index, player in ipairs ( getElementsByType "player" ) do setElementData ( player, "Money", getPlayerMoney ( player ) ) end -- End our loop. end -- End our function. setTimer ( updatePlayersMoney, 2500, 0 )
Well, Thank You So Much For Doing It For me!!
priority is basically the order, so if you want your new column as 2nd, then put 2. Or try neighbouring integers if that was a little off.If you are calling these functions server-side, then you can choose, if all players should see same columns, or some of them should see different columns, thats' what forElement is for. If you want all players to see same columns as everybody else, then just don't add forElement argument at all.
Well, If i don't add forElement agument then it will think the next argument(width) is forElement, If i am right.
scoreboardAddColumn ('Somename',somepixel,'somename',2) -- It will think 'somepixel' is forElement and 'somename' is width.
Well
-
name: The column name (also the element data name used to get information from).
forElement: The player to who the column should be added for.
width: Width of the column in pixels.
friendlyName: Friendly name (displayed in the scoreboard) of the column.
priority: The priority slot of the column (1-500). If slot isn't free, the column in that slot will be pushed forward.
Just reading the wiki handles it.
I don't understand what its meant by forElement and Priority.
And Which argument i can use for adding column 'money' in 2nd column (as it always shown in first column)
Can You Please Provide Little Example For Adding Money In 2nd Column ?
-
Well, I didn't made this script. I download it from community.
Here it is :-
exports [ "scoreboard" ]:addScoreboardColumn ( "Money", 5 ) function updatePlayersMoney ( ) for index, player in ipairs ( getElementsByType "player" ) do setElementData ( player, "Money", getPlayerMoney ( player ) ) end -- End our loop. end -- End our function. setTimer ( updatePlayersMoney, 2500, 0 )
I want it in dxscoreboard and after name column (in 2nd column).
Can You Help Me Please ?
-
Watch Your Title, Mr.Shariq, Busta!!!
-
Hello, I am Currently using dxscoreboard and i downloaded some scripts which shows players kills/deaths/money on scoreboard But the problem is They are not in correct order. I mean i want them to be in after the column name.
Name,Money,Kills,Deaths.
If it provide any help, i look into those scripts and they use Scoreboard exported functions (not dxscoreboard).
Can Someone Please Help Me ?
-
I already read JR10 Post but it didn't solve all my confusion, thats why i came here.
But your second thread did a good job, Thank You So Much.
-
You should learn the basics of SQL to start with mysql in lua.
B2T:
You need to have smth like a id/name in your database of your player to save the money to the specific player.
I'll write you smth when i got home.
Well, I mean i have learnt some basics of SQL and now wanna try them with lua.
Waiting for your post.
Report community resources here!
in Suggestions
Posted
Well, would not that make our community clean.
I mean maybe it can be a copy of some other resource as There are many other resources with same functions.
It will save users time on getting his/her desire resource .
I really apologize If i am wrong. But really I think there should be rule of not uploading resource which is already exist in community.