Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...

Icecage

Members
  • Posts

    6
  • Joined

  • Last visited

Icecage's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. sorry I missed something on my code in my first reply It actually worked after I added this line to enter frame event blitMask.update(null, true); Thanks a lot for your help, sorry for the troubles
  2. I followed your advice, set autoUpdate to false blitMask = new BlitMask(this, x, y, width, blockHeight * 5, false, [b]false[/b], 0xFFFFFF, true); And I put this in EnterFrame event: blitmask.update(null, true); the dynamic text still doesn't get updated If this is relevant at all, I'm working on a scrolling calendar which followed this tutorial I added a startDrag on the blitmask on mousedown event.
  3. Hi, how would I change a dynamic text after I use blitmask blitMask = new BlitMask(this, x, y, width, blockHeight * 5, false, true, 0xFFFFFF, true); I tried to: blitMask.disableBitmapMode(); dynamicText.text = "BLABLA"; blitMask.enableBitmapMode(); blitMask.dispose(); dynamicText.text = "BLABLA"; blitMask = new BlitMask(this, x, y, width, blockHeight * 5, false, true, 0xFFFFFF, true); but nothing works. Any advice on how I can achieve this?
  4. You were right, it's the rectangle. 40 * _rowMax * 3 was leftover of my previous code. The value 3 was because I used 3 containers to make it seamless (before I'm aware of existence of blitmask) Sorry, my bad. Thanks for the reply
  5. Yeah it supposed to tween all the targets to the end of the list (for testing purpose) and then repeat from the first element. It doesn't loop back.
  6. I seem to have a problem trying to make an infinite scroller by using blitmask's wrap mode. It just won't repeat. private function drawCalendar():void { for (var i:int = 0; i < 4; i++) //type { var _rowMax:int; var _curWidth:Number; switch(i) { case 0: _rowMax = 12; _curWidth = 100; break; case 1: _rowMax = 31; _curWidth = 75; break; case 2: _rowMax = 24; _curWidth = 75; break; case 3: _rowMax = 12; _curWidth = 75; break; } for (var j:int = 0; j < _rowMax; j++) { var d:Dimension_Sp = new Dimension_Sp(i, j); d.y = 40 * j; d.txt.width = _curWidth; containerVector[i].addChild(d); } containerVector[i].maxValue = _rowMax; containerVector[i].x = previousWidth; containerVector[i].graphics.beginFill(0xCCCCCC); containerVector[i].graphics.drawRect(0, 0, _curWidth, 40 * _rowMax * 3); containerVector[i].graphics.endFill(); addChild(containerVector[i]); var blitMask:BlitMask = new BlitMask(containerVector[i], containerVector[i].x, containerVector[i].y, containerVector[i].width, 40, true, true, 0xFFFFFF, true); blitMask.enableBitmapMode(); blitMask.wrap = true; blitMask.autoUpdate = true; blitMask.update(null, true); blitMask.addEventListener(MouseEvent.CLICK, onClick, false, 0, true); previousWidth += _curWidth; } } private function onClick(e:MouseEvent):void { var myTarget:Dimension_Container = (e.target).target; TweenMax.to(myTarget, 3, { y:-myTarget.maxValue*40} ); }
×