eldelahoz Posted April 25, 2013 Share Posted April 25, 2013 Hola esto sonara un poco noob pero bueno quiero saber como puedo saber si el script es client o server ¡Saludos! Link to comment
Sasu Posted April 25, 2013 Share Posted April 25, 2013 Argumentos, eventos y funciones. Yo me guio por eso. Link to comment
NodZen Posted April 25, 2013 Share Posted April 25, 2013 Yo me guio por los eventos. Por ejemplo: Si es onPlayerJoin, es server. Link to comment
eldelahoz Posted April 25, 2013 Author Share Posted April 25, 2013 Entonces por ejemplo este seria server? objeto = createObject ( 16773, 811.09997558594, 889.40002441406, 775.59997558594, 0, 0, 0 ) x,y,z = getElementPosition (objeto) Zona = createColSphere ( x, y, z, 15 ) function funcion (hitElement) local skin = getPlayerSkin ( hitElement ) if skin == 100 then moveObject ( objeto, 800, 798.09997558594, 889.40002441406, 775.59997558594 ) end end addEventHandler ( "onColShapeHit", Zona, funcion ) function funcion2 (hitElement) local skin = getPlayerSkin ( hitElement ) if skin == 100 then moveObject ( objeto, 800, 811.09997558594, 889.40002441406, 775.59997558594 ) end end addEventHandler ( "onColShapeLeave", Zona, funcion2 ) Link to comment
PhantomDamn Posted April 25, 2013 Share Posted April 25, 2013 yo me guio si el recurso es global o personal... pero es mas recomendable guiarte por los eventos Link to comment
Recommended Posts