oke,
on a new map empty.
Place first the outerring(not animated.
Then place the middle ring(animated) with this script: name the script astragate.lua
-- Starts Astragate animation when player is close (change startupDistance if needed)
-- When 'water' portal opens after animation completes, walking into the portal will
-- transport the player to the entity named in the astragate_ring 'IfUsed' field
-- nb: enter the astragate_center's 'e' number below too!
local astragate_center_e = 3
local startupDistance = 350
--
local open = 0
function astragate_init(e)
Hide(astragate_center_e)
CollisionOn(astragate_center_e)
end
function astragate_main(e)
if GetPlayerDistance(e) < startupDistance then
if open == 0 then
if g_Entity[e]['animating'] == 0 then
SetAnimation(0)
SetAnimationSpeed(e,1)
PlayAnimation(e)
g_Entity[e]['animating'] = 1
open = 1
LoopSound(e,0)
return
end
end
if open == 1 then
if g_Entity[e]['animating'] == 0 then
Show(astragate_center_e)
CollisionOff(astragate_center_e)
StopSound(e,0)
LoopSound(e,1)
open = 2
end
end
if open == 2 then
if GetPlayerDistance(e) < 50 then
TransportToIfUsed(e)
end
end
else
open = 0
StopSound(e,0)
StopSound(e,1)
StopAnimation(e)
Hide(astragate_center_e)
end
end
then place the center piece,this is gonna be the 3 entity.( so the 3 in the script indicated the 3 placed entity)
with this script: named the script stargate_center
function stargate_center_init(e)
weapon_name[e] = "stargate_center"
end
function stargate_center_main(e)
end
the main code astragte.lua, have these lines:
local astragate_center_e = 3 (the 3 is the enity number in the editor)
i hope this helps a bit
edit:
a video of the basic setup: this without the dialer.. so when i also figured out that part i let you know
Harry
Harry
When nothing goes right, go left