DrPhoX Posted May 21, 2012 Share Posted May 21, 2012 Hey, i created VERY simple script but don't work -.- ... I'm beginner on Lua scripting. Can someone help me please? addEventHandler ("onPlayerJoin", getRootElement(), function(decoration) local decoration = "================================================" outputChatBox(" .. decoration .. ", thePlayer, 38, 98, 188, true) outputChatBox("#ffffffWelcome to #2662bc=(RfC)= #ffffffserver", thePlayer, 38, 98, 188, true) outputChatBox("#ffffffDon't forgot to visit our webiste!", thePlayer, 38, 98, 188, true) outputChatBox("#848484www.website.eu", thePlayer, 38, 98, 188, true) outputChatBox(" .. decoration .. ", thePlayer, 38, 98, 188, true) end end) Link to comment
Wei Posted May 21, 2012 Share Posted May 21, 2012 addEventHandler ("onPlayerJoin", getRootElement(), function(thePlayer) local decoration = "================================================" outputChatBox(decoration, thePlayer, 38, 98, 188, true) outputChatBox("#ffffffWelcome to #2662bc=(RfC)= #ffffffserver", thePlayer, 38, 98, 188, true) outputChatBox("#ffffffDon't forgot to visit our webiste!", thePlayer, 38, 98, 188, true) outputChatBox("#848484www.website.eu", thePlayer, 38, 98, 188, true) outputChatBox(decoration, thePlayer, 38, 98, 188, true) end end) Try Link to comment
Alpha Posted May 21, 2012 Share Posted May 21, 2012 addEventHandler ("onPlayerJoin", root, function() local decoration = "================================================" outputChatBox(decoration , source, 38, 98, 188, true) outputChatBox("#ffffffWelcome to #2662bc=(RfC)= #ffffffserver", source, 38, 98, 188, true) outputChatBox("#ffffffDon't forgot to visit our webiste!", source, 38, 98, 188, true) outputChatBox("#848484www.website.eu", source, 38, 98, 188, true) outputChatBox(decoration, source, 38, 98, 188, true) end) Link to comment
DrPhoX Posted May 21, 2012 Author Share Posted May 21, 2012 Blazy, don't work --- Alpha... working! Thank you so much Link to comment
top sniper Posted May 21, 2012 Share Posted May 21, 2012 addEventHandler ("onPlayerJoin", getRootElement(), function(thePlayer) local decoration = "================================================" outputChatBox(decoration, thePlayer, 38, 98, 188, true) outputChatBox("#ffffffWelcome to #2662bc=(RfC)= #ffffffserver", thePlayer, 38, 98, 188, true) outputChatBox("#ffffffDon't forgot to visit our webiste!", thePlayer, 38, 98, 188, true) outputChatBox("#848484www.website.eu", thePlayer, 38, 98, 188, true) outputChatBox(decoration, thePlayer, 38, 98, 188, true) end end) Try end end) ? It should be one "end" Link to comment
Jaysds1 Posted May 22, 2012 Share Posted May 22, 2012 lol, try this: addEventHandler("onPlayerJoin",root,function() -- There's no parameters local decoration = "================================================" outputChatBox(" "..decoration.." ",source, 38, 98, 188, true) -- You need to end the quote then add the string you want, or just put the variable instead of the quotes outputChatBox("#ffffffWelcome to #2662bc=(RfC)= #ffffffserver", source, 38, 98, 188, true) outputChatBox("#ffffffDon't forgot to visit our webiste!", source, 38, 98, 188, true) outputChatBox("#848484www.website.eu", source, 38, 98, 188, true) outputChatBox(" ".. decoration .." ", source, 38, 98, 188, true) end end) Link to comment
Alpha Posted May 22, 2012 Share Posted May 22, 2012 Alpha... working! Thank you so much Already solved. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now