Hotspots don't move if they inherited from custom class
Posted: Sun Jun 17, 2007 4:21 pm
I've tried to customize hotspot through action script and if I specify base class for hotspot's movieclip then hotspot will be created but won't move along with pano.
Action Script class:
The code which creates hotspot:
Output window
(Note: second line appears after pano.addHotspot invoking):
Any suggestions?
Action Script class:
Code: Select all
class Hotspot extends MovieClip
{
public function Hotspot()
{
trace("Hotspot " + _name + " activated.");
}
}
Code: Select all
var hotSpot: MovieClip = _root.attachMovie("MyHotspot", id, _root.getNextHighestDepth());
m_vr.pano.addHotspot(id, pan, tilt, hotSpot);
(Note: second line appears after pano.addHotspot invoking):
Code: Select all
Hotspot hs1 activated.
Hotspot undefined activated.
Any suggestions?