-stolka-
Members-
Posts
144 -
Joined
-
Last visited
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
-stolka-'s Achievements
Poot-butt (14/54)
0
Reputation
-
could someone tell me what's the name of flamethrower 'standing' aimation in ped block?
-
is there any function to edit players' driving skills ?
-
hi i found this function on the wiki that get a random player 'getRandomPlayer' is it possible to make a function that do the same thing but cannot get the player i'm using... for exaple if i use the command /random can i get a random player exept myself?
-
it doesn't work exports.scoreboard:addScoreboardColumn('Country') function showcountry() local flag = exports.admin:getPlayerCountry ( source ) if flag then setElementData( source,"Country",{type="image", src="./admin/client/images/flags/"..flag..".png", width=30, height=20} ) else flag = "N/A" end end addEventHandler("onPlayerJoin",getRootElement(),showcountry)
-
i downloaded this script but it doesn't work... it outputs the string of the directory insted the flag image exports.scoreboard:addScoreboardColumn('Country') function showcountry() local flag = exports.admin:getPlayerCountry ( source ) if flag then setElementData(source,"Country",":admin/client/images/flags/"..flag..".png") else flag = "N/A" end end addEventHandler("onPlayerJoin",getRootElement(),showcountry)
-
the debug report error line 7 of server but the clien doesn't even dispay the name of the weapon ( for now there is only one weapon ) server local ammuMarker1 = createMarker(295.30, -38.15, 1000.51, "cylinder", 2,180, 180, 180, 180 ) setElementInterior( ammuMarker1, 1 ) local vehicles = {} function spawnVeh(id, price) if ( getPlayerMoney( source ) >= tonumber( price ) ) then outputChatBox( tostring( id ), source ) takePlayerMoney( source, tonumber( price ) ) giveWeapon(source, id, 90 ) end end addEvent("buyGunForPlayer",true) addEventHandler("buyGunForPlayer", root, spawnVeh) function showAmmuGui(hitPlayer) if hitPlayer and getElementType(hitPlayer) == "player" then triggerClientEvent (hitPlayer,"showAmmuGUI",getRootElement(),hitPlayer) end end addEventHandler("onMarkerHit",ammuMarker1,showAmmuGui) client guiWindowSetSizable( wndAmmu, false ) guiWindowSetMovable( wndAmmu, false ) guns = { {"m4", 500}, } gridAmmu = guiCreateGridList(0.01, 0.2, 0.99, 0.5, true, wndAmmu) guiGridListAddColumn(gridAmmu, "Guns", 0.85) guiGridListAddColumn(gridAmmu, "Price", 0.85) for i,gun in ipairs(guns) do row = guiGridListAddRow(gridAmmu) -- guiGridListSetItemText(gridAmmu, row, 1, tostring(guns[1]), false, false) guiGridListSetItemData(gridAmmu, row, 1, tostring(guns[2])) end function buyGun() local row, col = guiGridListGetSelectedItem(gridAmmu) if (row and col and row ~= -1 and col ~= -1) then local gun = tostring(guiGridListGetItemData(gridAmmu, row, 0)) local price = tonumber(guiGridListGetItemData(gridAmmu, row, 1)) if (( price ~= "" ) and ( gun ~= "" )) then triggerServerEvent("buyGunForPlayer", localPlayer, gun, price) end end end addEventHandler("onClientGUIClick", buyGunBtn, buyGun, false) function closeAmmuGui() if (source == cancelGunBtn) then guiSetVisible(wndAmmu,false) showCursor(false) end end addEventHandler("onClientGUIClick", cancelGunBtn, closeAmmuGui) function showGUIp() guiSetVisible(wndAmmu,true) showCursor(true) end addEvent("showAmmuGUI",true) addEventHandler("showAmmuGUI", getRootElement(), showGUIp)
-
the debug reports "attempt to perform arithmethic on a nil value line 4" so i tried to see how getBankAccountBalance returns and output it in the chatbox! it outputs 'false' in chatbox function enterClubConfirmed( ) oldBalance = exports [ "bank-reloaded" ]:getBankAccountBalance ( "stolka" ) outputChatBox(tostring(oldBalance)) exports [ "bank-reloaded" ]:setBankAccountBalance ( bankAccount, tonumber( oldBalance ) + 120 ) fadeCamera( player, true, 1.5 ) setElementDimension( player, 2 ) setElementInterior( player, 2 ) end addEvent( "onPlayerClubConfirm", true ) addEventHandler( "onPlayerClubConfirm", getRootElement(), enterClubConfirmed )
-
so how do i make minigun has unlimited ammo?
-
what's wrong in this function? addEventHandler( "onWeaponFire", root, function () if ( isElement( source ) ) and ( getElementType( source ) == "player" ) then if getPlayerWeapon( source ) == 38 then giveWeapon ( source, 38, 1 ) end end end )
-
which is the event that i have to use? i can't find it in the wiki
-
hi which functions should i use to make a weapon has unlimited ammo?
-
4 girls dancing... i wanted to make 'em immortal... i don't know why the debug reports bad argument on all onClientPedDamage events client addEventHandler( "onClientResourceStart", getRootElement( ), function ( ) strip1 = createPed ( 237, -2677.8662109375,1403.3516845703,907.5703125 ) strip2 = createPed ( 238, -2678.0302734375,1409.7257080078,907.5703125 ) strip3 = createPed ( 246, -2673.3210449219,1409.7158203125,907.5703125 ) strip4 = createPed ( 152, -2678.7436523438,1414.4287109375,907.56634521484 ) setElementInterior ( strip1, 3 ) setElementInterior ( strip2, 3 ) setElementInterior ( strip3, 3 ) setElementInterior ( strip4, 3 ) setElementDimension ( strip1, 12 ) setElementDimension ( strip2, 12 ) setElementDimension ( strip3, 12 ) setElementDimension ( strip4, 12 ) setPedAnimation( strip1, "STRIP", "STR_Loop_A", 0, true, false, false ) setPedAnimation( strip2, "STRIP", "STR_A2B", 0, true, false, false ) setPedAnimation( strip3, "STRIP", "STR_C1", 0, true, false, false ) setPedAnimation( strip4, "STRIP", "STR_C2", 0, true, false, false ) end ) function cancelPedDamage ( attacker ) cancelEvent() -- cancel any damage done to peds end addEventHandler ( "onClientPedDamage", strip1, cancelPedDamage ) addEventHandler ( "onClientPedDamage", strip2, cancelPedDamage ) addEventHandler ( "onClientPedDamage", strip3, cancelPedDamage ) addEventHandler ( "onClientPedDamage", strip4, cancelPedDamage )
-
i have a resource that creates few teams at startup... function createGameTeams () createTeam ("Criminal", 250, 0, 0 ) createTeam ("Delta Force", 0, 153, 0) createTeam ("police", 100, 149, 237) createTeam ("Pilot", 255, 255, 0 ) createTeam ("Taxi Driver", 255, 255, 0) createTeam ("Medic", 6, 183, 248) end addEventHandler ("onResourceStart", resourceRoot, createGameTeams) that's the only thing it does... why when i restart it i cannot join a team any more?
-
i tested it.. it doesn't work any help?
-
i cant test it right now... is it correct x,y,z = getElementPosition( source ) local ho = {} ho[0] = { 2036.1735839844, -1413.0563964844, 16.9921875, 0 } ho[1] = { -2656.12, 631.01, 14.45, 0 } ho[2] = { 1607.07, 1825.3, 10.83, 0 } ho[0][3] = getDistanceBetweenPoints3D ( x,y,z,ho[0][0], ho[0][1], ho[0][2] ) ho[1][3] = getDistanceBetweenPoints3D ( x,y,z,ho[1][0], ho[1][1], ho[1][2] ) ho[2][3] = getDistanceBetweenPoints3D ( x,y,z,ho[2][0], ho[2][1], ho[2][2] ) local e=0 local i=0 local xs,ys,zs for e=0,3,1 do if ho[e][3] < ho[e+1][3] then xs = ho[e][0] ys = ho[e][1] zs = ho[e][2] end end setTimer (spawnPlayer, 1000, 1, source, xs,ys,zs, 0, getPedSkin (source), 0, 0, getPlayerTeam(source)) setTimer (setCameraTarget, 1250, 1, source, source)