Gamesnert
MTA Contributors-
Posts
2,035 -
Joined
-
Last visited
Everything posted by Gamesnert
-
Have you read the Wiki? Go to "Deathmatch Server Manual" if not.
-
Since it's not working yet, you might want to look in the resources list. Search for either "Mabako's map editor"(which I use), "Alternative map editor" or "offedit".
-
I can't find my own MTA:SA DM server in the browser list!
Gamesnert replied to GTA-FREAK[Ger]'s topic in DM Server-side
quick connect 127.0.0.1 and your port. -
Look in the client-side board, there you'll see the serial generator is down. So almost everyone is getting that error. And with MTA 1.1, I suppose you mean MTA DP2.1? Since MTA 1.1 doesn't exist for as far as I know...
-
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
ATM, it's indeed causing more trouble, and I agree it should be thrown out. Temporaraly, untill it works again. Unless it's done in 2-4 days... -
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
Actually, it's better to wait untill it's back up. And I don't have a BIG problem with this. Not sure 'bout Lil Toady though... -
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
Well, you should learn how to use it properly first ofcourse. -
Just wait, and the serial gen'll be up as soon as possible.
-
Venturas Nights Roleplay looking for experienced scripters
Gamesnert replied to SpZ's topic in General discussion
I can help scripting, but not very actively. Contact me if you want some more info. -
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
(( Maybe a little big to quote... Ehm... See the 2nd post above mine here... )) Yes, you're quite right. I don't know why they just kick out serial system until solved... Oh well, it'll be waiting until it works. (I actually picked the right time to go on holliday? Lol) By the way, if you have something like Hamachi (virtual networking application) or use 127.0.0.1, you might be able to get on. (your friends only by Hamachi or LAN though...) I don't know for sure though! -
Install bugs should be in client-support, not here. Bugs is for in-game bugs, crashes etc. Just so you know
-
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
Why don't you get ANOTHER cup of coffee, and enjoy it for another... Ehm... 14 days? Just wait. As I already said, just wait. But I think Lil Toady might be able to give an ETA in a few days. Don't hope too much yet though! -
For some reason, the webadmin doesn't have rights to that indeed... LOL. But if you look in the ACL.XML, you can see in the admin GROUP part (not the ACL part) something like... <resource src="resource.admin"/> I dunno, am on vacation ATM... So look in the admin GROUP, and you should see something like resource.admin. Copy that line and replace it with something like... And whatever is the place to put your resource.
-
1. Moderator box... What do you mean? 2. Ehm... I can't even see if that question makes any sence... Can you ask it a little better? 3. That means the script is client-side. If it's a resource that can save it in a .map file, you need to save, copy and paste it into your map. 4. Again: client-side. Also, you need to save the map. And I don't know if it saves in the current map file... I don't really think so... You should copy from the saved file and save it in yours.
-
Ehm... Not all objects... Only from a map file? In that case I still have a small line that might help you... /me looks for it /me found it Ok, loop through a list of all objects, and use the line below to check if it's a map object. If it is, you put it in a dimension. If it isn't, let it do nothing. if getElementType( parent ) == "map" and getElementID( parent ) ~= "dynamic" then If it doesn't work, you might want to delete getElementID(parent)~="dynamic", since idk what it does. This line was for a map-vehicle-only-respawn script, and so "dynamic" may have to do with vehicles, maybe not. I'm not extremely good in English, so I don't know what dynamic even means... But well, the line may be all that counts. And I think this SHOULD work.
-
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
Lol, if they don't see this, they're absolutely blind... Then I dunno how their found their way to the DM Client-Side board, but they're blind then. -
If you are having SERIAL Problems, Read this!!
Gamesnert replied to fgwelder's topic in DM Client-side
Nice to see someone making the pointless-posting even more pointless. Note to everyone: If this topic didn't inform you enough, go look at the other 5 topics underneath this one for more info... I doubt there will be ANY question about it that hasn't been answered. -
I'm still looking to the security problems... It might be that you have 2 events with "onPlayerChat" that output it to the chatbox. You might have to edit that. Because I don't have those problems with exactly the same script. And Dylan, seriously stealing scripts is totally NOT a good idea... As you can see it didn't even work at first, you missed about 4 things to close some started things... And the rest still was buggy... Also, if you're not good in Lua, NEVER start difficult! The piece of code you "made" was quite sophisticated, and when you're a starter you must try the easy scripts first. Learn doing it without even using any of the tutorials. Then you know when you're ready to make it a bit more difficult. And well, Dylan. If you want your own custom class, you'll have to edit the main lua file, which is not user-friendly and may be too difficult for starters. So to be honest, if I would have to choose, I would have gone with mine... You can edit it all in 1 file, detailed explanation, a few examples in it, and almost fully customizable without learning Lua. So I kind of doubt anyone will really need your script now... Idk, but this is what I expect and my opinion. And does freeroam even do that? If so you only need to remove the ones in "onPlayerChat". Otherwise you won't get ANY system messages at all... (atleast, not the chatbox ones )
-
Hmmm... Ok, try the new script: (the security doesn't work yet, so the -- make it comments. Since they don't mean anything ATM anyway ) config.xml: <config> <!-- The configuration file, which holds all the info about players, classes and colors. --> <!-- To add a class, add it in <class .. /> with the classname between the "". --> <!-- After that, you might want to add a color too. (or edit an existing one) --> <!-- For those tasks, you can just edit and add user etc. like in this example. --> <!-- If you have any problems with this code, contact Gamesnert on the forums. --> <!-- Note! Anyone not specified will become "member", and this class is auto generated. --> <classes class1="admin" class2="supermod" class3="mod"/> <user name="Gamesnert" class="admin"/> <user name="Anyone" class="supermod"/> <user name="Someone" class="mod"/> <colors admin="#FF0000" supermod="#00FF00" mod="#0000FF" member="#FFFFFF"/> </config> (Note: The names (except the first) were for debug reasons. I don't know anyone calling himself: "anyone" Also note that if you delete the member color, it will output the normal message! (not for the other ones though )) Script: -- ************* IMPROVED RELEASE V1.01 *************** -- ************* MADE BY GAMESNERT *************** -- ************* SCRIPTNAME : *************** -- ************* NAMECOLOR (working version) *************** -- ************* A MUST HAVE FOR CLANS!! *************** -- ************* ORIGINAL BY: FATALITRY *************** accountdat={["classes"]={}, ["colors"]={}} function init() local xmlFile=xmlLoadFile("config.xml") if xmlFile then local configNode=false configNode=xmlFindSubNode(xmlFile,"classes",0) if configNode then class=true i=1 while class~=false do class=xmlNodeGetAttribute(configNode,"class"..i) if class~=false and class~=nil then accountdat["classes"][i]=class else class=false outputDebugString("No more classes found! " .. i .. " classes were created in total.") end i=i+1 end end local configNode=true i=0 while configNode~=false do configNode=xmlFindSubNode(xmlFile,"user",i) if configNode then local xmlReadName=xmlNodeGetAttribute(configNode,"name") local xmlReadClass=xmlNodeGetAttribute(configNode,"class") accountdat[xmlReadName]={name=xmlReadName, class=xmlReadClass} accountdat[i+1]=accountdat[xmlReadName] else if i<1 then outputDebugString(getResourceName(getThisResource()) .. ": No users were found in the config file! The script won't have any effect!") end configNode=false end i=i+1 end configNode=false configNode=xmlFindSubNode(xmlFile,"colors",0) if configNode then class=true i=1 while class~=false do if accountdat["classes"][i] then class=accountdat["classes"][i] local color=xmlNodeGetAttribute(configNode,class) accountdat["colors"][class]=color else if i<2 then outputDebugString(getResourceName(getThisResource()) .. ": Could not find any classes!") else if xmlNodeGetAttribute(configNode,"member") then accountdat["colors"]["member"]=xmlNodeGetAttribute(configNode,"member") end end class=false end i=i+1 end else outputDebugString(getResourceName(getThisResource()) .. ": No color setting could be found! The script won't have any effect!") end xmlUnloadFile(xmlFile) else outputDebugString(getResourceName(getThisResource()) .. ': No file named "config.xml" found!') end end addEventHandler("onResourceStart",getResourceRootElement(getThisResource()),init) function onPlayerTalk(msg,msgType) -- if getClientAccount(source) and accountdat[getClientName(source)] then if msgType==0 then if accountdat[getClientName(source)] then class=accountdat[getClientName(source)].class else class="member" end color=accountdat["colors"][class] if color then outputChatBox(color .. "[" .. class .. "] " .. getClientName(source) .. ": " .. "#FFFFFF" .. msg,getRootElement(),0,0,0,true) cancelEvent() else if class~="member" then outputDebugString(getResourceName(getThisResource()) .. ": Could not output chat from .. " .. getClientName(source) .. "!") end end end -- else -- outputChatBox("Your nick is equal to the name of a protected account. Please log in to chat.",source,255,0,0) -- end end addEventHandler("onPlayerChat",getRootElement(),onPlayerTalk) function nickChangeProtection(oldNick,newNick) if accountdat[newNick]~=false and accountdat[newNick]~=nil then kickPlayer(source,"Console","Changing nick to a protected nick.") end end --addEventHandler("onClientChangeNick",getRootElement(),nickChangeProtection) If you want, remove the --. Has no effect at all... Lol. Anyway, alot bigger isn't it? And it might be just what you lookin' for. If you need big extra's, (except for the security...) PM me. I'll post this on MTAbeta.com tomorrow. (when I (hopefully) finished the security) And I wish I never said it only took 20 mins.
-
I expect _G etc would hold the function... Or.... Something... And that you meant "onClientClick" instead of "onClientCLick".
-
Send two messages? That's pretty weird... 1 with color and 1 without? If the case I just said, make sure cancelEvent() is present in the code like in my example. The update was all about making your OWN classes, and it is coming along nicely, except for some bugs that'll suck up some of my time, and I love that. So moderator, admin and member are just classes. My script doesn't support tags... (yet) But when you can make your own classes, you can rename moderator to mod for example. The same way you edit colors of the classes right now! I'll devellop this further, and yes... Security has ALWAYS been an issue of mine... Luckily, there are account-functions! Now let's hope I can finish it today or tomorrow, because from saterday till 2 weeks later... I'm outdoors... If I can't make it, please someone else fix it. But let's hope I can finish it myself intime! And I'll post it on that site when it's done. Only when people can actually use it, you should give it. Also: Keep in mind that I'll make the script as editable as possible from the config! Make sure you make as little changes to the script as possible! Very sensitive code to errors... EDIT: Alllrighty then! V1.01 is done except for the security fix! (which probably won't even take 20 minutes) Since it's pointless to release an update now and over 20 minutes, I only give this update now. (in the case anyone needs to know when it's done) But the next look at this post, it'll probably contain the totally changed piece of code.
-
Well, I don't think that's too difficult... Might be quite easy. Make a loop that reads all of those subnodes, then for each subnode you can let it read out and use bindKey(getRootElement(),xmlReadKey,"down",xmlReadFunction)... Or something like that.
-
Yes I know, I didn't have time to fix that bug yet... Getting on it in a few moments. EDIT: Finally the forums work again... I got "500 - Internal Server Error" all the time... Anyway, I fixed the script, and am even updating it FURTHER! So this is the script FOR NOW: (note that it could be the config might not be fully correct, I had to change it for the changes I'm making now...) config.xml <config> <user name="Gamesnert" class="admin"/> <user name="Anyone" class="moderator"/> <colors admin="#FF0000" moderator="#0000FF" member="#FFFFFF"/> </config> Script: -- ************* IMPROVED RELEASE V1.0 *************** -- ************* MADE BY GAMESNERT *************** -- ************* SCRIPTNAME : *************** -- ************* NAMECOLOR (working version) *************** -- ************* A MUST HAVE FOR CLANS!! *************** -- ************* ORIGINAL BY: FATALITRY *************** accountdat={} function init() local xmlFile=xmlLoadFile("config.xml") if xmlFile then local configNode=true i=0 while configNode~=false do configNode=xmlFindSubNode(xmlFile,"user",i) if configNode then local xmlReadName=xmlNodeGetAttribute(configNode,"name") local xmlReadClass=xmlNodeGetAttribute(configNode,"class") accountdat[xmlReadName]={name=xmlReadName, class=xmlReadClass} accountdat[i+1]=accountdat[xmlReadName] else if i<1 then outputDebugString(getResourceName(getThisResource()) .. ": No users were found in the config file! The script won't have any effect!") end end i=i+1 end configNode=false configNode=xmlFindSubNode(xmlFile,"colors",0) if configNode then local readAdmin=xmlNodeGetAttribute(configNode,"admin") local readModerator=xmlNodeGetAttribute(configNode,"moderator") local readMember=xmlNodeGetAttribute(configNode,"member") accountdat["colors"]={["admin"]=readAdmin,["moderator"]=readModerator,["member"]=readMember} else outputDebugString(getResourceName(getThisResource()) .. ": No color setting could be found! The script won't have any effect!") end end end addEventHandler("onResourceStart",getResourceRootElement(getThisResource()),init) function onPlayerTalk(msg,msgType) if msgType==0 then if accountdat[getClientName(source)] then class=accountdat[getClientName(source)].class else class="member" end local color=accountdat["colors"][tostring(class)] outputChatBox(color .. "[" .. class .. "] " .. getClientName(source) .. ": " .. "#FFFFFF" .. msg,getRootElement(),0,0,0,true) cancelEvent() end end addEventHandler("onPlayerChat",getRootElement(),onPlayerTalk) Extra feature in next version: Your own classes by editing config.xml! Will be done soon, only still have a few bugs
-
Topic name: nameColor, right underneath this one.
-
Ok, I'll test when I'm further with this. The messed up code needs to be fixed, and it looks like it's almost done.
