-
Posts
570 -
Joined
-
Last visited
-
Days Won
4
Everything posted by #\_oskar_/#
-
الاكواد اللي استخدمتها dbConnect + export
-
كدا قصدك ؟
-
setVehicleDamageProof
-
كل واحد وتفكيره لو تبي تسويها له تفضل
-
عشان يجيب اللوق من لوحة الادمن ويحطه باللوحه اللي سواها
-
استخدم الداتا اسهل طريقه setElementData + getElementData + executeSQLQuery
-
اتكلم عربي او روح صفحة الاجانب واطرح موضوعك
-
مود العاجل | سلسلة مودات MtA Sa# | مود العاجل حصري + خاصية (العاجل مغلق موقتا)
#\_oskar_/# replied to #Doctor's topic in المساهمات
عمل جيد بس حاول تصلح مشكلة تكرار الشات بالتوفيق لك -
addCommandHandler("قفل", function( plr ) local acc = getPlayerAccount( plr ) local accName = getAccountName ( acc ) if isGuestAccount(acc) then return end if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Console" ) ) then if ( getElementData(plr, "ChatL") == true ) then setElementData(plr, "ChatL", false) outputChatBox("تم اغلاق العاجل",root,255,0,0,true) else setElementData(plr, "ChatL", true) outputChatBox("تم فتح العاجل",root,255,0,0,true) end else outputChatBox ("You ! :o",plr,255,255,255,true) end end) addCommandHandler("IM",function ( source,_,...) if ( getElementData(source, "ChatL") == false ) then return outputChatBox("مغلق",source,255,0,0,true) end local msg = table.concat({...} , " ") if isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(source)),aclGetGroup ('Console')) or isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(source)),aclGetGroup ('Msg')) or nil then setElementData(resourceRoot,"Msg_",msg) setElementData(resourceRoot,"Have_",true) setElementData(resourceRoot,"By_",getPlayerName(source)) else outputChatBox("انت لست ادمن",source,255,0,0,true) end end)
-
Groups = { -- القروبات المسموح لها بالكتابة "Console", "AM", } -------------------- لا داعي لتعديل الأكواد تحت هذا السطر ------------------- function check ( thePlayer, commandName, ... ) if getElementData(resourceRoot,"oskar_") == 'false' then return outputChatBox('العاجل مغلق مؤقت',thePlayer,255,0,0,true) end local accName = getAccountName ( getPlayerAccount ( thePlayer ) ) local veve = { ... } local message = table.concat ( veve, " " ) for i, v in ipairs ( Groups ) do if isObjectInACLGroup ( "user."..accName, aclGetGroup ( v ) ) then setElementData ( resourceRoot, "MessageAdmin", message); setElementData(resourceRoot,"PlrAdmin",getPlayerName(thePlayer)); SaveMessage ( ) triggerClientEvent ( "Bingo", getRootElement( ), getElementData ( resourceRoot, "MessageAdmin" ) ) end end end addCommandHandler( "AM", check ) addCommandHandler("MM",function (thePlayer,command,source) if source == 'false' then setElementData(resourceRoot,'oskar_','false') outputChatBox('تم قفل العاجل',thePlayer,255, 0, 0,true) elseif source == 'true' then setElementData(resourceRoot,'oskar_','true') outputChatBox('تم فتح العاجل',thePlayer,0, 255 , 0,true) end end) addEventHandler ( "onResourceStart", resourceRoot, function ( ) executeSQLQuery("CREATE TABLE IF NOT EXISTS SaveMessagee (Message, Server)") end ) addEvent ( "SetMessage", true ) addEventHandler ( "SetMessage", root, function ( ) getMessage ( ) end ) SaveMessage = function ( ) local msg = executeSQLQuery ( "SELECT * FROM SaveMessagee WHERE Server = '" .. getServerName ( ) .."'" ) if ( #msg ~= 0 ) then return executeSQLQuery("UPDATE SaveMessagee SET Message=? WHERE Server=? ", tostring ( getElementData ( resourceRoot, "MessageAdmin" ) ), getServerName ( ) ) else return executeSQLQuery("INSERT INTO SaveMessagee (Message,Server) VALUES(?,?)", tostring ( getElementData ( resourceRoot, "MessageAdmin" ) ), getServerName ( ) ) end end getMessage = function ( ) local msg = executeSQLQuery ( "SELECT * FROM SaveMessagee" ) if ( #msg ~= 0 ) then setElementData ( resourceRoot, "MessageAdmin", msg[1]["Message"] ) return setTimer ( triggerClientEvent, 1000, 1, "Bingo", getRootElement( ), getElementData ( resourceRoot, "MessageAdmin" ) ) else return setTimer ( triggerClientEvent, 1000, 1, "Bingo", getRootElement( ), " " ) end end اكتب ب اف 8 MM true >> مفتوح MM false >> مقفول
-
وعليكم السلام المود لم يعجبني
-
كيف الكود يشتغل بدون تحقق ؟ + اشك انه شغال اصلا
-
local x,y,z = 0,0,100 -- حط احداثياتك هنا local size = 100 -- الحجم local C_ = createColRectangle (x,y,z,size) local R_ = createRadarArea (x,y,z,size,255,255,0,150,root) addEventHandler("onColShapeLeave",C_,function (e) if getElementType(e) == "player" then killPed(e) outputChatBox('لايمكنك الخروج',e,255,0,0) end end) كنت مسويه لك يرجعه مكانه بدل مايقتله حرام
-
local x,y,z = 0,0,100 -- حط احداثياتك هنا local size = 100 -- الحجم local C_ = createColRectangle (x,y,z,size) local R_ = createRadarArea (x,y,z,size,255,255,0,150,root) addEventHandler("onColShapeLeave",C_,function (e) if getElementType(e) == "player" then local x,y,z = getElementPosition(e) setElementPosition (e,x-5,y-5,z) outputChatBox('لايمكنك الخروج',e,255,0,0) end end) جرب
-
--#Client addEvent ( "Enablee", true ) addEventHandler ( "Enablee",root,function (e) guiSetEnabled ( thebest,e) end) --#Server addEventHandler("onPlayerLogin",root,function (e) for _,v in ipairs ('Console','Admin') do if isObjectInACLGroup ( "user."..getAccountName(getPlayerAccount(source)), aclGetGroup (v[1]) ) then triggerClientEvent (source,"Enablee",source,true) end end end) addEventHandler("onPlayerLogout",root,function (e) triggerClientEvent (source,"Enablee",source,false) end) جرب
-
مااعرف احداثيات مابك عشان اضبطها عليه انت حاول تضبط الاحداثيات
-
local x,y,z = 0,0,100 -- حط احداثياتك هنا local size = 100 -- الحجم local C_ = createColRectangle (x,y,z,size) local R_ = createRadarArea (x,y,z,size,255,255,0,150,root) -- Useful function C(e,t,_,b,r,g) if getElementType(e) == "player" then toggleControl (e,"fire",_) toggleControl (e, "aim_weapon",_) outputChatBox(t,e,b,r,g) end end -- Enter addEventHandler("onColShapeHit",C_,function (e) C(e,'لا يمكنك استخدام الاسلحه',false,255,0,0) end) -- Leave addEventHandler("onColShapeLeave",C_,function (e) C(e,'الان يمكنك استخدام الاسلحه',true,0,255,0) end)
-
مايحتاج كلنت الكود كله سيرفر انت بس حاول تسوي اي شئ
-
createColRectangle onColShapeHit onColShapeLeave toggleControl الموضوع سهل جدا حاول تسويه
-
createColRectangl onColShapeLeave killPed
-
وضح اكثر لان مافهمت طلبك