flash-cs5

Flash CS5 won't execute AS3 code

时间秒杀一切 提交于 2019-12-11 07:35:26
问题 I am getting a strange issue in Flash CS5. I have a .fla file that was working fine up until recently. Now, when I Ctrl-Enter to Test Movie...nothing happens. I have a Document Class set up (and when I click the pencil button, it opens up the right script, so Flash knows where the code is) called Main. In the constructor, there is a trace('Main()') just so I know the constructor got called, but that trace isn't showing up. A few days ago this same code was working fine, so i'm guessing I

Reference MovieClip After it is Added to Stage as a Child

此生再无相见时 提交于 2019-12-11 07:28:43
问题 I am currently having problems referencing a MovieClip child which I add to the Stage from the Document Class. Basically when the MovieClip child is added to the Stage from the Document Class, I want a certain MovieClip already on the Stage to reference it once it is on the Stage . Also, if it is possible , I don't want the MovieClip referencing the child being added to the Stage to have parameters linking it with the Document Class, because I plan on nesting this MovieClip within another

Using embedded fonts with TLFTextField

眉间皱痕 提交于 2019-12-11 07:00:10
问题 I don't know about you but I'm having a really hard time getting my head around TLF. I'm using Flash CS5. I've got an embedded font loaded from an external SWF. As far as I can tell, it's embedded properly - it used to work before I switched from the classic TextField - but I needed to switch because I need the advanced ligature support. My code is: //setting up... var text:TFLTextField = new TLFTextField(); text.width = 530; text.height = 330; text.type = TextFieldType.INPUT; text.text =

Random Pixels Blink White for 1/60th of a Second

♀尐吖头ヾ 提交于 2019-12-11 06:33:37
问题 I am trying to make single pixels flash for 1/60th of a second and then go away over a 2 second period of time until every single pixel on a 1280x720 screen has flashed white. After 2 seconds have elapsed the screen is all black again for 3 or so seconds before it loops and does it again. The way I solved it was using this fla another stackoverflow user came up with and I modified that uses movie clips. The problem is it doesn't work to get 921600 movie clips to start randomly. It gets really

Actionscript 3 - How can i convert from XMLList to XML?

流过昼夜 提交于 2019-12-11 05:43:42
问题 My function is returning XML, so i do: return xml.blah.blah.blah It tells me it can't convert XMLList to XML so i'm guessing xml.blah.blah.blah is a XMLList. How can i do this (convert XMLList to XML)? the simpliest way possible? 回答1: You should be able to just cast the XMLList to XML. Either: XML(xml.blah.blah) or (xml.blah.blah as XML) 回答2: You can access items of an XMLList like you would an array: var booksXML:XML = <Books> <Book ISBN="0000000000"> <title>Title 1</title> <author>Author 1<

Open swf file than works with socket

十年热恋 提交于 2019-12-11 05:19:16
问题 Sorry for my bad English. I have the following problem: I have a .fla file, that works with Socket class. There is a server(written in Delphi XE, but it does not matter). I connect to it from my .fla. When i execute my .fla from within Flash Professional CS5 everything works fine. But when i tried to execute resulting .swf from Explorer(Win 7, Flash Player 10) i got an error: SecurityError: Error #2010: Local-with-filesystem SWF files are not permitted to use sockets. at flash.net::Socket

AS3 Returning a variable from an event listener function

不问归期 提交于 2019-12-11 05:17:28
问题 I'm trying to return XML from an event complete back to the main function, but can't figure out how to do it. Here's the functions I'm calling: Main File: public var mySendAndLoad:SendAndLoad = new SendAndLoad(); mySendAndLoad.sendData(url,variables) The mySendAndLoad class: package { import flash.events.*; import flash.net.*; import flash.xml.XMLDocument; public class SendAndLoad { public var xml:XML = new XML(); public var xmlList:XMLList; public function SendAndLoad() { } public function

PHP Code hinting not working in Dreamweaver CS5

旧巷老猫 提交于 2019-12-11 04:56:11
问题 I'm using Adobe Dreamweaver CS5, I have been using this for a long time, but this is the first time I am facing such issue. Some of the code hintings are disbaled, like $_SERVER , $_REQUEST , etc.. Is there any option to enable these hints? I tried preference option though its disabled. I am missing exactly this: (source: killersites.com) 回答1: Go to menu Edit -> Preferences -> Code Hints and then disable jquery code 1.7 . 回答2: PHP code hinting is turned on in DW options correct? (sorry can't

Adding 2 decimal number gives wrong result in Action Script

风格不统一 提交于 2019-12-10 23:07:34
问题 I have a problem with the following statement trace(10.12+13.75) //output 23.869999999999997 Can anybody explain me why is this so and how to get exact 23.87 out of this? Thanks 回答1: That happens because of the precision of IEEE format. Simplest would be to use toFixed. var num:Number = 10.12+13.75; var numStr:String = num.toFixed(2); var num2:Number = new Number(numStr); 回答2: Computer floating point numbers are not perfectly accurate. JavaScript (and I assume ActionScript, as it's a variant)

How do I remove gloss from an iPhone app icon?

给你一囗甜甜゛ 提交于 2019-12-10 19:07:17
问题 Here is a tutorial that tells you how to remove the gloss on an app in xcode. How can I do this in flash cs5? If I can't, can I do something to the image in photoshop so that it looks like it has no gloss when the gloss is applied? 回答1: In the xml that is generated with your swf go to the node < InfoAdditions > And add the following after <![CDATA[ <key>UIPrerenderedIcon</key><true/> before <key>UIDeviceFamily</key> Then when you compile, you icons will be without gloss 回答2: For the plist,