Jump to content

Recommended Posts

Posted

ola pessoal nao intendo gringo e nao consegui achar o script pra colokar musica no mapa auguem pode me passar e me dar um breve tuto de como colokar ?? vlw

Posted

Oi! O script correto é:

Cria 2 arquivos:

client.lua

function playAudio() 
   playSound ( "song.mp3" ) 
end 
addEventHandler ( "onClientResourceStart", resourceRoot, playAudio ) 
  

meta.xml

<meta> 
    <file src="song.mp3" /> 
    <script src="client.lua" type="client" /> 
</meta> 

Vc tem que renomear o arquivo de musica song.mp3 :wink:

"Everything exists, because otherwise nothing would", Bob Marley, 2015.

Posted

hmm obrigado esse problema ja foi resolvido mais poderia me diser agora como eu coloko textura em serto objeto ??

obrigado.

Posted

Este problema é muito mais complexa, você sabe que é um arquivo TXD?

"Everything exists, because otherwise nothing would", Bob Marley, 2015.

Posted

txd.lua

  
    txd = engineLoadTXD ( "data/euros.txd" ) 
    engineImportTXD ( txd, 587 ) --VC TEM Q PONER É ID DO OBJETO!!! 
  

meta.xml

<meta> 
    <script src="client.lua" type="client" /> 
    <file src="txdarquivo.txd" /> 
</meta> 

"Everything exists, because otherwise nothing would", Bob Marley, 2015.

  • 1 month later...
Posted

Eh melhor de fazer un codigo mais limpo :D

  
addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), 
function() 
txd = engineLoadTXD ( "texture.txd" ) 
engineImportTXD ( txd, 500 ) -- O id do seu objeto 
end) 
  
  

Asim e melhor ...

Paid developer. Twitter: @willia_am -

http://www.williamdasilva.fr

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