MA[S]RIY Posted June 5, 2016 Share Posted June 5, 2016 السلام عليكم شباب ابي كود لما تكتب امر في الشات يلسك لبس معين ويكون لرتبه معينه يعني مثلا لو الشرطي كتبت في الشات تنظيم يلبسه لبس معين وشكرا Link to comment
nxFairlywell Posted June 5, 2016 Share Posted June 5, 2016 تحتاج اكواد سيرفر فقط 'onPlayerChat' : Event حدث الكتابة بالشات function ( message , type ) : وظيفة if message:find("تنظيم") then : تحقق اذا وجدت كلمة تنظيم بالرسالة isObjectInACLGroup : تحقق اذا كان حساب اللاعب بقروب getPlayerAccount : حساب اللاعب getAccountName : اسم الحساب aclGetGroup : القروب setElementModel : skin منح اللاعب Link to comment
Mr.R Posted June 5, 2016 Share Posted June 5, 2016 addEventHandler ( "onPlayerChat", root, function ( Message, type ) if not ( isGuestAccount ( getPlayerAccount ( source ) ) ) then if ( isObjectInACLGroup ( "user."..getAccountName ( getPlayerAccount ( source ) ), aclGetGroup ( "Police" ) ) ) then if ( type == 0 ) then if ( Message:find ( "تنظيم" ) ) then setElementModel ( source, رقم السكن ) outputChatBox ( "لقد حصلت على سكن", source, 0, 255, 0, true ) end end end end end ) 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