DrPhoX Posted May 21, 2012 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)
Wei Posted May 21, 2012 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 Diet with russian vodka, lose 3 days in one week !
Alpha Posted May 21, 2012 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) My Resources: [REL] Support System v1.0.2
DrPhoX Posted May 21, 2012 Author Posted May 21, 2012 Blazy, don't work --- Alpha... working! Thank you so much
Alpha Posted May 21, 2012 Posted May 21, 2012 You're welcome. My Resources: [REL] Support System v1.0.2
top sniper Posted May 21, 2012 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" ================================================================== ~|منٌ رأيّتُموِۂ يّعتُدُيّ على عرض فُتُٱة مؤمنٌة فُٱسًحًقَوِوِوِوِوِوِوِة|~ ==================================================================
Wei Posted May 21, 2012 Posted May 21, 2012 Sorry my bad Diet with russian vodka, lose 3 days in one week !
Jaysds1 Posted May 22, 2012 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) My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
Alpha Posted May 22, 2012 Posted May 22, 2012 Alpha... working! Thank you so much Already solved. My Resources: [REL] Support System v1.0.2
Jaysds1 Posted May 22, 2012 Posted May 22, 2012 oh, lol, My bad My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
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