Jump to content

SonicTHedgehog

Members
  • Posts

    27
  • Joined

  • Last visited

Everything posted by SonicTHedgehog

  1. Well .. i am a scripter but not an experienced scripter .. so i want to get experience from other players scripts.. i check every script i see and try to use all of them in a script i make ... well i saw this and i dont know what is the meaning of it.. ! function drawSpectators() local textX = x - spectatorSettings.xOffset local textY = spectatorSettings.yOffset dxDrawText("MIRANDO: "..tonumber(#spectators), textX - 0.2, textY - 0.2, x, y, tocolor(0, 0, 0, 255), 0.4, "bankgothic") drawColor("#00FF00MIRANDO: #ffffff"..tonumber(#spectators), textX, textY, x, y, tocolor(83, 134, 139), 0.4, "bankgothic") dxDrawText("FPS: "..tonumber(getElementData(getLocalPlayer(), "fps")), textX - 0.2, textY + 15 - 0.2, x, y, tocolor(0, 0, 0, 255), 0.4, "bankgothic") drawColor("#00FF00FPS: #ffffff"..tonumber(getElementData(getLocalPlayer(), "fps")), textX, textY + 15, x, y, tocolor(15, 192, 252, 255), 0.4, "bankgothic") dxDrawText("$: "..tonumber(getPlayerMoney(getLocalPlayer())), textX - 0.2, textY + 15 + 15 - 0.2, x, y, tocolor(0, 0, 0, 255), 0.4, "bankgothic") drawColor("#00FF00$: #ffffff"..tonumber(getPlayerMoney(getLocalPlayer())), textX, textY + 15 + 15, x, y, tocolor(15, 192, 252, 255), 0.4, "bankgothic") setTimer ( updateText, 1000, 0 ) end its snoopcat script .. can some one tell me the meaning and the details of this script ??
  2. I made a spawn script .. i want it to work only with players that first time they join ... ... I mean i use login gui it covers the spawn button .. when a player(not new) login the spawn button or the script to disappear And if a player register the login gui dissapear but the script keep working... sorry for my bad english
  3. I have a spawn script.. it make players choose thier skin before playing.. i want it just for new players( the players that join the server first time) because i want to save the registered players skins + position .. help me please + i can you tell me how to make a script that every one can use it .. just for admins ? or a team that i choose ? help me if thats possible. ty
  4. in 1.0.5 cant switch users & cant run multiple clients what about 1.1 ?????????????
  5. i know how to spawn a vehicle on any x,y,z but how to make the player spawn in the vehicle ? because when i spawn vehicle on any x,y,z using marker it spawns alot of vehicles if the player is still standing on the marker so i want the player to spawn in the car. help me please if you know how. thanks
  6. How to make a ped ?? and how to make it with anim or weapon ? help me please ???
  7. 1.When i set my team to police or another team by the admin panel it change my team for few seconds then i back without team . 2.Need help with Create Vehicle when player hitmarker function policecarsmarkeronStartup () policecarsChangeMarker = createMarker (1567.0947265625, -1607.6402587891, 13.3828125, "cylinder", 1.5, 0, 0, 0, 255, getRootElement()) setElementInterior (policecarsChangeMarker, 0) end addEventHandler("onResourceStart", getRootElement(), policecarsmarkeronStartup) function policecarsmarker (hitPlayer, matchingDimension) if (source == policecarsChangeMarker) then outputChatBox ("Press 1,2,3,4 to select a Police car from 4 cars", hitPlayer, 255, 0, 0, false) outputChatBox ("And press 'enter' when you find a good one", hitPlayer, 255, 0, 0, false) toggleAllControls (hitPlayer, false, true, false) bindKey (hitPlayer, "1", "down", policecarsChangeMarkerBindKeys) bindKey (hitPlayer, "2", "down", policecarsChangeMarkerBindKeys) bindKey (hitPlayer, "3", "down", policecarsChangeMarkerBindKeys) bindKey (hitPlayer, "4", "down", policecarsChangeMarkerBindKeys) bindKey (hitPlayer, "enter", "down", policecarsChangeMarkerBindKeys) end end addEventHandler("onMarkerHit", getRootElement(), policecarsmarker) function policecarsChangeMarkerBindKeys (vehicle, key, keystate) if (key == "1") and (keystate == "down") then local vehicle = createVehicle (vehicle) createVehicle (vehicle, 60000) end if (key == "2") and (keystate == "down") then local vehicle = createVehicle (vehicle) createVehicle (vehicle, 404) end if (key == "3") and (keystate == "down") then local vehicle = createVehicle (vehicle) createVehicle (vehicle, 505,65000) end if (key == "4") and (keystate == "down") then local vehicle = createVehicle (vehicle) createVehicle {442,45000} end if (key == "enter") and (keystate == "down") then toggleAllControls (thePlayer, true, true, true) unbindKey (thePlayer, "1", "down", policecarsChangeMarkerBindKeys) unbindKey (thePlayer, "2", "down", policecarsChangeMarkerBindKeys) unbindKey (thePlayer, "3", "down", policecarsChangeMarkerBindKeys) unbindKey (thePlayer, "4", "down", policecarsChangeMarkerBindKeys) unbindKey (thePlayer, "enter", "down", policecarsChangeMarkerBindKeys) end end as you see here i wrote create vehicle and tried every thing .. but still not working. 3.4. When i die on LS i respawn on LS hospital but when i die in SF or LV i respawn in LS hospital !! any one can help me ? or give me a link for hospital respawn ? ( i dont mean script one for me .. i mean if you know one please give me the link ) Sorry am new on scripting ( NOOB )
  8. I am trying to make a marker and when player get in it his team set to police(and if u can tell/show me how to make it with "yes & no" buttons) then it shows what i wrote on the chatbox i think every thing is right exept the set team part.. when i try it .. it says ,(, expected near ,if, in the server.exe .. please help me .. and as what i said last time .... i am new in scripting so i need help. thanks function policeinfomarkeronStartup () policeinfoChangeMarker = createMarker (1554.5867919922, -1675.6022949219, 16.1953125, "cylinder", 1.5, 255, 0, 0, 255, getRootElement()) end addEventHandler("onResourceStart", getRootElement(), policeinfomarkeronStartup) function policeinfomarker (hitPlayer, matchingDimension) if (source == policeinfoChangeMarker) then outputChatBox ("Now you are a police but you need police clothes and stick", hitPlayer, 255, 0, 0, false) outputChatBox ("Go and get them from LasVentas PoliceStation", hitPlayer, 255, 0, 0, false) outputChatBox ("Good luck", hitPlayer, 255, 0, 0, false) end end addEventHandler("onMarkerHit", getRootElement(), policeinfomarker) function policeinfomarker (hitPlayer, matchingDimension) if (source == policeinfoChangeMarker) then local r, g, b = getTeamColor(Police) setPlayerTeam(player, Police) end addEventHandler("onMarkerHit", getRootElement(), policeinfomarker)
  9. This is it ! check it if there is some thing wrong ! shotg.lua function replaceFunction( ) txd = engineLoadTXD ( "data/shotg.txd" ) engineImportTXD ( txd, 22 ) end addEventHandler("onClientResourceStart",getResourceRootElement(getThisResource()),replaceFunction) meta.xml <meta> <info author="SonicTheHedgehog" type="Weapon" name="ShotG" /> <script src="shotg.lua" type="client" /> <file src="data/shotg.txd" type="client" /> </meta> Lol sorry again
  10. And is there some thing wrong with the meta.xml ??
  11. Still not working .. now what about the meta.xml is it wrong ? <meta> <info author="SonicTheHedgehog" type="Weapon" name="ShotG" /> <script src="shotg.lua" type="client" /> <file src="data/shotg.TXD" type="client" /> </meta>
  12. function ( "> replacing the shotg weapon" ) txd = engineLoadTXD ( "data/shotg.txd" ) engineImportTXD ( txd, 22 ) end whats wrong with it ?? i want to replace any weapon ( because i dont know the weapons ID ) i choosed 22 and i think its m4 with my txd shotg whats wrong with it ? its not working and if its wrong .. i am still new in scripting.
  13. Can you make a Medic that heals with spraycan job ? it may be great if you did .. and you must make places to get jobs because admins are not always online and without admin players cant get job and no job = leave server any way great job !
  14. last question ! sorry ! can you tell me what to write in the meta.xml ? now i know the .lua
  15. Can you tell me what to do ? i am so sorry i am new in scripting i did the wiki scripting tutorial and every thing worked but i still dont know how to make some thing new lol here is the examples Example 1: This example loads a combination of a custom DFF and TXD file to replace the Euros vehicle in-game. The collisions are embedded inside the DFF file. outputChatBox ( "> replacing the euros vehicle" ) txd = engineLoadTXD ( "data/euros.txd" ) engineImportTXD ( txd, 587 ) dff = engineLoadDFF ( "data/euros.dff", 587 ) engineReplaceModel ( dff, 587 ) Example 2: This example loads a combination of custom DFF, TXD and COL files to replace an in-game model of a set of floors. outputChatBox ( "> loading floor objects" ) txd_floors = engineLoadTXD ( "models/office_floors.txd" ) engineImportTXD ( txd_floors, 3781 ) col_floors = engineLoadCOL ( "models/office_floors.col" ) dff_floors = engineLoadDFF ( "models/office_floors.dff", 0 ) engineReplaceCOL ( col_floors, 3781 ) engineReplaceModel ( dff_floors, 3781 ) Example 3: This example replaces the victim billboards in last venturas (when replacing default models you do not need to replace a dff or col) outputChatBox ( "> replacing billboards" ) txd_floors = engineLoadTXD ( "models/vgsn_billboard.txd" ) engineImportTXD ( txd_floors, 7300 ) i think i must use first one ... but how idk
  16. Engine functions replace a vehicle TXD file .. and i want to replace a weapon TXD file ..
  17. I have weapon .DFF and .TXD now can you tell me what to do ? please ?? sorry because i dont know T-T
  18. Can i add my own weapon skin to my server? and other players see it ?? If yes can you tell me HOW ?
  19. First i want to say that i am new in scripting so easy with me 1. HOW TO MAKE a RPG game mode ? with jobs ? (cops,criminals,medic,taxi driver....) 2. How to make a ped , object with 3Ds Max and add it to the server so other players can see it ? I need a tutorial or some thing like that.
  20. In freeroam or play game modes .. can i add my own Car,Skil,building models ? and other players see it? If yes .. can some one tell me how ?
×
×
  • Create New...