Jump to content

login message


[DMC]

Recommended Posts

Posted (edited)

LOOK AT 3rd Post

function addPlayer() 
local playeraccount = getPlayerAccount(source) 
if not isGuestAccount(playeraccount) then 
local accountname = getAccountName(playeraccount) 
CheckPlayer = executeSQLSelect ( "PlayersData", "accountname", "accountname = '" .. accountname .. "'" ) 
if ( type( CheckPlayer ) == "table" and #CheckPlayer == 0 ) or not CheckPlayer then  
executeSQLInsert ( "PlayersData", "'".. accountname .."','0','0','0','0','FF0000','00FF00','None','None/None','I love DMC','0','0'" ) 
end 
end 
local playeraccount = getPlayerAccount(source) 
if not isGuestAccount(playeraccount) then 
local accountname = getAccountName(playeraccount) 
local data = executeSQLQuery("SELECT * FROM PlayersData where accountname = '" .. accountname .. "'") 
outputChatBox(getPlayerName(source).. " login and says: ".. data[1]["LoginMsg"] .."!",root,0,255,0,true) 
setElementData(source,"ageNsex",data[1]["AgeNSex"]) 
setElementData(source,"contact",data[1]["Contact"]) 
setElementData(source,"message",data[1]["LoginMsg"]) 
setElementData(source,"skin",data[1]["Skin"]) 
setElementData(source,"NC",data[1]["NameC"]) 
setElementData(source,"CC",data[1]["ChatC"]) 
setElementData(source,"CarColor",data[1]["CarColor"]) 
end 
end 
addEventHandler("onPlayerLogin",getRootElement(), addPlayer) 

Edited by Guest
logo_left.png
Posted

You want this

outputChatBox(getPlayerName(source).. " login and says: ".. data[1]["LoginMsg"] .."!",root,0,255,0,true) 

output to be printed after 2 secs?

if yes then use,

setTimer(outputChatBox,2000,1,getPlayerName(source).. " login and says: ".. data[1]["LoginMsg"].."!",getRootElement(),0,255,0,true) 

Admin.png
Posted

srry this is not needed at all, i will explain my situation

My friend solidsnake/castillo

made a script for me that alows A player to login to his nick only

not any other names

But when someone does a login to an other name its still saying outPutChatbox :cry:

logo_left.png
Posted

how somebody can login to other name when this is not possible with solid's login script?

/login command?

block this in acl then, should be possible.

Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online!

programista php rzeszów

Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting.

Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...