Search Results

Search found 6496 results on 260 pages for 'neon flash'.

Page 71/260 | < Previous Page | 67 68 69 70 71 72 73 74 75 76 77 78  | Next Page >

  • Make a turn based system like final fantasy in AS3

    - by Kaoru
    i wanted to make a turn based system like final fantasy tactics. I already created the map, which is 5x5 tiles grid and the characters which is each character places in the end of the tiles. I have 2 teams, which are named Red and Yellow. ------Red-------: First character is at 0,0. Second character is at 0,1. Third character is at0.2, fourth character is at0.3, and the last one is at0.4`. -----Yellow------: First character is at 5.0. Second character is at 5.1. Third character is at 5.2, fourth character is at 5.3, and the last one is at 5.4. I wanted Red team are moving first and make a decision (whether it is attack or wait), and after 5 characters of the Red team is already made a decision, the Yellow team is the one that make a decision (Yellow team is an AI) But, i don't know how to move my characters into the next grid (e.g: from 0,0 to 0,1) by clicking the left mouse button and also how do i display a grid (when select a move selection) that shows how many tiles that the character able to move. Anyone know about this? or how should i know more about this? is there any recommendations books or webs? And also, i don't know how to move the characters using mouse click.

    Read the article

  • What would be a good game making engine supporting Vector images?

    - by Qqwy
    I want to create a simple platforming game, in which you are a square in a wonderful world. I would like this game to be able to be played in browsers. Basically I am searching for something similar to "Flixel", but with the following features: Support Vector Graphics Allow zooming/rotating objects without producing huge amounts of lag as soon as you are using more objects. (Because I want to rotate the map around the player) So in other words, preferably zoom the viewport/camera instead of the objects themselves. Does an engine like that exist?

    Read the article

  • AS3 How to check on non transparent pixels in a bitmapdata?

    - by Opoe
    I'm still working on my window cleaning game from one of my previous questions I marked a contribution as my answer, but after all this time I can't get it to work and I have to many questions about this so I decided to ask some more about it. As a sequel on my mentioned previous question, my question to you is: How can I check whether or not a bitmapData contains non transparent pixels? Subquestion: Is this possible when the masked image is a movieclip? Shouldn't I use graphics instead? Information I have: A dirtywindow movieclip on the bottom layer and a clean window movieclip on layer 2(mc1) on the layer above. To hide the top layer(the dirty window) I assign a mask to it. Code // this creates a mask that hides the movieclip on top var mask_mc:MovieClip = new MovieClip(); addChild(mask_mc) //assign the mask to the movieclip it should 'cover' mc1.mask = mask_mc; With a brush(cursor) the player wipes of the dirt ( actualy setting the fill from the mask to transparent so the clean window appears) //add event listeners for the 'brush' brush_mc.addEventListener(MouseEvent.MOUSE_DOWN,brushDown); brush_mc.addEventListener(MouseEvent.MOUSE_UP,brushUp); //function to drag the brush over the mask function brushDown(dragging:MouseEvent):void{ dragging.currentTarget.startDrag(); MovieClip(dragging.currentTarget).addEventListener(Event.ENTER_FRAME,erase) ; mask_mc.graphics.moveTo(brush_mc.x,brush_mc.y); } //function to stop dragging the brush over the mask function brushUp(dragging:MouseEvent):void{ dragging.currentTarget.stopDrag(); MovieClip(dragging.currentTarget).removeEventListener(Event.ENTER_FRAME,erase); } //fill the mask with transparant pixels so the movieclip turns visible function erase(e:Event):void{ with(mask_mc.graphics){ beginFill(0x000000); drawRect(brush_mc.x,brush_mc.y,brush_mc.width,brush_mc.height); endFill(); } }

    Read the article

  • GA-P31-S3G motherboard usb flash drive boot

    - by user1048125
    I currently trying to understand if my motherboard supports booting from USB flash drive or not... In motherboard manual it written: "First/Second/Third Boot DeviceSpecifies the boot order from the available devices. Use the up or down arrow key to select adevice and press to accept. Options are: Floppy, LS120, Hard Disk, CDROM, ZIP,USB-FDD, USB-ZIP, USB-CDROM, USB-HDD, LAN, Disabled" Is there way to boot from 8GB USB flash drive?

    Read the article

  • RTS style fog of war woes

    - by Fricken Hamster
    So I'm trying to make a rts style line of sight fog of war style engine for my grid based game. Currently I am getting a set of vertices by raycasting in 360 degree. Then I use that list of vertices to do a graphics style polygon scanline fill to get a list of all points within the polygon. The I compare the new list of seen tiles and compare that with the old one and increment or decrement the world vision array as needed. The polygon scanline function is giving me trouble. I'm mostly following this http://www.cs.uic.edu/~jbell/CourseNotes/ComputerGraphics/PolygonFilling.html So far this is my code without cleaning anything up var edgeMinX:Vector.<int> = new Vector.<int>; var edgeMinY:Vector.<int> = new Vector.<int>; var edgeMaxY:Vector.<int> = new Vector.<int>; var edgeInvSlope:Vector.<Number> = new Vector.<Number>; var ilen:int = outvert.length; var miny:int = -1; var maxy:int = -1; for (i = 0; i < ilen; i++) { var curpoint:Point = outvert[i]; if (i == ilen -1) { var nextpoint:Point = outvert[0]; } else { nextpoint = outvert[i + 1]; } if (nextpoint.y == curpoint.y) { continue; } if (curpoint.y < nextpoint.y) { var curslope:Number = ((nextpoint.y - curpoint.y) / (nextpoint.x - curpoint.x)); edgeMinY.push(curpoint.y); edgeMinX.push(curpoint.x); edgeMaxY.push(nextpoint.y); edgeInvSlope.push(1 / curslope); if (curpoint.y < miny || miny == -1) { miny = curpoint.y; } if (nextpoint.y > maxy) { maxy = nextpoint.y; } } else { curslope = ((curpoint.y - nextpoint.y) / (curpoint.x - nextpoint.x)); edgeMinY.push(nextpoint.y); edgeMinX.push(nextpoint.x); edgeMaxY.push(curpoint.y); edgeInvSlope.push(1 / curslope); if (nextpoint.y < miny || miny == -1) { miny = curpoint.y; } if (curpoint.y > maxy) { maxy = nextpoint.y; } } } var activeMaxY:Vector.<int> = new Vector.<int>; var activeCurX:Vector.<Number> = new Vector.<Number>; var activeInvSlope:Vector.<Number> = new Vector.<Number>; for (var scanline:int = miny; scanline < maxy + 1; scanline++) { ilen = edgeMinY.length; for (i = 0; i < ilen; i++) { if (edgeMinY[i] == scanline) { activeMaxY.push(edgeMaxY[i]); activeCurX.push(edgeMinX[i]); activeInvSlope.push(edgeInvSlope[i]); //trace("added(" + edgeMinX[i]); edgeMaxY.splice(i, 1); edgeMinX.splice(i, 1); edgeMinY.splice(i, 1); edgeInvSlope.splice(i, 1); i--; ilen--; } } ilen = activeCurX.length; for (i = 0; i < ilen - 1; i++) { for (var j:int = i; j < ilen - 1; j++) { if (activeCurX[j] > activeCurX[j + 1]) { var tempint:int = activeMaxY[j]; activeMaxY[j] = activeMaxY[j + 1]; activeMaxY[j + 1] = tempint; var tempnum:Number = activeCurX[j]; activeCurX[j] = activeCurX[j + 1]; activeCurX[j + 1] = tempnum; tempnum = activeInvSlope[j]; activeInvSlope[j] = activeInvSlope[j + 1]; activeInvSlope[j + 1] = tempnum; } } } var prevx:int = -1; var jlen:int = activeCurX.length; for (j = 0; j < jlen; j++) { if (prevx == -1) { prevx = activeCurX[j]; } else { for (var k:int = prevx; k < activeCurX[j]; k++) { graphics.lineStyle(2, 0x124132); graphics.drawCircle(k * 20 + 10, scanline * 20 + 10, 5); if (k == prevx || k > activeCurX[j] - 1) { graphics.lineStyle(3, 0x004132); graphics.drawCircle(k * 20 + 10, scanline * 20 + 10, 2); } prevx = -1; //tileLightList.push(k, scanline); } } } ilen = activeCurX.length; for (i = 0; i < ilen; i++) { if (activeMaxY[i] == scanline + 1) { activeCurX.splice(i, 1); activeMaxY.splice(i, 1); activeInvSlope.splice(i, 1); i--; ilen--; } else { activeCurX[i] += activeInvSlope[i]; } } } It works in some cases but some of the x intersections are skipped, primarily when there are more than 2 x intersections in one scanline I think. Is there a way to fix this, or a better way to do what I described? Thanks

    Read the article

  • Update Manager got stuck (but not frozen) while installing downloaded updates. What should I do?

    - by WarriorIng64
    I have just gotten my Ubuntu 12.04 LTS desktop computer reassembled after a trip back home and connected it to my parent's wireless Internet connection. The connection seems quite shaky (disconnects half the time, likely an ongoing issue with the wireless card I have installed), and it struggled to download updates because of the constant interruptions. Eventually, it managed to download the updated packages and started installing them. I got up and left it to do its work. When I came back, I saw it was still having trouble staying connected to the wireless (no surprise there), but then I noticed that it seemed like Update Manager had stopped making progress on the installation. I opened the Details pane to see what it was last doing: My guess was that the installation script for flashplugin-installer couldn't complete the download until I stabilized the Internet connection. I hooked my Ubuntu laptop up to my desktop via Ethernet and shared its wireless connection using this guide, and as I am typing this now from my desktop you can see that the connection issue was successfully worked around. However, even with a stable connection established, Update Manager seems "stuck" at its current position and won't go any further. It's not totally frozen, but I can't do anything beyond open/close the Details pane as the Cancel button is grayed out. I know it can cause big problems if updates are stopped during installation, but I'm at a loss as to how this situation should be handled. I'm sure it should finish normally if I can just find a way to restart Update Manager, but the question is how this should be approached. How can I safely get my updates to finish installing?

    Read the article

  • Creating rescue / install USB flash disk for CentOS

    - by wwwpanda
    For CentOS installation CDs, you can install OS, as well as booting into "rescue" mode so that you can do a chroot mount on the system partition for problem solving, even the system is installed in hardware RAID drives. How can we create a similar thing but on usb flash drive? I tried to do it with unetbootin, but when booting into the USB, eventually the CentOS setup still requires presence of CDs. Ultimately, I want to use this usb flash drive for remote disaster recovery through say HP iLo remote console / Dell iDrac etc.

    Read the article

  • Why does the player fall down when in between platforms? Tile based platformer

    - by inzombiak
    I've been working on a 2D platformer and have gotten the collision working, except for one tiny problem. My games a tile based platformer and whenever the player is in between two tiles, he falls down. Here is my code, it's fire off using an ENTER_FRAME event. It's only for collision from the bottom for now. var i:int; var j:int; var platform:Platform; var playerX:int = player.x/20; var playerY:int = player.y/20; var xLoopStart:int = (player.x - player.width)/20; var yLoopStart:int = (player.y - player.height)/20; var xLoopEnd:int = (player.x + player.width)/20; var yLoopEnd:int = (player.y + player.height)/20; var vy:Number = player.vy/20; var hitDirection:String; for(i = yLoopStart; i <= yLoopEnd; i++) { for(j = xLoopStart; j <= xLoopStart; j++) { if(platforms[i*36 + j] != null && platforms[i*36 + j] != 0) { platform = platforms[i*36 + j]; if(player.hitTestObject(platform) && i >= playerY) { hitDirection = "bottom"; } } } } This isn't the final version, going to replace hitTest with something more reliable , but this is an interesting problem and I'd like to know whats happening. Is my code just slow? Would firing off the code with a TIMER event fix it? Any information would be great.

    Read the article

  • My sound is not working, so I'm going to reinstall FYI [closed]

    - by fer
    I've had trouble getting the sound to work in Ubuntu 12.04 I'm running an Acer Aspire 5739g laptop. This is using a clean install. This wasn't a problem when ubuntu first installed. Rather, it was when I ran the updates that it stopped working. I already tried the suggestions on the ubuntu sites and other similar queries, and they haven't fixed it. Something in the updates is making my sound not work. Edit: It turns out that this might be a bug (the sound issue, first paragraph). After reinstall, it happened again (it's not caused by updates at all, or any software, because I fixed it now w/o reinstall). It seems like I replicated it as follows: I changed auto-hide in the behavior tab of Appearance settings by turning it on, and setting the sensitivity to below the recommended setting. Then instead of restarting, I just logged out and back in. The sound stopped working again. I set the behavior settings to default, restarted, and now it's back to normal. Not sure if it's due to only logging out (and not restarting) or b/c I set my sensitivity to a low setting. Not sure if this helps anyone, but thought I'd mention it.

    Read the article

  • When do you say "near ID" / "far ID" when using RTMFP in ActionScript 3?

    - by Panzercrisis
    I've been using RTMFP streaming for around a year in ActionScript 3, and I pretty much know the difference between a near ID and far ID. The near ID is your peer ID, and the far ID is the other guy's peer ID. The problem I'm having is that, to my knowledge, choosing whether to use one term or the other in a given sentence is a little like choosing whether to say "go" or "come". In English, "go" and "come" have opposite meanings, but ironically, they can still be used almost interchangeably. It's because whether you're going or coming is so heavily dependent on perspective, as opposed to anything concrete. Is the choice of words between "near ID" and "far ID" just as ambiguous, or is there some sort of method to the madness? Thanks!

    Read the article

  • Actionscript - Dropping Multiple Objects Using an Array?

    - by Eratosthenes
    I'm trying to get these fireBalls to drop more often, im not sure if im using Math.random correctly also, for some reason I'm getting a null reference because I think the fireBalls array waits for one to leave the stage before dropping another one? this is the relevant code: var sun:Sun=new Sun var fireBalls:Array=new Array() var left:Boolean; function onEnterFrame(event:Event){ if (left) { sun.x = sun.x - 15; }else{ sun.x = sun.x + 15; } if (fireBalls.length>0&&fireBalls[0].y>stage.stageHeight){ // Fireballs exit stage removeChild(fireBalls[0]); fireBalls.shift(); } for (var j:int=0; j<fireBalls.length; j++){ fireBalls[j].y=fireBalls[j].y+15; if (fireBalls[j].y>stage.stageHeight-fireBall.width/2){ } } if (Math.random()<.2){ // Fireballs shooting from Sun var fireBall:FireBall=new FireBall; fireBall.x=sun.x; addChild(fireBall); fireBalls.push(fireBall); } }

    Read the article

  • Why does my FPS drop gradually over time?

    - by mmankt
    I'm working on this game: yt alpha preview I came into a huge game-breaking problem - after 10-15 min of gameplay the FPS drops from 60 to 30 and is very unstable. I'm using tons of physics and particles, I'm deleting and nulling everything I can after it's supposed to be removed, I remove objects from vectors etc. The memory usage is stable at around 150mb so a leak is unlikely (or invisible?)- after a round ends and I delete everything, play a new round and performance is still terrible. I spent two days trying to figure this out and I just can't fix it. Maybe I'm missing something? I know it's hard to help with no code but I would just have to post my whole source.

    Read the article

  • Dropping multiple objects using an array in Actionscript?

    - by Eratosthenes
    I'm trying to get these fireBalls to drop more often, I'm not sure if I'm using Math.random correctly. Also, for some reason I'm getting a null reference because I think the fireBalls array waits for one to leave the stage before dropping another one? This is the relevant code: var sun:Sun=new Sun var fireBalls:Array=new Array() var left:Boolean; function onEnterFrame(event:Event){ if (left) { sun.x = sun.x - 15; }else{ sun.x = sun.x + 15; } if (fireBalls.length>0&&fireBalls[0].y>stage.stageHeight){ // Fireballs exit stage removeChild(fireBalls[0]); fireBalls.shift(); } for (var j:int=0; j<fireBalls.length; j++){ fireBalls[j].y=fireBalls[j].y+15; if (fireBalls[j].y>stage.stageHeight-fireBall.width/2){ } } if (Math.random()<.2){ // Fireballs shooting from Sun var fireBall:FireBall=new FireBall; fireBall.x=sun.x; addChild(fireBall); fireBalls.push(fireBall); } }

    Read the article

  • Best way to generate pieces in match-3 games, and then tracking them?

    - by JonLim
    I've been working on a match-3 style game in Actionscript using Flixel, and so far, I've been able to build the core mechanics of the game, including board generation, piece generation, piece swapping and movement, and checking algorithms. However, I am now running into issues with clearing out pieces and letting the above pieces fall down and generating new pieces. The reason I'm running into these issues is that when all of the pieces are generated, the pertinent values (position, sprite ID, and sprite object) are pushed into an array that helps me track everything, all the time. When pieces are moved, I swap the values of the corresponding arrays and life goes on. And that array is the core of my problem: if a row in the middle of the board clears out, ideally, all of the pieces above the cleared pieces should fall down to take their place and new pieces are generated at the top and also fall into place. Except if I try to do that now, all the pieces can fall down, but then I'd have to bump all of their values into the right arrays (oh god my head) and then generate new pieces and fit THOSE into the correct place in the array. Am I overthinking this? Or is there a far better way to track these pieces? Thanks guys!

    Read the article

  • Collision for mobile game

    - by zemiguel12
    I'm writing a little game in as3 using Starling, and I need to check collision between 2 boats that can rotate. I don't need the pixel perfect collision, but bounds collision is not enough too. The boat look more or less like this: I was thinking about create one square on the back of the boat and a triangle on the front, than for each boat, check if the square collide with the other boat square or triangle, and the same for the triangle. I just don't know how to do that, I don't know if it's possible with the Shape.hitTest, or if it's the best way to do that. What can I do?

    Read the article

  • Large Sprite Performance

    - by Iansen
    I've got a large Sprite generated using a set of vertices(x,y coordinates) and a bitmap pattern (using moveTo, lineTo, beginBitmapFill, endFill ...etc). It's about 15000 pixels wide and between 1500 - 2000 pixels high depending on the level -it's the terrain for a 2D game. My question is: what is the best way to display/move it on the stage - performance wise? Currently I'm just adding it to the stage as is...I get decent frame rate/ memory/ cpu usage but I want to optimize it for slower PCs. Any ideas? I've been reading a little about blitting but I'm not sure how to implement it in my case. Thanks.

    Read the article

  • How to fix: "NPMethod called on non-NPObject wrapped JSObject" error?

    - by chandra
    HI, I am trying to call a method defined in flash object from javascript (firefox-3.0/Linux) and getting the exception: "NPMethod called on non- NPObject wrapped JSObject". If I use eval on window.document.flash_object.func() it throws "NPMethod called on non-NPObject wrapped JSObject". Where as, if I define a javascript function in side the page as given below: function myFunc() { return flash_object.func(); } and later do a eval of window.document.myFunc() it works fine. I am running the two evals through a test framework called Selenium. [eval(window.document.flash_object.func()) and eval(window.document.myFunc())]. The issues seems to be issue with invoking the flash-object method without passing 'this' reference. Here is sample html/js code to reproduce this issue: "NPMethod called on non-NPObject wrapped JSObject". <script> function changeColor() { mymovie.changeColor(); } function getColorNP() { var func = mymovie.getColor; func(); } </script> <button type="button" onclick="getColorNP();">getColorNP</button> <button type="button" onclick="getColor();">getColor</button> getColorNP throws the exception Error: NPMethod called on non-NPObject wrapped JSObject! Source File: http://my.host/Colors/colors.html getColorNP throws the exception Error: NPMethod called on non-NPObject wrapped JSObject! Source File: http://my.host/Colors/colors.html Now, question to javascript gurus: Given flash object and a method name, how do I invoke the method on that object. Lets say, a function takes two arguments: a flash object, and a method name as string. I want to do an eval on object.method() inside that function. Is this possible, if so, can you please explain me how this can be done. As flash object's method is not a standard javascript function, i think its not possible to function binding through bind(). Is there any other alternative? Thx, Chandra

    Read the article

  • Anyone else unable to listen to uncaughtErrorEvent when loaded by another swf?

    - by aaaidan
    When I try to access the uncaughtErrorEvents dispatcher when loaded directly, everything works well. But when I try the same code when loaded by another swf I get a reference error. protected function onAddedToStage(e:Event):void { trace("Flash version: " + Capabilities.version); try { loaderInfo.uncaughtErrorEvents.addEventListener("uncaughtError", onUncaughtError); trace("YAY!"); } catch (e:Error) { trace(e); } } Output when loaded directly (in browser): Flash version: MAC 10,1,53,64 YAY! Output when loaded by another "loader" SWF: Flash version: MAC 10,1,53,64 ReferenceError: Error #1069: Property uncaughtErrorEvents not found on flash.display.LoaderInfo and there is no default value. If others can replicate this I'd be appreciative. EDIT: Also have tried this with stage.loaderInfo, instead of just loaderInfo. Same issue...

    Read the article

  • ActionScript 3 and camelcase package name

    - by Paul Dinh
    I'm using Flash Builder 4 to build my AIR application. For a certain reason, I need to declare my package name in camelcase, and class names in lowercase: //test.as package Core { public class test { } } The folder structure is like this (the dir 'Core' matches the package name): src/ Core/ test.as However, Flash Builder shows error and it doesn't compile at all, only when I put the package name as 'core' then it compiles. Does AS3 syntax allow uppercase letters in package name? Or just because Flash Builder implicitly disallows this?

    Read the article

  • How to pass PHP variable as FlashVars via SWFObject

    - by Matt
    I am trying to take a PHP variable and pass it along to Flash via Flash vars. My end goal is to pass a string formatted as XML to Flash, but because I'm struggling I've stripped everything down to the basics. I'm just trying to pass a simple PHP string variable to Flash via FlashVars with SWFObject but something isn't right. The page won't load when I try to pass the variable inside of php tags, but it will load if I just pass a hard coded string. The basic structure of my page is that I have some PHP declared at the top like so: PHP <?php $test = "WTF"; ?> Some HTML (excluded here for simplicity sake) and then the JavaScript SWFObject Embed within my HTML: <script type="text/javascript" src="js/swfobject2.js"></script> <script type="text/javascript"> // <![CDATA[ var swfURL = "swfs/Init-Flash-PHP.swf"; var flashvars = {}; flashvars.theXML = <?php print $test ?>; var params = {}; //params.menu = "false"; params.scale = "showAll"; params.bgcolor = "#000000"; params.salign = "TL"; //params.wmode = "transparent"; params.allowFullScreen = "true"; params.allowScriptAccess = "always"; var attributes = {}; attributes.id = "container"; attributes.name = "container"; swfobject.embedSWF(swfURL, "container", '100%', '100%', "9.0.246", "elements/swfs/expressinstall.swf", flashvars, params, attributes); // ]]> </script> And the bare essentials of the ActionScript 3 Code: _paramObj = LoaderInfo(stage.loaderInfo).parameters; theText_txt.text = _paramObj['theXML']; How do I pass a PHP variable using SWFObject and FlashVars? Thanks.

    Read the article

  • Returning errors from AMFPHP on purpose.

    - by Morieris
    When using flash remoting with amfphp, what can I write in php that will trigger the 'status' method that I set up in my Responder in Flash? Or more generally, how can I determine if the service call has failed? The ideal solution for me would be to throw some exception in php serverside, and catch that exception in flash clientside... How do other people handle server errors with flash remoting? var responder = new Responder( function() { trace("some normal execution finished successfully. this is fine."); }, function(e) { trace("how do I make this trigger when my server tells me something bad happened?"); } ); myService = new NetConnection; myService.connect("http://localhost:88/amfphp/gateway.php"); myService.call("someclass.someservice", responder);

    Read the article

  • swfobject weird behavior

    - by David
    Hi All, I'm using swfobject to embed my flash. It's doing weird things. I've created a simple textfield using FlexBuilder. It's an AS3 project, which extends Sprite. I've set its width to be 640 and height to 450. Then, in the swfobject parameters of the page, I've also set 640 x 450. I've made the background nice and red and ugly so you can see it. :) http://www.brighttext.com/flash/TextFieldSetFormat.html It seems to be the right dimensions. BUT I've got a textfield which is supposed to be almost the same size and height. This runs fine in FlexBuilder (is the right size) but is all messed up once I add swfobject Can anyone see what is happening? EDIT NOTE: I just looked at it and it looks ok. But then I refreshed the page and the textfield is postage-stamp size (again -- this is the original behavior I saw.) It's now looking OK in firefox but not in IE8. Flash is supposed to look the same in all browsers !!?? AS3 code: package { import flash.display.Sprite; import flash.text.TextField; import flash.text.TextFormat; import flash.text.Font; [SWF(width="640", height="450", backgroundColor="#FFFFFF", frameRate="30")] public class TextFieldSetFormat extends Sprite { [Embed(source='C:/WINDOWS/Fonts/ArialBD.TTF', fontWeight = 'bold', fontName='ArialBold')] [Embed(source='C:/WINDOWS/Fonts/Arial.TTF', fontWeight = 'regular', fontName='Arial')] public function TextFieldSetFormat() { var tf2:TextFormat = new TextFormat(); tf2.size = 16; tf2.font = "Arial"; Font.registerFont(_VerdanaFontBold); Font.registerFont(_VerdanaFont); var pad:Number = 10; var brightTextField:TextField = new TextField; brightTextField.backgroundColor = 0xDDF3B2; brightTextField.background = true; brightTextField.embedFonts = true; brightTextField.border = true; brightTextField.defaultTextFormat = tf2; brightTextField.wordWrap = true; brightTextField.multiline = true; brightTextField.width = stage.stageWidth - (4 * pad); brightTextField.height = stage.stageHeight - (3 * pad); brightTextField.x = 2*pad; brightTextField.y = 2*pad; brightTextField.text = "Dear Senators, I have become concerned over the idea that some in the Senate will oppose the public option because of a group of wild-eyed, overbearing but misinformed ideologues. These people mistakenly equate insurance reform with Socialism and call our first African-American President unprintable epithets. This is unacceptable. The public option is the choice of more than 70% of Americans, a majority of the House and a great many opinion leaders. Passing insurance reform without a public option persists the current broken system. I am aware that many Senators would prefer to pass a reform bill with bipartisan support. But we cannot allow this critical debate to be hijacked by extremists or corporate profiteers. Thank you, and I look forward to hearing from you."; addChild(brightTextField); } } }

    Read the article

  • reference parent class function in AS 3.0

    - by vasion
    I am trying to run a function of the main class, but even with casting it does not work. I get this error TypeError: Error #1009: Cannot access a property or method of a null object reference. at rpflash.communication::RPXMLReader/updateplaylist() at rpflash.communication::RPXMLReader/dataHandler() at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::XMLSocket/scanAndSendEvent() this is the main class code package{ import flash.display.MovieClip; import rpflash.communication.RPXMLReader; public class Main extends MovieClip{ var reader:RPXMLReader = new RPXMLReader(); public function Main(){ trace('Main actionscript loaded'); } public function test(){ trace('test worked');} } } and this is the function trying to call it: private function updateplaylist(){ //xml to string var xmls:String= xml.toXMLString(); trace('playlist updated debug point'); MovieClip(this.parent).test();} what am i doing wrong?

    Read the article

< Previous Page | 67 68 69 70 71 72 73 74 75 76 77 78  | Next Page >