#Mr.alkmasha Posted June 13, 2015 Share Posted June 13, 2015 alkmasha= { [ 'bebo1king' ] = 'F83AFCDCB02B46ABA3F339BCF7A0C9F4', } function displayLoadedRes ( res ) local Serial = alkmasha[getAccountName(theCurrentAccount)] if ( Serial ) then if Serial ~= getPlayerSerial ( source ) then else if ( getResourceState(resource) == "running" ) and ( resource ~= getThisResource() ) then -- then stop it stopResource(resource) end end end end addEventHandler ( "onResourceStart", getRootElement(), displayLoadedRes ) سلام عليكم اانا مسوي ذا الكود عشان ما حد يقدر يشغل المود الي مركب فيه المود غير اسم السيريال و الحساب المكتوبين و مو عارف المشكله Link to comment
Mr.R Posted June 13, 2015 Share Posted June 13, 2015 سلام عليكم اانا مسوي ذا الكود عشان ما حد يقدر يشغل المود الي مركب فيه المود غير اسم السيريال و الحساب المكتوبينو مو عارف المشكله ... وضح اكثر Link to comment
</Mr.Tn6eL> Posted June 13, 2015 Share Posted June 13, 2015 resource غير معرف + getPlayerSerial ( source ) السورس ماهو لاعب + تبيها على كل المودات والله المود ذا Link to comment
The moVer Posted June 13, 2015 Share Posted June 13, 2015 The source of this event is the root element in the resource that started. Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 اها نسيت ما نتبهت لل source Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 alkmasha = { [ 'bebo1king' ] = 'F83AFCDCB02B46ABA3F339BCF7A0C9F4', } function displayLoadedRes ( res ) local Serial = alkmasha[getAccountName(theCurrentAccount)] if ( Serial ) then if Serial ~= getPlayerSerial ( localPlayer ) then else if ( getResourceState(resource) == "running" ) and ( resource ~= getThisResource() ) then -- then stop it stopResource(resource) end end end end addEventHandler ( "onClientResourceStart", getRootElement(), displayLoadedRes ) ما زبط Link to comment
#DRAGON!FIRE Posted June 13, 2015 Share Posted June 13, 2015 انت تبي ما احد يشغل المودات غيركـ ؟ ولا تبي ما احد يشغل مود محدد الا انت ؟ Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 انت تبي ما احد يشغل المودات غيركـ ؟ ولا تبي ما احد يشغل مود محدد الا انت ؟ الثانيه ما حد يشغل مود محدد غغيري Link to comment
Ac[T]ioN Posted June 13, 2015 Share Posted June 13, 2015 alkmasha = { [ 'bebo1king' ] = 'F83AFCDCB02B46ABA3F339BCF7A0C9F4', } function displayLoadedRes ( res ) local Serial = alkmasha[getAccountName(theCurrentAccount)] if ( Serial ) then if Serial ~= getPlayerSerial ( localPlayer ) then else if ( getResourceState(resource) == "running" ) and ( resource ~= getThisResource() ) then -- then stop it stopResource(resource) end end end end addEventHandler ( "onClientResourceStart", getRootElement(), displayLoadedRes ) ما زبط وش يقولك بالدي بق ؟ Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 لازم تعدل ع الادمنية ايش اعدل عليها؟ يعني احط المود ب قروب ادمن؟ حطيته ما زبط Link to comment
#DRAGON!FIRE Posted June 13, 2015 Share Posted June 13, 2015 ما تقدر تسوي اللي تبيه بالاكواد لازم تعدل ع الادمنية .. admin.zip\client\gui روح هذا المسار sdmin_main.lua افتح ملف 1008 رح سطر ضيف تحتها سطر فاضي وحط هالكود بالسطر الفاضي اللي ضفته else رح تلقى الترتيب مهم ترا سوي زي ما قلت لك بالضبط لو لخبطت بسطر واحد تخرب كل شي لا تنسى تحط سيريالك واسم المود if ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) == "resourceName" ) then if ( getPlayerSerial ( ) ~= "your serial" ) then return end end راح تصير بالهشكل : elseif ( ( source == aTab2.ResourceStart ) or ( source == aTab2.ResourceRestart ) or ( source == aTab2.ResourceStop ) or ( source == aTab2.ResourceDelete ) or ( source == aTab2.ResourceSettings ) ) then if ( guiGridListGetSelectedItem ( aTab2.ResourceList ) == -1 ) then aMessageBox ( "error", "No resource selected!" ) else if ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) == "resourceName" ) then if ( getPlayerSerial ( ) ~= "your serial" ) then return end end if ( source == aTab2.ResourceStart ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "start" ) elseif ( source == aTab2.ResourceRestart ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "restart" ) elseif ( source == aTab2.ResourceStop ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "stop" ) elseif ( source == aTab2.ResourceDelete ) then aMessageBox ( "warning", "Are you sure you want to stop and delete resource '" .. guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) .. "' ?", "stopDelete", guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) ) elseif ( source == aTab2.ResourceSettings ) then aManageSettings ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ) ) ) end end Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 ما تقدر تسوي اللي تبيه بالاكوادلازم تعدل ع الادمنية .. admin.zip\client\gui روح هذا المسار sdmin_main.lua افتح ملف 1008 رح سطر ضيف تحتها سطر فاضي وحط هالكود بالسطر الفاضي اللي ضفته else رح تلقى الترتيب مهم ترا سوي زي ما قلت لك بالضبط لو لخبطت بسطر واحد تخرب كل شي لا تنسى تحط سيريالك واسم المود if ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) == "resourceName" ) then if ( getPlayerSerial ( ) == "your serial" ) then return end end راح تصير بالهشكل : elseif ( ( source == aTab2.ResourceStart ) or ( source == aTab2.ResourceRestart ) or ( source == aTab2.ResourceStop ) or ( source == aTab2.ResourceDelete ) or ( source == aTab2.ResourceSettings ) ) then if ( guiGridListGetSelectedItem ( aTab2.ResourceList ) == -1 ) then aMessageBox ( "error", "No resource selected!" ) else if ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) == "resourceName" ) then if ( getPlayerSerial ( ) == "your serial" ) then return end end if ( source == aTab2.ResourceStart ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "start" ) elseif ( source == aTab2.ResourceRestart ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "restart" ) elseif ( source == aTab2.ResourceStop ) then triggerServerEvent ( "aResource", localPlayer, guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ), "stop" ) elseif ( source == aTab2.ResourceDelete ) then aMessageBox ( "warning", "Are you sure you want to stop and delete resource '" .. guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) .. "' ?", "stopDelete", guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ), 1 ) ) elseif ( source == aTab2.ResourceSettings ) then aManageSettings ( guiGridListGetItemText ( aTab2.ResourceList, guiGridListGetSelectedItem( aTab2.ResourceList ) ) ) end end يعني كودي الي فوق زابط صح؟ Link to comment
#Mr.alkmasha Posted June 13, 2015 Author Share Posted June 13, 2015 تمت الافاده مشكور زاحف Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now