Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local connection = exports["dm_core"]:getConnection()
- addEventHandler("onElementDataChange", root,
- function(dataName, ovalue)
- if dataName == "newSkin" then
- local value = getElementData(source, dataName)
- setElementData(source,"char.Skin",value)
- setElementModel(source, value)
- local id = getElementData( source, "dbid" )
- dbExec(connection,"UPDATE `characters` SET `skin`=? WHERE `id`=?",value,id)
- end
- end
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement