Jump to content

Annas

Members
  • Posts

    143
  • Joined

  • Last visited

Everything posted by Annas

  1. Annas

    help object id

    Hello, anyone can give me this object id ? , and thx. http://i.imgur.com/xMJEXkz.png
  2. i dont understand Any exemple please?
  3. im sorry but .. none helping me , please help .
  4. Hello , guys please how to make Dx Text in the (F11 map) and when i resize the map , text been resized too.. See this exemple of my friend server: See here , stay watching "Corleone" Dx text in those pictures: Dx text on the (F11 Map) : http://i.imgur.com/Mnud4OQ.jpg Also Dx text on the Minimap radar: http://i.imgur.com/1gbqa1O.png And when u resize the map in (F11 Map) text been resized too: http://i.imgur.com/lfDYsRC.png Please help me to do this and thx.
  5. ! Not working , i added it in CLIENT SIDE. even it didnt shows the cursor , and it didnt show the output .. Error in Debug script: bad argument @ 'getElementData' [Expected element at argument 1, got string 'texon'] EDIT: and.. Some of my players in my server got kicked for this reason: Download error: Error downloading requested files. Couldn't connect to server. [Failed connect to 87.98.180.15:22060; No error] [CSTtex/texture_sv.lua]
  6. When i did the command , cursor will shows , but there is no outputChatBox , and when i click on any object , nothing happend , cursor stills active .. help please....
  7. I added it , as Server Side but .. Error in debugscript attempt to call global 'getLocalPlayer' (a nil value)
  8. Hello Guys, Today i just tried to make a script , do a command , show a cursor , set data . click on any object by the cursor , set data, hide the cursor. here is my code: -- SERVER SIDE function showCursor (player) local adminlevel = getElementData(player, "admin.number") if (adminlevel >= 2) then showCursor(true) setElementData(player, "CursorIsOn", true) setElementData(player, "CursorIsOff", false) outputChatBox("Texture Mod ON, please Select an object.", player, 255, 255, 255) end end addCommandHandler("texon", showCursor) function editit ( player, clickedElement ) if getElementData(player, "CursorIsOff") == true then return end if getElementData(player, "CursorIsOn") == true then if ( clickedElement ) then local elementType = getElementType ( clickedElement ) setElementData(player, "underEdit", true) showCursor(false) outputChatBox("Object Selected", player, 255, 255, 255) end end addEventHandler ( "onClientClick", getRootElement(), editit ) It's not working .. Cursor didnt shows.. help me please
  9. I have made a script , replace shader for ped (player) by a command. so when that player did the command , the shader will been applied in his skin. it works perfect. but when a player quit , and then come back , he wont see that shader until he applied the shader to world texture again by the command.. there is no function or anything to save it? Exemple(Using engineApplyShaderToWorldTexture): 1- player did /customskin 2- shader of the skin been applied , all can see it. 3- it works perfect. the player who got the shader texture can go far and come back , others can see it as well. 4- when a player reconnect. (not the player who make the texture) 5- all can see that shader cauz they were online , ingame when he did the command to apply the shader. but who reconnected after he applied the shader to world texture , he wont see it , until the player who did the command , disable the shader and apply it back. I WISH YOU UNDERSTAND
  10. Hello Community Member, Just i wanna Apply Shader To World Texture in any object selected. So when i click "num_8" bind , it shows a cursor , when i click on the object (any object) so i can do "/replace 1" command to replace a texture on that object. 1- Type "num_8" bind, cursor must be shows. 2- Click on the object by the cursor. 3- in then im able to do "/replace 1" , when i did it , it apply the shader (any .png/.jpg texture) 4- just made the "/replace 1" command , with any Test.png or jpg , in then i can add "/replace 2 , and more.. with more texture's) Notice: only that object selected, exemple , replacing object 980 , ONLY THAT OBJECT, not all of them please help me on this or .. idk , please help And thx <3
  11. Hi , i have made a script , but i failed This script is about: 1- player did /superadvert TEXT and it will be shows a text to all players function advertising ( thePlayer, ... ) local message = table.concat( {...}, " " ) local r, g, b = getPlayerNametagColor(thePlayer) if message == "" then outputChatBox("You didnt enter a message!", thePlayer, 200, 0, 0) return end if isPlayerMuted(thePlayer) then outputChatBox("You are muted!", thePlayer, 255, 0, 0) return end outputChatBox("#FF6464(ADVERT) ".. getPlayerName(thePlayer).."#FFFFFF: "..message, root, r, g, b, true) end addCommandHandler ( "superadvert", advertising ) I wanna it get the player name tag color ONLY for the player name! Only this be with the currently name tag color of the player outputChatBox("#FF6464(ADVERT) ".. getPlayerName(thePlayer).." #FFFFFF: "..message, root, r, g, b, true) So when the player will did the command /superadvert Message for test & his name tag color is (R: 0 - G: 0 - B: 0) and his name TEST so the output will be like this (ADVERT) Test : Message for test Wish you understand me
  12. Annas

    /command test

    Hi , i have made this simple server side code function onlineStaff(thePlayer) local admins = {} for _,player in ipairs(getElementsByType("player")) do if(exports.CSTadmin:isPlayerStaff(player)) then table.insert(admins,getPlayerName(player)) end end if(#admins > 0) then exports.CSTtexts:output("Online staff: "..table.concat(admins,", "),thePlayer, 0,255,0) else exports.CSTtexts:output("No Staff is currently online!",thePlayer,255,0,0) end end addCommandHandler("onlinestaffs", onlineStaff) I must do ./onlinestaffs , to view currently online staffs .. , how can i make it "/online staffs" ? Please help.
  13. Fully code please, i do not understand anything! command : /takemoney ACCname AMOUNT please understand and help me ,kiss your hands!
  14. Ok , this is good exemple, and 100% will be working function something(player) local amount = getaccountdata(player, "money") if player(player=who will type the command) in team named "Staff" then setAccountData(player, ..amount.., -THEMONEY) end addcommandhandler("setmoney", something) (i know , i'll replace the team and others..) but what about (-TheMoney) , i wont set money to him i wanna take from him the money.. oh , wait .. takePlayerMoney(player, amount) i can make it local acc = getaccountdata(player, "money") takePlayerMoney(acc, amount) ? , it will work if he is offline right?
  15. the money data name: money can anyone state the client or server side script please? i need it with command handler I will show you my exemple , but i wanna fixed one ; and one working.. Wish you understand.. function something(player) local amount = getaccountdata(player, "money") if player(player=who will type the command) in team named "Staff" then setAccountData(player, ..amount.., -THEMONEY) end addcommandhandler("setmoney", something) the command must be (./takemoney ACCOUNT AMOUNT)
  16. How can i take player money when he is offline? i dont know if there is a function named Take Account Money or something like that i just wanna take a player money from his account when he is offline.. please help me , and thx.
  17. Username: iannas Your name(Full and last name): iAnans Ben Ahmed Why do you want free MTA Server?: Due to in tunisia , still not have a paypal yet or anything to bought with , wish i get free host for 1 year or 3 months , ty. Server Slots: 500 Your Skype: anas-ben-ahmed123 Your Email: [email protected]
  18. Annas

    setskin ID

    hello, i wish you understand what i wish for .. i wanna simple script for (if getElementData"vipTime") then able to use command : /vipskin ID , ID = any skin id he wish to .. like , /vipskin 0 (then he will set CJ skin) , and if he use /vipskin 271 then return end .. (blocked it)
  19. what u mean ?, wanna complete Server.lua , script ?
  20. please help , i tried to change onPlayerQuit to a Command Handler .. i wish you understand me.. i have made a vehicle system , but i didnt complete it yet for this reason , when i quit , all currently vehicles spawned destroyed by this function function SaveVehicleDataOnQuit() for i, veh in ipairs (getElementsByType("vehicle")) do if getElementData(veh, "Owner") == source then destroyVehicle(veh) end end end addEventHandler("onPlayerQuit", root,SaveVehicleDataOnQuit) i try to change "addEventHandler("onPlayerQuit", root,SaveVehicleDataOnQuit)" to addcommandhandler, i do it like this: function SaveVehicleDataOnQuit() for i, veh in ipairs (getElementsByType("vehicle")) do if getElementData(veh, "Owner") == source then destroyVehicle(veh) end end end addCommandHandler("hide",SaveVehicleDataOnQuit) but not work with the command handler , please help me
  21. Can any one help me please ? i need (no shot when not aim) , for no lag. i try to do this: SERVER SIDE addEventHandler ( "onResourceStart", root, function ( ) for _,weaponSkill in ipairs({"poor","std","pro"}) do setWeaponProperty("Combat Shotgun", weaponSkill, "flags", 0x000001) end end ) it's not work .. I NEED TO DISABLE : when a player have weapon, + he dont aim; he can shot without aiming ! PLEASE I NEED UR HELP!
×
×
  • Create New...