Flash AS3.0 如何修改这个变量
privatevarpm1:DrawMark=newDrawMark(0xff0000,370,260,20,20,"1");构造函数:packagemyclass{im...
private var pm1:DrawMark = new DrawMark(0xff0000,370,260,20,20,"1");
构造函数:package myclass { import flash.display.Sprite; import flash.text.TextField; public class DrawMark extends Sprite { private var _label:TextField; private var _color:uint; private var _xpos:Number; private var _ypos:Number; private var _w:Number; private var _h:Number; private var _labeltext:String; public function DrawMark(color:uint,xpos:Number,ypos:Number,w:Number,h:Number,labeltext:String):void { _color=color; _xpos=xpos; _ypos=ypos; _w=w; _h=h; _labeltext=labeltext; init(); } private function init():void { graphics.beginFill(_color); graphics.drawRect(_xpos,_ypos,_w,_h); graphics.endFill(); _label = new TextField ; _label.text = _labeltext; _label.autoSize = "left"; _label.x = _xpos+5; _label.y = _ypos+2; addChild(_label); } }}我想加入语句 修改 pm1的(0xff0000,370,260,20,20,"1")内容 如何做? 展开
构造函数:package myclass { import flash.display.Sprite; import flash.text.TextField; public class DrawMark extends Sprite { private var _label:TextField; private var _color:uint; private var _xpos:Number; private var _ypos:Number; private var _w:Number; private var _h:Number; private var _labeltext:String; public function DrawMark(color:uint,xpos:Number,ypos:Number,w:Number,h:Number,labeltext:String):void { _color=color; _xpos=xpos; _ypos=ypos; _w=w; _h=h; _labeltext=labeltext; init(); } private function init():void { graphics.beginFill(_color); graphics.drawRect(_xpos,_ypos,_w,_h); graphics.endFill(); _label = new TextField ; _label.text = _labeltext; _label.autoSize = "left"; _label.x = _xpos+5; _label.y = _ypos+2; addChild(_label); } }}我想加入语句 修改 pm1的(0xff0000,370,260,20,20,"1")内容 如何做? 展开
2013-05-17
展开全部
flash因为安全策略所以无法直接修改服务器上的txt和xml文件,只能通过asp或者java等页面文件改写,你可以查下js和as通信相关方面的文章
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询