Adham Posted April 26, 2016 Share Posted April 26, 2016 سسلأم عليكم عملت كود مسح شات ما ظبت ابيكم تعدلولي عليه الكود Server : function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) if isObjectInACLGroup("user."..cuenta, aclGetGroup("Console")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 1")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 2")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 3")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 4")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 5")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 6")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Head.Admin")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Trainee")) then spaces(thePlayer) end end addCommandHandler("77", clear) outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat, getRootElement(), 255, 255, 255, true)end[/b] Link to comment
[iMr]-W[i]Fi,.! Posted April 26, 2016 Share Posted April 26, 2016 سسلأم عليكم عملت كود مسح شات ما ظبتابيكم تعدلولي عليه الكود Server : function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) if isObjectInACLGroup("user."..cuenta, aclGetGroup("Console")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 1")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 2")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 3")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 4")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 5")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 6")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Head.Admin")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Trainee")) then spaces(thePlayer) end end addCommandHandler("77", clear) outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat, getRootElement(), 255, 255, 255, true)end[/b] function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) if isObjectInACLGroup("user."..cuenta, aclGetGroup("Console")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 1")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 2")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 3")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 4")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 5")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Level 6")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Head.Admin")) then spaces(thePlayer) elseif isObjectInACLGroup("user."..cuenta, aclGetGroup("Trainee")) then spaces(thePlayer) end end addCommandHandler("77", clear) function spaces () outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat", getRootElement(), 255, 255, 255, true) end جرب Link to comment
Ahmed Ly Posted April 26, 2016 Share Posted April 26, 2016 local Admins = { "Console", "Admin" } function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) for k,v in ipairs ( Admins ) do if isObjectInACLGroup("user."..cuenta, aclGetGroup(v)) then outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat", getRootElement(), 255, 255, 255, true) end end end addCommandHandler("77", clear) Link to comment
Adham Posted April 26, 2016 Author Share Posted April 26, 2016 ما ظبت + بيمسح الشات نصو و مش بيكتب Clear chat Link to comment
Ahmed Ly Posted April 26, 2016 Share Posted April 26, 2016 ما ظبت + بيمسح الشات نصوو مش بيكتب Clear chat local Admins = { "Console", "Admin" } function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) for k,v in ipairs ( Admins ) do if isObjectInACLGroup("user."..cuenta, aclGetGroup(v)) then outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat",root, 0, 255, 0, true) end end end addCommandHandler("77", clear) Link to comment
Adham Posted April 26, 2016 Author Share Posted April 26, 2016 تمام بس بيمسح مرتين ورا بعض Link to comment
Ahmed Ly Posted April 26, 2016 Share Posted April 26, 2016 تمام بس بيمسح مرتين ورا بعض كيف قصدك مرتين ورا بعض؟ Link to comment
[iMr]-W[i]Fi,.! Posted April 26, 2016 Share Posted April 26, 2016 جرب كذا ي لعبة local Admins = { "Console", "Admin" } function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount(thePlayer) ) for k,v in ipairs ( Admins ) do if isObjectInACLGroup("user."..cuenta, aclGetGroup(v)) then outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" ") outputChatBox(" #0099cc"..getPlayerName(thePlayer).." - Cleard Chat",root, 0, 255, 0, true) end end end addCommandHandler("77", clear) Link to comment
|Mr|-Talal07-| Posted April 26, 2016 Share Posted April 26, 2016 GR = {"Console","Admin"} addCommandHandler("777", function (player) local acc = getPlayerAccount(player) if not isGuestAccount(acc) then for i,group in ipairs(GR) do if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup(group)) then for i=40 do outputChatBox(" ") end return end end end end ) Link to comment
Abdul KariM Posted April 26, 2016 Share Posted April 26, 2016 (edited) local Admins = { "Console", "Admin" } function clear ( thePlayer ) local cuenta = getAccountName( getPlayerAccount ( thePlayer ) ) if not isGuestAccount(cuenta) then for _ , v in ipairs ( Admins ) do if isObjectInACLGroup("user."..cuenta, aclGetGroup( v )) then for i = 0 , 17 do outputChatBox ( " " , root ) end outputChatBox(" #0099cc"..getPlayerName( thePlayer ).." - Cleard Chat",root, 0, 255, 0, true) end end end end addCommandHandler("77", clear ) Edited April 26, 2016 by Guest Link to comment
Ahmed Ly Posted April 26, 2016 Share Posted April 26, 2016 GR = {"Console","Admin"} addCommandHandler("777", function (player) local acc = getPlayerAccount(player) if not isGuestAccount(acc) then for i,group in ipairs(GR) do if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup(group)) then for i=40 do outputChatBox(" ") end return end end end end ) ليش حطيت for i = 40 do ؟ Link to comment
|Mr|-Talal07-| Posted April 26, 2016 Share Posted April 26, 2016 GR = {"Console","Admin"} addCommandHandler("777", function (player) local acc = getPlayerAccount(player) if not isGuestAccount(acc) then for i,group in ipairs(GR) do if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup(group)) then for i=40 do outputChatBox(" ") end return end end end end ) ليش حطيت for i = 40 do ؟ عشان يكرر في الشات 40 مره Link to comment
Jupi Posted April 27, 2016 Share Posted April 27, 2016 GR = {"Console","Admin"} addCommandHandler("777", function (player) local acc = getPlayerAccount(player) if not isGuestAccount(acc) then for i,group in ipairs(GR) do if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup(group)) then for i=40 do outputChatBox(" ") end return end end end end ) ليش حطيت for i = 40 do ؟ هذا اللوب الرقمي يستعمل في تكرار العمليات حسب رقم من اختيارك وتقدر تحدد من متي يبدا ومتي ينتهي مثلاً يكرر من 0 ل 10 كذا 10 مرات وممكن من 25 ل 70 طيب كيف تجيب كام بيكرر؟ لو كان ما يبدأ ب صفر و اعداد كبيرة؟ اطرح العددين من بعض يطلع لك الفرق كيف يتركب؟ for NumberVar = start, end, increment do --- end NumberVar = متغير حق رقم العملية start = الرقم اللي اللوب بيبدأ منه end = الرقم اللي بينتهي عنده increment : زيادة اللوب طبعاً ثالث شيء حق الزيادة اختياري بس مفيد ويلحس شوي الارقمنت هذا يزود كام مرة كل مرة يمر بلعملية يعني مثلاً حطيت 5 كل مرة يسوي لوب متغير NumberVar بيزيد 5 Note : الارقمنت اختياري ومو شرط تحطه ------------ بلنسبة لاخوي طلال ترتيبك للوب خاطيء و بيجب خطأ المفروض كذا for i = 0, 40 do :~) Link to comment
|Mr|-Talal07-| Posted June 11, 2016 Share Posted June 11, 2016 GR = {"Console","Admin"} addCommandHandler("777", function (player) local acc = getPlayerAccount(player) if not isGuestAccount(acc) then for i,group in ipairs(GR) do if isObjectInACLGroup("user." .. getAccountName(acc),aclGetGroup(group)) then for i=40 do outputChatBox(" ") end return end end end end ) ليش حطيت for i = 40 do ؟ هذا اللوب الرقمي يستعمل في تكرار العمليات حسب رقم من اختيارك وتقدر تحدد من متي يبدا ومتي ينتهي مثلاً يكرر من 0 ل 10 كذا 10 مرات وممكن من 25 ل 70 طيب كيف تجيب كام بيكرر؟ لو كان ما يبدأ ب صفر و اعداد كبيرة؟ اطرح العددين من بعض يطلع لك الفرق كيف يتركب؟ for NumberVar = start, end, increment do --- end NumberVar = متغير حق رقم العملية start = الرقم اللي اللوب بيبدأ منه end = الرقم اللي بينتهي عنده increment : زيادة اللوب طبعاً ثالث شيء حق الزيادة اختياري بس مفيد ويلحس شوي الارقمنت هذا يزود كام مرة كل مرة يمر بلعملية يعني مثلاً حطيت 5 كل مرة يسوي لوب متغير NumberVar بيزيد 5 Note : الارقمنت اختياري ومو شرط تحطه ------------ بلنسبة لاخوي طلال ترتيبك للوب خاطيء و بيجب خطأ المفروض كذا for i = 0, 40 do :~) للاسف انت تكلم واحد له سنتين ما برمج فاعذرني اذا اخطيت لكن مصيري ارجع كل المعلومات 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