Hello all, i have a question...
it's a real to replace original elegy paintjob with a new one??
this is my script, but it don't works... anybody can help me plz?)
function replaceModel()
txd = engineLoadTXD("data/elegy.txd", 562 )
engineImportTXD(txd, 562)
one = engineLoadTXD("data/elegy1.txd", 562 )
engineImportTXD(txd, 562)
two = engineLoadTXD("data/elegy2.txd", 562 )
engineImportTXD(txd, 562)
three = engineLoadTXD("data/elegy3.txd", 562 )
engineImportTXD(txd, 562)
end
addEventHandler ( "onClientResourceStart", getResourceRootElement(getThisResource()), replaceModel)
addCommandHandler ( "reloadcar", replaceModel )
and the 2nd script...
function applyMods(res)
if (res==getThisResource()) then
local ref = engineLoadTXD ( "data/elegy.txd" )
engineImportTXD ( ref, 562 )
end
end
addEventHandler("onClientResourceStart", getRootElement(), applyMods)
local ref = engineLoadTXD ( "data/elegy2.txd" )
engineImportTXD ( ref, 562, 2 )
end
end
addEventHandler("onClientResourceStart", getRootElement(), applyMods)
local ref = engineLoadTXD ( "data/elegy1.txd" )
engineImportTXD ( ref, 562, 1 )
end
end
addEventHandler("onClientResourceStart", getRootElement(), applyMods)
local ref = engineLoadTXD ( "data/elegy3.txd" )
engineImportTXD ( ref, 562, 3 )
end
end
addEventHandler("onClientResourceStart", getRootElement(), applyMods)