+Source|> Posted June 10, 2017 Share Posted June 10, 2017 انا عندي مود لوكال بس المشكلة لما اسوي ميوت للاعب يقدر يتكلم لوكال ابيه ما يقدر يتكلم Link to comment
#Soking Posted June 10, 2017 Share Posted June 10, 2017 if ( isPlayerMuted ( source ) ) then return end Link to comment
+Source|> Posted June 10, 2017 Author Share Posted June 10, 2017 (edited) 4 minutes ago, #Soking said: if ( isPlayerMuted ( source ) ) then return end ما اشتغل function isPlayerInRangeOfPoint ( player, x, y, z, range ) local px, py, pz = getElementPosition ( player ) return ( ( x- px ) ^2+ ( y- py ) ^2+ ( z- pz ) ^2 ) ^0.5 <= range end RGBToHex = function (red, green, blue, alpha) if((red < 0 or red > 255 or green < 0 or green > 255 or blue < 0 or blue > 255) or (alpha and (alpha < 0 or alpha > 255))) then return nil end if(alpha) then return string.format ( "#%.2X%.2X%.2X%.2X", red, green, blue, alpha ) else return string.format ( "#%.2X%.2X%.2X", red, green, blue ) end end LocalChat = function ( player, command, ... ) if ChatLocalDisabled then local acc = getPlayerAccount(player) if not isGuestAccount ( acc ) then if not isObjectInACLGroup("user." .. getAccountName(acc), aclGetGroup("Console")) then outputChatBox ( "(LOCAL) * Locked", player, 255, 255, 0, true ) cancelEvent ( ) return end else outputChatBox ( "(LOCAL) * Locked.", player, 255, 255, 0, true ) cancelEvent() return end end local px, py, pz = getElementPosition ( player ) local msg = table.concat ( {...}, " " ) for i, v in ipairs ( getElementsByType ( "player" ) ) do if isPlayerInRangeOfPoint ( v, px, py, pz, 30 ) then if ( isPlayerMuted ( source ) ) then return end local plrTeam = getPlayerTeam(player) if plrTeam then local rr, gg, bb = getTeamColor(plrTeam) outputChatBox ( RGBToHex(rr, gg, bb).."(LOCAL) "..getPlayerName(player)..": #FFFFFF"..msg, v, 255, 255, 0, true ) else outputChatBox ( "(LOCAL) "..getPlayerName(player)..": #FFFFFF"..msg, v, 255, 255, 0, true ) end end end outputServerLog("LOCAL: ".. getPlayerName ( player ) .. ": " .. msg) end addCommandHandler ( "Local", LocalChat ) Edited June 10, 2017 by A7MEDENO Link to comment
+Source|> Posted June 10, 2017 Author Share Posted June 10, 2017 (edited) 12 minutes ago, #Soking said: وين حاطط التحقق مو محصله function isPlayerInRangeOfPoint ( player, x, y, z, range ) local px, py, pz = getElementPosition ( player ) return ( ( x- px ) ^2+ ( y- py ) ^2+ ( z- pz ) ^2 ) ^0.5 <= range end RGBToHex = function (red, green, blue, alpha) if((red < 0 or red > 255 or green < 0 or green > 255 or blue < 0 or blue > 255) or (alpha and (alpha < 0 or alpha > 255))) then return nil end if(alpha) then return string.format ( "#%.2X%.2X%.2X%.2X", red, green, blue, alpha ) else return string.format ( "#%.2X%.2X%.2X", red, green, blue ) end end LocalChat = function ( player, command, ... ) if ChatLocalDisabled then local acc = getPlayerAccount(player) if not isGuestAccount ( acc ) then if not isObjectInACLGroup("user." .. getAccountName(acc), aclGetGroup("Console")) then outputChatBox ( "(LOCAL) * Locked", player, 255, 255, 0, true ) cancelEvent ( ) return end else outputChatBox ( "(LOCAL) * Locked.", player, 255, 255, 0, true ) cancelEvent() return end end local px, py, pz = getElementPosition ( player ) local msg = table.concat ( {...}, " " ) for i, v in ipairs ( getElementsByType ( "player" ) ) do if isPlayerInRangeOfPoint ( v, px, py, pz, 30 ) then if ( isPlayerMuted ( source ) ) then return end ------------- التحقق local plrTeam = getPlayerTeam(player) if plrTeam then local rr, gg, bb = getTeamColor(plrTeam) outputChatBox ( RGBToHex(rr, gg, bb).."(LOCAL) "..getPlayerName(player)..": #FFFFFF"..msg, v, 255, 255, 0, true ) else outputChatBox ( "(LOCAL) "..getPlayerName(player)..": #FFFFFF"..msg, v, 255, 255, 0, true ) end end end outputServerLog("LOCAL: ".. getPlayerName ( player ) .. ": " .. msg) end addCommandHandler ( "Local", LocalChat ) سطر 38 Edited June 10, 2017 by A7MEDENO Link to comment
Abdul KariM Posted June 10, 2017 Share Posted June 10, 2017 وحطه تحت السطر 33 player بـ source استبدل Link to comment
#BrosS Posted June 10, 2017 Share Posted June 10, 2017 3 minutes ago, Abdul KariM said: وحطه تحت السطر 33 player بـ source استبدل 1 Link to comment
+Source|> Posted June 10, 2017 Author Share Posted June 10, 2017 1 minute ago, #BrosS said: هههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههه شكرا لكم 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