-
Posts
275 -
Joined
-
Last visited
Everything posted by uhm
-
what object is it? the hot coffee animations were removed but I don't know about objects
-
if its still the active process (so you can still see whats being said and whatnot) simply press CTRL+C or type command: exit if you ran it via "screen", which is the method you should use for running mta-server, check out part 3 (My Connection Dropped - What Can I Do?) of this page: http://www.howtoforge.com/linux_screen and then type command: exit to do it dramatically you can type ps to view current processes. the first column is the process id. this is what you use for: pkill
-
Okay, I shall formulate it so it is better to understand or translatable by a machine: Indeed. The code I have posted won't work instantly. Because you must replace the values I have set manually by functions such as guiGetText. Instead of the lines where I put "print", you must put the actual handling. Such as showing a pop-up window when the check fails. And when the check succeeds, put code so your server does things like SQL "INSERT"-commands. If you are checking if the username is okay in a client-side script, you also must put a trigger for the code on the side of your server (server-side). Because you can not use SQL-commands directly on the client-side.
-
nay dawg you obviously need to change the hardcoded values to shiz like guiGetText and instead of those prints you do the actual handling like draw a popup when its wrong and trigger your server side code to do sql shiz
-
I don't know the original, but this is fantastic sorry for bad lithuanian
-
well that code I posted doesn't allow the # character, so it already does
-
Also awesome, the drama. The loads and loads of drama. Like with that one SAMP developer, Kyle I think? And that that entire community decided not to use GTANET anymore? Classic! Scumbags uniting themselves in forums meant for scumbags. Troyrulz and Mr s0beit himself being the leaders of the underworld. It's hard to reminisce because there's only few things that are common and happened to all because there are so many subcommunities, but this whole GTASA multiplayer thing brought on so, so much Naturally these things I mention aren't those I would want back If I could travel back in time... 1892.
-
probably use a regular expressions like so username = 'whatever32$#@(*$59' if username:match('[a-zA-Z0-9]+') ~= nil then print 'It is alright' else print 'It contains illegal characters or is not long enough' end tested for syntax and functionality the regex I used ([a-zA-Z0-9]+) means: allow any character in range of a-z, A-Z, underscores and 0-9 and require at least one of those with no maximum check out RegExr to build and test your own regular expression
-
the mysqlResult object becomes nil when there's a syntax error in your script your syntax error is here: SELECT 'account_name','account_password' /* --> */ FROM 'account_info' /* <-- */ WHERE 'account_name'='"..safeusername.."' AND 'account_password'='"..safepassword.."' because youre executing the query not on a table or an array, but on a string and while that is an actual syntax error, this error wont get caught: all of your stuff that refers to cells and so are parsed as strings, so only in the even you would use account_name as a username and account_password as the password it would return one row, and the values would be account_name and account_password accountCheck = "SELECT account_name,account_password FROM account_info WHERE account_name='"..safeusername.."' AND account_password='"..safepassword.."'"
-
thats not how you put a comments in an xml file best remove those or wrap them in tags but outside of an xml element it wont parse <server host="irc.sefmta.net84.net" nick="SEFBot" port="6667" channels="#Echo" secure="false" /> <!--port, optional default: 6667--> <!--secure, optional default: false-->
-
isnt the syntax "UPDATE SET [col=value,col2=value2] WHERE [statement]"? (rhetorical) odd that it blatantly updates them all then, you should really run mysql in safe mode check if this works: function _changeEngineState( thePlayer ) local theVehicle = getPedOccupiedVehicle ( thePlayer ) if ( theVehicle ) then if ( getPedOccupiedVehicleSeat( thePlayer ) == 0 ) then local vehicleID = getElementData( theVehicle, "vehicleID" ) local result = mysql_query ( database ,"SELECT * FROM `vehicles` WHERE `vehicleID` = '"..tonumber(vehicleID).."'") if result then if ( getVehicleEngineState( theVehicle ) == true) then setVehicleEngineState( theVehicle, false ) -- turn it off. setElementData( theVehicle, "moteur", 0) mysql_query(database,"UPDATE `vehicles` SET enginestate = '0' WHERE vehicleID='"..vehicleid.."'") elseif ( getVehicleEngineState( theVehicle ) == false) then setVehicleEngineState( theVehicle, true ) -- turn it on setElementData( theVehicle, "moteur", 1) mysql_query(database,"UPDATE `vehicles` SET enginestate = '1' WHERE vehicleID='"..vehicleid.."'") end end end end end addCommandHandler("moteur", _changeEngineState)
-
in script.lua you type stuff like local spawnX, spawnY, spawnZ = 1959.55, -1714.46, 10 function joinHandler() spawnPlayer(source, spawnX, spawnY, spawnZ) fadeCamera(source, true) setCameraTarget(source, source) outputChatBox("Welcome to My Server", source) end addEventHandler("onPlayerJoin", getRootElement(), joinHandler) aight? so the actual LUA statements that determine what goes on in your server then theres a difference between server and client side scripts though: note that buymenu.lua has type="client" (see below) most of your code will go server side, but some features such as GUIs (clickable menus), drawing things on screen, playing music, handling peds and so on go in clientside scripts <script src="counterstrike.lua" /> <script src="buymenu.lua" type="client" /> This list: /counterstrike /meta.xml /counterstrike.lua /buymenu.lua it's just the file structure inside your resource, you don't have to put that list anywhere. However in the meta.xml file you define what files are related to your script. Mainly for those .lua scripts, but also for downloading images for display onscreen to clients or downloading mods for your players to use. Check out "Meta.xml" on the wiki for in-depth information.
-
that meta stuff ( ... ) goes in meta.xml and in the files with a lua extension you code the actual script it's actually on that very wiki page, bro check the section "Creating a working script"
-
lol it's a spambot that used the topic as a basis to put together a random compilation of lines to reply with. it even has a punch line. a rather comedic one too I must say. edit: wait now I'm not so sure, since that punchline wasn't stolen and only appears on these forums. that signature is definitely spam though and the first line sounds as if the community center were a building.
-
I keep thinking of the cursor with a red outline... I forgot what it's function was, might it be for this purpose? Press E and then target the road as you normally would This may be completely unrelated though, forgive me if it is
-
Yeah, that's why that object list should help out. It's a GUI and you can literally just scroll through every object you placed without having to click on the actual object.
-
I am literally offended by how low these prices are So you'd be good if I'd pay you 2 pounds for the first month and then 1 pound recurring and I would get FTP access, unlimited server storage space, unlimited bandwidth AND a 16 player server? This is worth thousands of moneys What's the uplink? What's the prospects on continuity; Will this be around in 5 years?
-
looks really cool check this on how to embed: viewtopic.php?f=98&t=50828
-
Alright let me know if it works after
-
I was thinking of this: (tested for syntax, but not for functionality) g_id = {} g_name = {} addEventHandler("onResourceStart", root, function() local iG = 0 local iC = 0 local xml = xmlLoadFile( ":Ws_freeroam/xml/vehicles.xml" ) local group -- for every in your xml file.... group = xmlFindChild( xml, "group", iG ) while group do local cars local idName = xmlNodeGetAttribute( group, "name" ) -- this is an unused variable btw -- check every car element in that group... cars = xmlFindChild( group, "vehicle", iC ) while cars do -- insert it into this table table.insert( g_id, tonumber( xmlNodeGetAttribute( cars, "id" ) ) ) table.insert( g_name, xmlNodeGetAttribute( cars, "name" ) ) -- go to the next car in the group iC = iC + 1 cars = xmlFindChild( group, "vehicle", iC ) end -- go to the next group in the xml file iG = iG + 1 group = xmlFindChild( xml, "group", iG ) end xmlUnloadFile( xml ) end ) addEventHandler ("onPlayerVehicleEnter", root, function( vehicle ) for id, name in ipairs( g_id ) do if name == getElementModel( vehicle ) then triggerClientEvent( source, "ShowCarName", root, g_name[id] ) end end end )
-
have newest drivers? works well in single player?
-
nay dawg, linux doesnt care about drive letters use like screen ./mtasa-blue/MTA10_Server/output/mta-server but i'm not sure because a lot of directory changing was involved type ls to see the current directory's contents and i guess figure out where it put mta-server or maybe the find command find . -name mta-server that should output the exact path
-
colorhost hosts in scranton yes, yes, that seems like a very fair price. quite interesting. neither shallow nor pedantic it would appear. quite on the contrary. I assure you, these replies of mine are not offtopic, sir. That first reply was hilarious because that's where the server from OP's signature is hosted right now.
-
your error is here: -- first you execute it on the first element (index 0) tag = xmlFindChild( xml, "group", index ) cars = xmlFindChild( tag, "vehicle", index ) -- then you go into a loop while cars do table.insert( g_id, tonumber( xmlNodeGetAttribute( cars, "id" ) ) ) table.insert( g_name, xmlNodeGetAttribute( cars, "name" ) ) -- index ups, but it has no effect since you need to redefine 'cars' index = index + 1 end this isnt supposed to look like a half assed reply, I hope this budges you in the right direction since it's not really a XML skills related thing but more a logical error edit: actually that double xmlFindChild doesn't make sense either, only if every has only one . you'll need to add a second loop
