GrainHHH

Members
  • Content Count

    8
  • Joined

  • Last visited

Community Reputation

0 Neutral

About GrainHHH

  • Rank
    Newbie
  1. lets pick up the addEventHandler function. I've read all that crap that wiki offers me about element tree and other related thing but i still can't really understand when i need to use, lets say, the root or the rootElement. i understand that if i want to create a guiWindow that will pop up when player connects my server i need to do smt like --> addEvenHandler("onPlayerJoin", root, function() end) but i have no idea what root really makes and why i use it beside the fact that this event fires up when player connects. so, please, if you really understand it, help me) thank yoy in advance,
  2. For example: 1. addCommandhandler("test", function(player, command, something ) 2. triggerClientEvent(source, "event", source) Why the hell in first case i have to use player while in the second place, source? Thank you in advance
  3. i thought about it but look 1. I create FIRST marker here [2, 0, 2.22] 2. When i teleport myself here [10, 0, 5] 3. And create SECOND marker here [12, 0, 2.22,] I don't place myself in new created marker. Maybe i should add delay in between teleporting myself and creating third marker? I think the game just doesnt't have enough time to spawn me in new place before createing new marker. Definetely will try it out
  4. The script should create first marker in that position [2, 0, 2.22] After i hit the marker, script should create second marker in that position[12, 0, 2.22] And that's it, nothing more but look at the screen Istead of just creating second marker when i hit first, script start as i understand create it over and over again but WHY? And how can i fix that problem? createMarker(2, 0, 2.22, "cylinder", 1.0, 255, 100, 100, 100) function toSpawnIt(player) spawnPlayer(player, 10, 0, 5) createMarker(12, 0, 2.22, "cylinder", 1.0, 255, 100, 100, 100) end addEventHandler("onMarkerHit", resourceRoot, toSpawnIt) thank you in advance!
  5. How to connect server to Sqlite? Let"s take script than will be saving positions of cars and load them when server starts ( i think i'll be able to make other similar scripts knowing how to make this one ) I have everything i need ( including DB browser ) but can you show me right code and explain it? Thank you in advance. I really appreciate it.
  6. Thank god i got it. But there's mistake in your code ( "addCommandHandler " for client-sided type can take only 3 arguments - commandName, handlerFunction, caseSensitive ). But anyway it hepled me so thank you, i really appreciate it. And sorry for my english)
  7. function addRadio () outputChatBox ( " WOOOORKS " ) outputChatBox ( "You're currently listening to " .. getRadioChannelName ( getRadioChannel() ) .. "!" ) end addCommandHandler ( "MyRadio", addRadio, bool restricted = false, bool caseSensitive = false ) What's wrong with this code? Why the hell it doesn't work? ( Nothing happens when i enter the command ) this command must be available for evereone in any case ( I mean it doesn't matter whether i enter /MyRadio or /myradio, /MyRaDiO and so on ) Thank you in advance