Jump to content

Textures


BabY

Recommended Posts

Hey all, I Think you Remember me xD

Well, Back to Real

I Had a Problem While Changing a Texture of an Object in my Race Map

My Script :

function Texture () 
lol = engineLoadTXD("ballysign01.txd")  
engineImportTXD (lol, 8394 ) 
  
end 
addEventHandler( "onClientResourceStart", resourceRoot, Texture ) 

Debug Script :

titledxd.png

Well,

I Suspect The Error in the Event :)

And, I Searched in the Wiki, and Every Thing, But I Couldn't Find a Way for it :'(

So, After all my Ideas Gone, I'am Posting Here, Willing to Find da Answer :?:

Link to comment
function replace() 
  
    txd = engineLoadTXD("ballysign01.txd") 
  
    setTimer (function() 
     
        engineImportTXD(txd, 8394) 
end,2000,1,txd) 
end 
addEventHandler('onClientResourceStart', resourceRoot, replace) 
addCommandHandler ( "replace", replace) 

Check file maybe have other name

edit:

in meta.xml

<meta> 
    <info author="MI550" version="0.1" type="script" /> 
    <file src="ballysign01.txd" type="client" /> 
    <script src="textures.lua" type="client" /> 
</meta> 

Edited by Guest
Link to comment
function replaceTXD()  
  
txd = engineLoadTXD("ballysign01.txd") 
  engineImportTXD(txd, 8394) 
  
end 
addEventHandler ( "onClientResourceStart", getResourceRootElement(getThisResource()), replaceTXD) 

and in meta.xml add;

<script src="textures.lua" type="client" /> 
<file src="ballysign01.txd" /> 
<map src="yourmap.map" dimension="0" /> 

it should work now

Link to comment

In Fact,

When I Added This Line in the Meta,

My Map Resource Got Bugged O_o

I'am Glad Cuz It's not Damaged and I Can Open it, If not I WIll Kill you xD

The Resource Got Corrupted, But only When Testing ...

I'll Try to Delete Editor_Test and Editor_Dumb and Try ^^

Greetz.

Link to comment

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...