Simplemente genial, agarraste el script y lo perfeccionaste !, ahora para agregar mas puertas solo cambio las coordenadas y el nombre de la puerta y ya ?...
EDIT: Eh mirado, y editado el script con mis coordenadas y como la otra vez y de varias puertas que coloque solo 1 se movio , lo raro esque hize un copi - paste de lo que pusiste 2 veces, y la segunda funcion de movimiento funciono, la primera no, y eh mirado todo 3 veces... el caso esque quedo asi:
Esta vendria ciendo la Funcion 1, la que no dio:
gates = {}
cols = {}
gates[1] = createObject ( 2929, 233.5244140625, 1822.6572265625, 7.9560956954956, 0, 0, 90 )
cols[1] = createColCircle ( 233.5244140625, 1822.6572265625, 7.9560956954956, 0, 0, 90 )
function openGates(thePlayer)
if source == cols[1] then
if isObjectInACLGroup( 'user.'..getAccountName( getPlayerAccount( thePlayer ) ), aclGetGroup( 'Admin' ) ) and hasObjectPermissionTo( thePlayer, 'function.door', true ) then
moveObject (gates[1], 233.5244140625, 1822.6572265625, 4.4560956954956 )
elseif source == cols[1] then
end
end
end
addEventHandler( "onColShapeHit", getRootElement(), openGates )
function closeGates(thePlayer)
if source == cols[1] then
if isObjectInACLGroup( 'user.'..getAccountName( getPlayerAccount( thePlayer ) ), aclGetGroup( 'Admin' ) ) and hasObjectPermissionTo( thePlayer, 'function.door', true ) then
moveObject (gates[1], 5000, 233.5244140625, 1822.6572265625, 7.9560956954956 )
elseif source == cols[1] then
end
end
end
addEventHandler( "onColShapeLeave", getRootElement(), closeGates )
-----------------------------------------------------------------------------------------------------------------
Y esta vendria siendo la Funcion 2, que si funciono.
gates[2] = createObject ( 980, 235.74890136719, 1806.5189208984, 12.164016723633, 0, 90, 0 )
cols[2] = createColCircle ( 235.74890136719, 1806.5189208984, 12.164016723633, 0, 90, 0 )
function openGates(thePlayer)
if source == cols[2] then
if isObjectInACLGroup( 'user.'..getAccountName( getPlayerAccount( thePlayer ) ), aclGetGroup( 'Admin' ) ) and hasObjectPermissionTo( thePlayer,
'function.door', true ) then
moveObject (gates[2], 5000, 235.74890136719, 1806.5189208984, 15.164016723633 )
elseif source == cols[2] then
end
end
end
addEventHandler( "onColShapeHit", getRootElement(), openGates )
function closeGates(thePlayer)
if source == cols[2] then
if isObjectInACLGroup( 'user.'..getAccountName( getPlayerAccount( thePlayer ) ), aclGetGroup( 'Admin' ) ) and hasObjectPermissionTo( thePlayer,
'function.door', true ) then
moveObject (gates[2], 5000, 235.74890136719, 1806.5189208984, 12.164016723633 )
elseif source == cols[2] then
end
end
end
addEventHandler( "onColShapeLeave", getRootElement(), closeGates )