-
Posts
1,411 -
Joined
-
Last visited
-
Days Won
2
Everything posted by WASSIm.
-
chnawa nrodha ?
-
slm lolad scripte hadha ya3ml miniguns fi hunter ama dra chbih lé yadhrab wa ta3mlt fi krahab il kol Client local miniguns = {} addEvent( "onEnter", true ) addEventHandler( "onEnter",root,function(thePlayer, seat) if seat ~= 0 and getElementModel(source) ~= 425 then return end if not miniguns[thePlayer] then miniguns[thePlayer] = {} end local x, y, z = getElementPosition ( source ) local rx, ry, rz = getElementRotation ( source ) miniguns[thePlayer][1] = createWeapon ( "minigun", x, y, z ) miniguns[thePlayer][2] = createWeapon ( "minigun", x, y, z ) miniguns[thePlayer][3] = createWeapon ( "minigun", x, y, z ) miniguns[thePlayer][4] = createWeapon ("minigun", x, y, z ) for i = 1,#miniguns[thePlayer] do setWeaponOwner ( miniguns[thePlayer][i], thePlayer) setElementAlpha ( miniguns[thePlayer][i],0) end attachElements ( miniguns[thePlayer][1], source, 2.15, 0.5, -1.2, 0, 0, 90 ) attachElements ( miniguns[thePlayer][2], source, -2.10, 0.5, -1.2, 0, 0, 90 ) attachElements ( miniguns[thePlayer][3], source, 2.57, 0.5, -1.1, 0, 0, 90 ) attachElements ( miniguns[thePlayer][4], source, -2.52, 0.5, -1.1, 0, 0, 90 ) if thePlayer~=localPlayer then return end toggleControl ( "vehicle_fire", false ) toggleControl ( "vehicle_secondary_fire", false ) for _,key in ipairs(getBoundKeys("vehicle_fire"))do bindKey ( key, "down",fire ) bindKey ( key, "up",fire ) end end) addEvent( "onExit", true ) addEventHandler( "onExit",root,function(thePlayer, seat) if seat ~= 0 and getElementModel(source) ~= 425 then return end for _,minigun in ipairs(miniguns[thePlayer])do destroyElement (minigun) end miniguns[thePlayer] = nil if thePlayer~=localPlayer then return end toggleControl ( "vehicle_fire", false ) toggleControl ( "vehicle_secondary_fire", false ) for _,key in ipairs(getBoundKeys("vehicle_fire"))do unbindKey ( key, "down",fire ) unbindKey ( key, "up",fire ) end end) function fire(_,state) triggerServerEvent("fire",localPlayer,state) end function move(source) local MiniSound = playSound3D("test.wav", x, y, z,false) setSoundMaxDistance(MiniSound, 140) setSoundEffectEnabled(MiniSound,"gargle",true) attachElements ( MiniSound, getPedOccupiedVehicle(source), 0, 0.5, -1.1, 0, 0, 90 ) end addEvent( "onEnableFire", true ) addEventHandler( "onEnableFire",root,function() for _,minigun in ipairs(miniguns[source])do setWeaponState ( minigun, "firing") end move(source) end) addEvent( "onDisableFire", true ) addEventHandler( "onDisableFire",root,function() for _,minigun in ipairs(miniguns[source])do setWeaponState ( minigun, "ready") end move(source) end) SERVER addEventHandler ("onVehicleEnter", root,function(player,seat) triggerClientEvent("onEnter",source,player,seat) end) addEventHandler("onVehicleExit", root,function(player,seat) triggerClientEvent ( "onExit",source,player,seat) end) addEvent("fire",false) addEventHandler("fire",root,function(state) if state=="down"then triggerClientEvent("onEnableFire",client) elseif state=="up"then triggerClientEvent ("onDisableFire",client) end end)
-
try this bindKey("F4", "down", function () local IsWindowVisible = guiGetVisible(GUIEditor_Window[1]) if (IsWindowVisible == true) then guiSetVisible(GUIEditor_Window[1], false) showCursor(false) end if (IsWindowVisible == false) then guiSetVisible(GUIEditor_Window[1], true) showCursor(true) end end )
-
working but to all cars and i can't shoting
-
no. exm this if player select dataIV Usually only player selecting have health (isPlayerOnGroupIV) but all player have that health addEventHandler("onClientGUIClick", IV, dataIV) if ( enablePlayerHealth ) then dxDrawRectangle(hx5, hy5, hx6, hy6,tocolor(0,0,0,170),false) dxDrawRectangle(hx1, hy1, hx2, hy2,tocolor(0,0,0,150),false) dxDrawBorderedText(""..tostring(currenthealth).."%",hx1+200, hy1-2, hx2, hy2,tocolor(220,220,220,255),scale-1,font2,"center","top",false,false,false) if ( exports.setting:isPlayerOnGroupIV ( source ) ) then dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(90,125,90,255),false) elseif ( exports.setting:isPlayerOnGroupTBOGT ( source ) ) then dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(220,220,220,255),false) elseif ( exports.setting:isPlayerOnGroupTLAD ( source ) ) then dxDrawRectangle(hx3, hy3, hx4, hy4,tocolor(90,0,0,255),false) end end
-
hi guys i have problem if player select exm TBOGT all player have this local x,y = guiGetScreenSize() function select() TLADvisible = guiGetVisible(IV) TBOGTvisible = guiGetVisible(TBOGT) IVvisible = guiGetVisible(TLAD) if (IVvisible == false) and (TBOGTvisible == false) and (TLADvisible == false) then IV = guiCreateStaticImage(x*0.75, y*0.401, x*0.210, y*0.350, "images/IV.png", false) TBOGT = guiCreateStaticImage(x*0.40, y*0.401, x*0.220, y*0.350, "images/TBOGT.png", false) TLAD = guiCreateStaticImage(x*0.05, y*0.401, x*0.200, y*0.350, "images/TLAD.png", false) dxDrawRectangle(0, 0, x*1, y*1, tocolor(0, 0, 0, 206), false) dxDrawText("Select your favorite GTA4", x*0.35, y*0.0846354166666667, x*0.83984375, y*0.1640625, tocolor(255, 255, 255, 255), 2.00, "pricedown", "left", "top", false, false, true, false, false) addEventHandler("onClientGUIClick", IV, dataIV) addEventHandler("onClientGUIClick", TBOGT, dataTBOGT) addEventHandler("onClientGUIClick", TLAD, dataTLAD) addEventHandler("onClientRender", getRootElement(), draw) showCursor(true) setElementFrozen(localPlayer, true) end if (IVvisible == true) and (TBOGTvisible == true) and (TLADvisible == true) then removeEventHandler("onClientRender", getRootElement(), draw) guiSetVisible(IV, false) guiSetVisible(TBOGT, false) guiSetVisible(TLAD, false) showCursor(false) setElementFrozen(localPlayer, false) end end bindKey("F2", "down", select ) function dataIV() setElementData(localPlayer, "Idioma", "IV") removeEventHandler("onClientRender", getRootElement(), draw) guiSetVisible(IV, false) guiSetVisible(TBOGT, false) guiSetVisible(TLAD, false) showCursor(false) setElementFrozen(localPlayer, false) txd = engineLoadTXD(":packweapon/weapon/ak47.txd", 355 ) engineImportTXD(txd, 355) dff = engineLoadDFF(":packweapon/weapon/ak47.dff", 355 ) engineReplaceModel(dff, 355) txd = engineLoadTXD(":packweapon/weapon/bat.txd", 336 ) engineImportTXD(txd, 336) dff = engineLoadDFF(":packweapon/weapon/bat.dff", 336 ) engineReplaceModel(dff, 336) txd = engineLoadTXD(":packweapon/weapon/shotgspa.txd", 349 ) engineImportTXD(txd, 349) dff = engineLoadDFF(":packweapon/weapon/shotgspa.dff", 349 ) engineReplaceModel(dff, 349) txd = engineLoadTXD(":packweapon/weapon/colt45.txd", 346 ) engineImportTXD(txd, 346) dff = engineLoadDFF(":packweapon/weapon/colt45.dff", 346 ) engineReplaceModel(dff, 346) txd = engineLoadTXD(":packweapon/weapon/desert_eagle.txd", 348 ) engineImportTXD(txd, 348) dff = engineLoadDFF(":packweapon/weapon/desert_eagle.dff", 348 ) engineReplaceModel(dff, 348) txd = engineLoadTXD(":packweapon/weapon/knifecur.txd", 335 ) engineImportTXD(txd, 335) dff = engineLoadDFF(":packweapon/weapon/knifecur.dff", 335 ) engineReplaceModel(dff, 335) txd = engineLoadTXD(":packweapon/weapon/m4.txd", 356 ) engineImportTXD(txd, 356) dff = engineLoadDFF(":packweapon/weapon/m4.dff", 356 ) engineReplaceModel(dff, 356) txd = engineLoadTXD(":packweapon/weapon/micro_uzi.txd", 352 ) engineImportTXD(txd, 352) dff = engineLoadDFF(":packweapon/weapon/micro_uzi.dff", 352 ) engineReplaceModel(dff, 352) txd = engineLoadTXD(":packweapon/weapon/molotov.txd", 344 ) engineImportTXD(txd, 344) dff = engineLoadDFF(":packweapon/weapon/molotov.dff", 344 ) engineReplaceModel(dff, 344) txd = engineLoadTXD(":packweapon/weapon/mp5lng.txd", 353 ) engineImportTXD(txd, 353) dff = engineLoadDFF(":packweapon/weapon/mp5lng.dff", 353 ) engineReplaceModel(dff, 353) txd = engineLoadTXD(":packweapon/weapon/rocketla.txd", 359 ) engineImportTXD(txd, 359) dff = engineLoadDFF(":packweapon/weapon/rocketla.dff", 359 ) engineReplaceModel(dff, 359) txd = engineLoadTXD(":packweapon/weapon/chromegun.txd", 351 ) engineImportTXD(txd, 351) dff = engineLoadDFF(":packweapon/weapon/chromegun.dff", 351 ) engineReplaceModel(dff, 351) txd = engineLoadTXD(":packweapon/weapon/sniper.txd", 358 ) engineImportTXD(txd, 358) dff = engineLoadDFF(":packweapon/weapon/sniper.dff", 358 ) engineReplaceModel(dff, 358) txd = engineLoadTXD(":packweapon/weapon/glancher.txd", 347 ) engineImportTXD(txd, 347) dff = engineLoadDFF(":packweapon/weapon/glancher.dff", 347 ) engineReplaceModel(dff, 347) txd = engineLoadTXD(":packweapon/weapon/missile.txd", 345 ) engineImportTXD(txd, 345) dff = engineLoadDFF(":packweapon/weapon/missile.dff", 345 ) engineReplaceModel(dff, 345) txd = engineLoadTXD(":packweapon/weapon/grenade.txd", 342 ) engineImportTXD(txd, 342) dff = engineLoadDFF(":packweapon/weapon/grenade.dff", 342 ) engineReplaceModel(dff, 342) txd = engineLoadTXD(":packweapon/weapon/default/sawnoff.txd", 350 ) engineImportTXD(txd, 350) dff = engineLoadDFF(":packweapon/weapon/default/sawnoff.dff", 350 ) engineReplaceModel(dff, 350) txd = engineLoadTXD(":packweapon/weapon/default/poolcue.txd", 338 ) engineImportTXD(txd, 338) dff = engineLoadDFF(":packweapon/weapon/default/poolcue.dff", 338 ) engineReplaceModel(dff, 338) txd = engineLoadTXD(":packweapon/weapon/default/satchel.txd", 363 ) engineImportTXD(txd, 363) dff = engineLoadDFF(":packweapon/weapon/default/satchel.dff", 363 ) engineReplaceModel(dff, 363) end function dataTBOGT() setElementData(localPlayer, "Idioma", "TBOGT") removeEventHandler("onClientRender", getRootElement(), draw) guiSetVisible(IV, false) guiSetVisible(TBOGT, false) guiSetVisible(TLAD, false) showCursor(false) setElementFrozen(localPlayer, false) txd = engineLoadTXD(":packweapon/weapon/tbogt/m4.txd", 356 ) engineImportTXD(txd, 356) dff = engineLoadDFF(":packweapon/weapon/tbogt/m4.dff", 356 ) engineReplaceModel(dff, 356) txd = engineLoadTXD(":packweapon/weapon/tbogt/satchel.txd", 363 ) engineImportTXD(txd, 363) dff = engineLoadDFF(":packweapon/weapon/tbogt/satchel.dff", 363 ) engineReplaceModel(dff, 363) txd = engineLoadTXD(":packweapon/weapon/tbogt/desert_eagle.txd", 348 ) engineImportTXD(txd, 348) dff = engineLoadDFF(":packweapon/weapon/tbogt/desert_eagle.dff", 348 ) engineReplaceModel(dff, 348) txd = engineLoadTXD(":packweapon/weapon/tbogt/micro_uzi.txd", 352 ) engineImportTXD(txd, 352) dff = engineLoadDFF(":packweapon/weapon/tbogt/micro_uzi.dff", 352 ) engineReplaceModel(dff, 352) txd = engineLoadTXD(":packweapon/weapon/tbogt/mp5lng.txd", 353 ) engineImportTXD(txd, 353) dff = engineLoadDFF(":packweapon/weapon/tbogt/mp5lng.dff", 353 ) engineReplaceModel(dff, 353) txd = engineLoadTXD(":packweapon/weapon/tbogt/sniper.txd", 358 ) engineImportTXD(txd, 358) dff = engineLoadDFF(":packweapon/weapon/tbogt/sniper.dff", 358 ) engineReplaceModel(dff, 358) txd = engineLoadTXD(":packweapon/weapon/tbogt/shotgspa.txd", 351 ) engineImportTXD(txd, 351) dff = engineLoadDFF(":packweapon/weapon/tbogt/shotgspa.dff", 351 ) engineReplaceModel(dff, 351) txd = engineLoadTXD(":packweapon/weapon/grenade.txd", 342 ) engineImportTXD(txd, 342) dff = engineLoadDFF(":packweapon/weapon/grenade.dff", 342 ) engineReplaceModel(dff, 342) txd = engineLoadTXD(":packweapon/weapon/bat.txd", 336 ) engineImportTXD(txd, 336) dff = engineLoadDFF(":packweapon/weapon/bat.dff", 336 ) engineReplaceModel(dff, 336) txd = engineLoadTXD(":packweapon/weapon/default/sawnoff.txd", 350 ) engineImportTXD(txd, 350) dff = engineLoadDFF(":packweapon/weapon/default/sawnoff.dff", 350 ) engineReplaceModel(dff, 350) txd = engineLoadTXD(":packweapon/weapon/default/poolcue.txd", 338 ) engineImportTXD(txd, 338) dff = engineLoadDFF(":packweapon/weapon/default/poolcue.dff", 338 ) engineReplaceModel(dff, 338) end function dataTLAD() setElementData(localPlayer, "Idioma", "TLAD") removeEventHandler("onClientRender", getRootElement(), draw) guiSetVisible(IV, false) guiSetVisible(TBOGT, false) guiSetVisible(TLAD, false) showCursor(false) setElementFrozen(localPlayer, false) txd = engineLoadTXD(":packweapon/weapon/tlad/sawnoff.txd", 350 ) engineImportTXD(txd, 350) dff = engineLoadDFF(":packweapon/weapon/tlad/sawnoff.dff", 350 ) engineReplaceModel(dff, 350) txd = engineLoadTXD(":packweapon/weapon/tlad/micro_uzi.txd", 352 ) engineImportTXD(txd, 352) dff = engineLoadDFF(":packweapon/weapon/tlad/micro_uzi.dff", 352 ) engineReplaceModel(dff, 352) txd = engineLoadTXD(":packweapon/weapon/tlad/poolcue.txd", 338 ) engineImportTXD(txd, 338) dff = engineLoadDFF(":packweapon/weapon/tlad/poolcue.dff", 338 ) engineReplaceModel(dff, 338) txd = engineLoadTXD(":packweapon/weapon/tlad/shotgspa.txd", 351 ) engineImportTXD(txd, 351) dff = engineLoadDFF(":packweapon/weapon/tlad/shotgspa.dff", 351 ) engineReplaceModel(dff, 351) txd = engineLoadTXD(":packweapon/weapon/tlad/grenade.txd", 342 ) engineImportTXD(txd, 342) dff = engineLoadDFF(":packweapon/weapon/tlad/grenade.dff", 342 ) engineReplaceModel(dff, 342) txd = engineLoadTXD(":packweapon/weapon/tlad/bat.txd", 336 ) engineImportTXD(txd, 336) dff = engineLoadDFF(":packweapon/weapon/tlad/bat.dff", 336 ) engineReplaceModel(dff, 336) txd = engineLoadTXD(":packweapon/weapon/m4.txd", 356 ) engineImportTXD(txd, 356) dff = engineLoadDFF(":packweapon/weapon/m4.dff", 356 ) engineReplaceModel(dff, 356) txd = engineLoadTXD(":packweapon/weapon/desert_eagle.txd", 348 ) engineImportTXD(txd, 348) dff = engineLoadDFF(":packweapon/weapon/desert_eagle.dff", 348 ) engineReplaceModel(dff, 348) txd = engineLoadTXD(":packweapon/weapon/mp5lng.txd", 353 ) engineImportTXD(txd, 353) dff = engineLoadDFF(":packweapon/weapon/mp5lng.dff", 353 ) engineReplaceModel(dff, 353) txd = engineLoadTXD(":packweapon/weapon/sniper.txd", 358 ) engineImportTXD(txd, 358) dff = engineLoadDFF(":packweapon/weapon/sniper.dff", 358 ) engineReplaceModel(dff, 358) txd = engineLoadTXD(":packweapon/weapon/default/satchel.txd", 363 ) engineImportTXD(txd, 363) dff = engineLoadDFF(":packweapon/weapon/default/satchel.dff", 363 ) engineReplaceModel(dff, 363) end function join() setElementData(localPlayer, "Idioma", "IV") end addEventHandler("onClientPlayerLogin", getRootElement(), join)
-
[WIP/Presentation] Youtube & Radio Virtualizer v2.0
WASSIm. replied to krischkros's topic in Resources
music world -
look in setting freeroam
-
Random problems: -script not working or -working but to all vehicles and can't kill players/peds or -working but can't kill players/peds <---first problem
-
function showGUIp(hitPlayer) if hitPlayer and getElementType(hitPlayer) == "player" then if ( getPlayerTeam ( hitPlayer ) == getTeamFromName ( "Swat" ) ) then triggerClientEvent (hitPlayer,"showGUIpv",getRootElement(),hitPlayer) else warnText("vehicles for Swat members only!",hitPlayer) end end end addEventHandler("onMarkerHit",markerpv, showGUIp)
-
try this my script weapon sound 3D function weaponfired(weapon, ammo, ammoInClip, hitX, hitY, hitZ, hitElement) local soundfile = "" if weapon == 24 then soundfile = "deagle.wav" elseif weapon == 23 then soundfile2 = "silenced.wav" elseif weapon == 22 then soundfile = "colt.wav" elseif weapon == 29 then soundfile = "mp5.wav" elseif weapon == 25 or weapon == 26 then soundfile = "shotgun.wav" elseif weapon == 27 then soundfile = "combat.wav" elseif weapon == 28 then soundfile = "uzi.wav" elseif weapon == 34 or weapon == 33 then soundfile = "sniper.wav" elseif weapon == 31 then soundfile = "m4.wav" elseif weapon == 30 then soundfile = "ak_47.wav" elseif weapon == 35 or weapon == 36 then soundfile = "rpg.wav" end local x, y, z = getElementPosition(source) local sound = playSound3D(soundfile, x, y, z, false) setSoundVolume(sound,0.9) setSoundMaxDistance(sound, 40) end addEventHandler("onClientPlayerWeaponFire", root, weaponfired)
-
what i use server said ? addEventHandler ("onVehicleEnter", root,function(player,seat) triggerClientEvent("onEnter",source,player,seat) end) addEventHandler("onVehicleExit", root,function(player,seat) triggerClientEvent ( "onExit",source,player,seat) end) addEvent("fire",false) addEventHandler("fire",root,function(state) if state=="down"then triggerClientEvent("onEnableFire",client) elseif state=="up"then triggerClientEvent ("onDisableFire",client) end end) addEventHandler ("onVehicleEnter", root,function(player,seat) triggerClientEvent("onEnter",source,player,seat) end) addEventHandler("onVehicleStartExit", root,function(player,seat) triggerClientEvent("onExit",source,player,seat) end)
-
problem: (can't damage player) or (can't shoting) plis how fix now?