Jump to content

KraZ

Members
  • Posts

    61
  • Joined

  • Last visited

Details

  • Gang
    Nephiix

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

KraZ's Achievements

Snitch

Snitch (10/54)

0

Reputation

  1. KraZ

    Menu

    OMFG THAT IS THE SICKEST IVE EVER SEEN? Can you add me on skype so If i get stuck scripting I could ask for help with dxFunctions and mouseOver functions? please. please? my skype: TheSevenGraphics
  2. How would i use the onClientMouseEnter client event, so when your cursor is over a dx text or image it will display a different image or text or change the colour of text, And also how would i use a dxText/image as a button, Could someone post some source code so I can see how its done or can someone help me? onClientGUIClick onClientMouseEnter onClientMouseLeave
  3. Hey Im wondering why is there no MultiTheftAuto for IV/Ballad Of Gay Tony/Lost And Damned? And will there be one for GTA:V? Because I love MTA its the best multiplayer software for GrandTheftAuto and I would love to be able to play it on GTA:V or even create a server on it, Wouldn't it be easier to create a MTA client for these games since multiplayer is already built in so all you are doing is modding the multiplayer software to add support for custom servers and GUI's and stuff?
  4. I haven't got any code yet because im not sure how I would go about doing this but could someone type a basic server and client side code on how you would set a serverside timer and when someone joins it displays that timer to them? I tried this once but the timer was reset everytime someone new joins, that is because I had the timer clientside, could someone just do this basic code for me please, I could do the rest like dxText etc...
  5. KraZ

    question,

    How would i set a timer and show the same time to everyone, So say someone has been in a game for like 5 minutes and someone joins late, how would i show them the current time left of the game and not restart the timer?
  6. KraZ

    Help?

    ow yeah obvcourse, debug says expected string at argument 1 on triggerClientEvent
  7. KraZ

    Teams problem:

    This is all you have? Can you post abit more of the script if you can?
  8. KraZ

    Help?

    Doesn't work btw, Gui doesn't display, heres client and serverside: --Serverside addEventHandler("onPlayerLogin", root, function() triggerClientEvent(source, "showTeamWindow", source) end ) --Clientside addEvent("showTeamWindow", true) addEventHandler("showTeamWindow", root, function() guiSetInputEnabled(true) showCursor(true) teamSelectionWindow = guiCreateWindow(489, 284, 388, 109, "Select a team:", false) guiWindowSetSizable(teamSelectionWindow, false) criminalButton = guiCreateButton(14, 31, 171, 54, "Criminals", false, teamSelectionWindow) addEventHandler("onClientGUIClick", criminalButton, selectCrim, false) guiSetFont(criminalButton, "default-bold-small") guiSetProperty(criminalButton, "NormalTextColour", "FFAAAAAA") copButton = guiCreateButton(195, 31, 171, 54, "Law Enforcement", false, teamSelectionWindow) addEventHandler("onClientGUIClick", copButton, selectCop, false) guiSetFont(copButton, "default-bold-small") guiSetProperty(copButton, "NormalTextColour", "FFAAAAAA") end )
  9. KraZ

    Help?

    Thanks, Im not bad at scripting and don't normaly need to post here, Its just haven't scripted in a long time and can't remember alot of things, Ah well thanks anyways, There is my gamelobby and login script finished just the exp system and stuff now
  10. Try this: --Clientside addEventHandler("onClientResourceStart",root, function() showPlayerHudComponent("radar" ,false) showChat(false) end) --Serverside addEventHandler("onPlayerLogin",root, function() showPlayerHudComponent("radar" ,true) showChat(true) end)
  11. KraZ

    Help?

    How would i be able to trigger a client event from the serverside once a player logs in but only for that player so something like... addEventHandler("onPlayerLogin", root, function() triggerClientEvent("showTeamWindow", getRootElement()) end ) but this shows the window(GUI) for every player instead of just the one who logs in... help me please?
  12. KraZ

    I need help!

    oi hi! why won't you reply on skype? anyways thanks, It seems to be working now
  13. KraZ

    I need help!

    Okay so im making a TDM server based on objective based games like bank robbery, defend the vault for 5 mins to win, etc... So i made this script but for some reason it doesn't spawn a player and stuff, i have no debug errors either, Basically the timer and everything works but once it starts the activity it shows a gui which is below, but then I click on the button to pick a team i send that to the serverside and it doesn't spawn the player or set the player team, any help? GUI addEvent("showTeamWindow", true) addEventHandler("showTeamWindow", getRootElement(), function() guiSetInputEnabled(true) showCursor(true) teamSelectionWindow = guiCreateWindow(489, 284, 388, 109, "Select a team:", false) guiWindowSetSizable(teamSelectionWindow, false) criminalButton = guiCreateButton(14, 31, 171, 54, "Criminals", false, teamSelectionWindow) addEventHandler("onClientGUIClick", criminalButton, selectCrim, false) guiSetFont(criminalButton, "default-bold-small") guiSetProperty(criminalButton, "NormalTextColour", "FFAAAAAA") copButton = guiCreateButton(195, 31, 171, 54, "Law Enforcement", false, teamSelectionWindow) addEventHandler("onClientGUIClick", copButton, selectCop, false) guiSetFont(copButton, "default-bold-small") guiSetProperty(copButton, "NormalTextColour", "FFAAAAAA") end ) function selectCop(button, state) if button == "left" and state == "up" then triggerServerEvent("selectCopTeam", getLocalPlayer()) end end function selectCrim(button, state) if button == "left" and state == "up" then triggerServerEvent("selectCrimTeam", getLocalPlayer()) end end SERVERSIDE: addEventHandler("onResourceStart", resourceRoot, function() criminalTeam = createTeam ( "Criminal", 255, 0, 0 ) policeTeam = createTeam ( "Police", 0, 0, 255 ) defaultTeam = createTeam ( "Default", 255, 255, 255 ) end ) addEvent("selectCopTeam", true) addEventHandler("selectCopTeam", getRootElement(), function() setPlayerTeam ( source, policeTeam ) spawnPlayer(source, 1344, 3257, 52, 0, 285) end ) addEvent("selectCrimTeam", true) addEventHandler("selectCrimTeam", getRootElement(), function() setPlayerTeam ( source, criminalTeam ) spawnPlayer(source, 1389, 3292, 4, 0, 104) end ) function player_Wasted( ammo, attacker, weapon, bodypart ) if ( attacker ) then local tempString if ( getElementType ( attacker ) == "player" ) then givePlayerMoney ( attacker, 100 ) end local teamCriminal = getTeamFromName ( "Criminal" ) local teamPolice = getTeamFromName ( "Police" ) local playerTeam = getPlayerTeam ( source ) if ( playerTeam == teamCriminal) then spawnPlayer(source, 1389, 3292, 4, 0, 104) elseif (playerTeam == teamPolice) then spawnPlayer(source, 1344, 3257, 52, 0, 285) end end end addEventHandler ( "onPlayerWasted", getRootElement(), player_Wasted ) function activityStart() triggerClientEvent("showTeamWindow", getRootElement()) triggerClientEvent("bankRob", getRootElement()) end addEvent("startActivity", true) addEventHandler("startActivity", getRootElement(), activityStart) function activityStop() for id, allPlayers in ipairs(getElementsByType("player")) do local teamDefault = getTeamFromName ( "Default" ) setPlayerTeam ( allPlayers, teamDefault ) killPed( allPlayers ) end end addEvent("stopActivity", true) addEventHandler("stopActivity", getRootElement(), activityStop)
  14. KraZ

    help?

    OMG, My awsome programming skills failed to notice the META LOL!
  15. KraZ

    help?

    Why doesn't this work? No debug errors, and timer doesn't show up, Can't find the problem, someone help me please? addEventHandler( "onClientResourceStart", getRootElement(), function() addEventHandler("onClientRender", root, draw) if isTimer(timer) then killTimer(timer) end timer = setTimer(function() removeEventHandler("onClientRender", root, draw) triggerServerEvent("startActivity", getRootElement()) end,500000,1) end) ------------------------------------------------------- function draw() if isTimer(timer) then local timeLeft = math.ceil(getTimerDetails(timer) / 1000) dxDrawText("Time Till Activity: ", 989, 175, 1391, 277, tocolor(255, 255, 255, 255), 1, "default", "left", "top", false, false, true, false, false) dxDrawText( tostring(timeLeft), 989, 175, 1391, 277, tocolor(255, 255, 255, 255), 1, "default", "left", "top", false, false, true, false, false) end end
×
×
  • Create New...