Dynamix Text On An Angle/90deg?
I really need to load dynamic text rotated 90deg. It seems it is not possible?
Any way around this without using Images? And if so .. how would I dynamically load an image in a certain x,y cord?
FlashKit > Flash Help > Flash MX
Posted on: 12-22-2003, 11:20 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Dynamix Text
Hi
I have a couple dynamic text fields on my main time, each are symbols. I want to apply a alpha tween to these fields so I set the first frame to 0% and the middle frame to 100% then the last frame to 0% again. I don't see that the alpha is working properly when I test the movie.
Any ideas
Å Ö Ä Etc. In Dynamix Text...
I'me loading an external text into a text field an it all works perfectly except for one thing... the text is in swedish so I need to use letters like å,ä,ö but they don't show up in the result swf. Infact, some of the letters that come after them in the word are erased... What do I need to replace these letters with???
thanks!
ps. I know the font supports these letters...
Dynamix Text
Hello,
Is this possible? - I've got a dynamic text boxes displaying information from an XML file as HTML. My first box, box A, is a list of titles. I've got another box, box B, that I would like to have display a description when you click on a title in box A.
Can I use <a href=""></a> tags and 'target' to target box B? If so, how? If not, is there another way?
Also, my scroll bar in box B is not working. The text extends beyond the range of the box and I cannot scroll. Any suggestion?
Thanks!
Dynamix Text Links
Is there any way at all to perform actions in the movie when you click a link in a dynamic text box? I'm trying to put these actions in the text file that the movie loads. I'm trying to make something open up in a new window (target doesn't work in hyperlink from text file) and have the sound in the movie stop at the same time. I'd appreciate any help.. thanks!
Images In Dynamix Text?
Hey,
I'm wondering if it's possible to, in whatever way, add images into your dynamic text, and I don't mind if it uses html or not. If it's not possible, what would then be the best trick to go arround this?
Oh, and sorry bout the short question, I'm quite iritated here
Thnx,
Sph
Printing Dynamix Text Box
Hi everyone,
I wrote the following code.
import flash.printing.PrintJob;
import fl.controls.TextArea;
import flash.events.MouseEvent;
var printP:PrintJob = new PrintJob();
printBtn.addEventListener(MouseEvent.CLICK,printp) ;
function printp(event:MouseEvent):void {
printP.start();
printP.addPage(printBox); //where printBox = the name of my dynamic text box
printP.send();
}
When i come to run the program, i get the following error:
1067: implicit coercion of a value of type flash.txt:Textfield to an unrelated type flash.display:Sprite.
Any clues?
Dynamix Text Fields In Flash Mx
Im not sure if im doing it wrong or what but i've been trying to get the dynamic text fields in flash mx to work and they dont. im using the
loadvariablesnum("textfile.txt",0) code and it doesnt seem to be applying the text. I have set the data in the text file and the text field to have the same name. can anyone tell me what im doing wrong? thanks in advance.
Dynamix Text In A Button Problem
Hi,
I am trying to use a dynamic text field on a button. Eventually the text will be pulled in from an xml, but for now I'm just hardcoding it in to see if it works. And, well, it doesn't. Here's a look at my code....any thoughts?
Code:
_root.attachMovie("button","button",100);
button._x = 100;
button._y = 100;
button.link.text = "blah";
Using Stylesheet In Dynamix Text From External .txt
Hello everybody! Thanx alot for all your tips. I have a problem that i cant find in tutorial or forum.
I am loading external textfiles into my *.swf in a dynamic-textfield and want to use CCS to shape them up. Can anyone please help where to put in the stylesheet code to get this working?
var thumb_spacing = 110;
var columns = 5;
// load variables object to handle loading of text
var description_lv = new LoadVars();
description_lv.onData = function(raw_text) {
description_txt.text = raw_text
};
function GeneratePortfolio(portfolio_xml) {
var portfolioPictures = portfolio_xml.firstChild.childNodes;
for (var i = 0; i<portfolioPictures.length; i++) {
var currentPicture = portfolioPictures[i];
var currentThumb_mc = menu_mc.createEmptyMovieClip("thumbnail_mc"+i, i);
currentThumb_mc._x = (i%columns)*thumb_spacing;
currentThumb_mc._y = Math.floor(i/columns)*thumb_spacing;
currentThumb_mc.createEmptyMovieClip("thumb_contai ner", 0);
currentThumb_mc.thumb_container.loadMovie(currentP icture.attributes.thumb);
currentThumb_mc.title = currentPicture.attributes.title;
currentThumb_mc.image = currentPicture.attributes.image;
currentThumb_mc.description = currentPicture.attributes.description;
currentThumb_mc.onRollOver = currentThumb_mc.onDragOver=function () {
info_txt.text = this.title;
};
currentThumb_mc.onRollOut = currentThumb_mc.onDragOut=function () {
info_txt.text = "";
};
currentThumb_mc.onRelease = function() {
image_mc.loadMovie(this.image);
description_lv.load(this.description);
timeline.loadVariables(baseurl + this.TEXT);
};
}
}
// xml object for xml content (defines sources for selections)
var portfolio_xml = new XML();
portfolio_xml.ignoreWhite = true;
portfolio_xml.onLoad = function(success) {
if (success) {
GeneratePortfolio(this);
} else {
trace("Error loading XML file");
}
// no success? trace error (wont be seen on web)
};
// load
portfolio_xml.load("portfolio.xml");
Formating Fonts In Dynamix Text Fields
Ok Im sure this has been answered and I searched first but stil have a problem.
Someone tell me whats wrong here:
Code:
mainTxt.htmlText = "<p align="left"><b><font color ="#000099" size = "14" >Team: </font>"+this.team+"</p>"+"<p align="left"><font color ="#000099" size = "14">Time: </font><br>"+this.time+"<p align="left"><font color ="#000099" size = "14">Level: </font><br>"+this.level+"<br>";
What im trying to do is make a catagory: then var
like this
Code:
Team: this.team
Level: this.level
I want the TEAM: part to be red and the 'this.team' to be black
there wil be a lot of these loaded form a php if that matters.
Problem With Scrolling Dynamix Text Box [MX2004]
http://www.flashkit.com/tutorials/Te...1073/index.php
I tried out the tutorial above and it isn't working quite right. When I hit the button I've made to scroll down, it scrolls down and then pops back to the start. I set it up right with the instance names and I tried it many times with the dynamic text box scrollable-option (that box in the bottomright corner of the box) in both positions.
Anyone got any suggestions or getting the same result as me?
Problem With Scrolling Dynamix Text Box [MX2004]
I've tried working with a scrollbar that is not the component one, just two buttons with actionscript. When I hit the button I've made to scroll down, it scrolls down and then pops back to the start. I set it up right with the instance names and I tried it many times with the dynamic text box scrollable-option (that box in the bottomright corner of the box) in both positions.
Anyone got any suggestions?
I've attached a .zip of the page for your reference. I've included the index.swf file because the externally loaded text (homecontent.txt) doesn't show up right when you preview it in Flash MX/MX2004. It works when you view it through the index.swf file though, just click on the "Home" link.
TIA!
ATTACHMENT
Download Link In Dynamix Text Field.
hi
I have a .txt file with html code inside of it that loads into my swf. i've managed to create a link (ain't i the genius) but the problem is that if the link ponits to another website e.g
a href="http://www.something.com/file.mp3"
it just opens the file in the browser.
is it possible to get it to download the file instead?
i've tried searching but i can't find a answer.
/snäll
Problem With Scrolling Dynamix Text Box [MX2004]
I've tried working with a scrollbar that is not the component one, just two buttons with actionscript. When I hit the button I've made to scroll down, it scrolls down and then pops back to the start. I set it up right with the instance names and I tried it many times with the dynamic text box scrollable-option (that box in the bottomright corner of the box) in both positions.
Anyone got any suggestions?
I've attached a .zip of the page for your reference. I've included the index.swf file because the externally loaded text (homecontent.txt) doesn't show up right when you preview it in Flash MX/MX2004. It works when you view it through the index.swf file though, just click on the "Home" link.
TIA!
ATTACHMENT
Images: Round Rather Then 90deg Corners In Flash
I am building a set of images slideshow; I want the images to be seen round and smooth in the corners rather than 90 degrees.
I tried Photoshop, it did work but it keeps the background of the corners all the time white no matter what in format I saved the image.
Can any1 help.
Text At An Angle
Hi
I have a movie clip with a dynamic text field that is rotated (6 degrees).... the text never shows up (it did before it was rotated). Is there a way around this? or do I have to go to Plan C (since there was no way around the problem in Plan A!)
I'm a beginner, so please talk down to me!
Scrolling Text On An Angle
hi .. is there Any possible way to use scrolling text positioned on an angle? using external text files, or html doesn't work. for once text field (or MC) is angled, the text disappeared.
so i figa taht i wud need to use embedded fonts. is there a way?
thanx
Dynamic Text On An Angle
Hi
I have a dynamic text box reading from a text file.
All works fine, but I would like it to be on an angle - I'm aware you can't do alpha effects etc on dynamic text but was hoping to just have it on a slight angle (like the writing running down a hill).
Is this doable at all?
Thanks
Helen
Text Field On An Angle
Hi
I need a text field to be on an angle, but it is slowing up the file and increasing the file size dramatically. Has anyone tried to do this? Is there anyway to get it to work?
Thanks
Text Mc Disappears On Angle?
I've created a simple text button mc according to Lee's tutorial and it is acting very strange.
Whenever I use the rotate tool to tilt the button, to any angle other than the standard horizontal, it disappears when you play the movie. It's just not there at all. If I tilt it back to the normal horizontal position for text, it is there and functions normally.
I've tried tiliting the symbol for the text inside the MC and tiliting the dynamic text of the button itself. always the same result: the button is not visible when you play the movie.
See any thing like this before?
edit, It's a dynamic text issue. I changed the text inside the symbol inside the button mc to static text and now it is fine. Still very curious, though.
Dynamic Text Field On Angle?
I am trying to use a dynamic text field on an angle but it does not render it in the swf file.
If I set the angle of the text field to 0 it renders correctly.
Has anyone managed to render a dynamic text field on an angle?
Thanks in advance
Text Tool Only Types At An Angle Oye
well, i don't know what i hit, but instead of being able to type from left to right (or 9 o'clock to 3 o'clock) my text tool is only typing from 10 o'clock to 4 o'clock! i've looked for a button and looked thru help, but no luck...
Xml Into A Dynamix Textfield
Hi!
I have a multiline dynamic text box throughout my Flash movie which drags in formated text from one of several attached .xml files. The text is wrapped but sometimes cause problems when the text on one of the lines of the text box reaches right to the very end of the box. The result of this is that you cannot read the end of the textline.
Is there actually anything I can do about this, and has anyone else experienced the same thing before?
Cheers,
(Sorry Dave for stoleing part of your post... )
Customize Dynamix Textfield
Hi
If this post is in the wrong place, I apologize. (new at this )
I have, sort of, a problem.
I have a textfield that displays the sum of a currency calculations, ex "36458". Is there a way to make the textfield dispaly the sum in a different way, ex "36.458:-" or "$36.458" ?
Getting An Angle
I have a helicopter and when you click with the mouse cursor, it adds another helipad, the helicopter starts at the first helipad and flies towards the next one in the array, so when you click, it adds another destination to the list. My problem, I want the helicopter to fly with it's tail to the back, getting the direction iut has to fly and then rotates it aacordingly, anybody that can help me???
it can be previewed at http://subman.deviantart.com
Check the helicopter chaos, this is the flash I'm having difficulty with..
Just click on the helicopter link, thanx for th einput in advance
Arc On An Angle
Hi,
Angles are drawn dynamically. They are measured and shown to users. I'm stuck on making arc for the angles drawn dynamically.
Any links, idea or help?
Angle
I have a two boxes center screen I did action on both as follows
onClipEvent (enterframe) {
_rotation-=2;
_x++;
_y++;
}
The first rotates up to far left corner 2nd bottom right corner.
onClipEvent (enterframe) {
_rotation-=2;
_x--;
_y--;
}
My quest is how would I get a 3rd + 4th box going opersite directions, Many thanks
Regards Barrie
Angle Between Two Mc's
hey
trying to calculate angel between two mc's
came up with this
ActionScript Code:
function angle(ob1, ob2) {
var o1 = eval(ob1);
var o2 = eval(ob2);
xDist = o1._x-o2._x;
yDist = o1._y-o2._y;
return (Math.atan(yDist/xDist)*180/Math.PI)-90;
}
but there seems to be something wrong with that
its only returning negative angels
any ideas whats wrong with it?
Angle
I have a two boxes center screen I did action on both as follows
onClipEvent (enterframe) {
_rotation-=2;
_x++;
_y++;
}
The first rotates up to far left corner 2nd bottom right corner.
onClipEvent (enterframe) {
_rotation-=2;
_x--;
_y--;
}
My quest is how would I get a 3rd + 4th box going opersite directions, Many thanks
Regards Barrie
Mouse Angle
Hi,
How do I track mouse's angle using trigonometry objects in
Flash 5? I need to find a way to convert any given x and y coordinates to degrees. (0 to 360)
Got any idea?
Thanks Much,
z27
Shooting At Any Angle
Hi,At the moment I have a movie clip that can move left right, up, and down, as well as rotate to any angle by keystroke. I was wondering though how
to write the code so it can shoot at any angle of rotation? At the moment the laser will follow the rotation of the movieclip, but will only go in the _x or
the _y coordinate, never both. Any ideas?
This is on the movieclip:
onClipEvent (keyDown) {
if (Key.getCode() == Key.RIGHT) {
_x = _x+2;
} else if (Key.getCode() == Key.LEFT) {
_x = _x-2;
} else if (Key.getCode() == 40) {
_y = _y+2;
} else if (Key.getCode() == 38) {
_y = _y-2;
} else if (Key.getCode() == 90) {
_rotation += -2;
_root.laser._rotation += -2;
} else if (Key.getCode() == 88) {
_rotation += 2;
_root.laser._rotation += 2;
} else if (Key.getCode() == 32) {
tank_x = getProperty("_root.tank", _x);
tank_y = getProperty("_root.tank", _y);
_root.laser.duplicateMovieClip("laser");
setProperty (_root.laser, _x, tank_x);
setProperty (_root.laser, _y, tank_y);
This is on the laser at the moment:
onClipEvent (load) {
laserMoveSpeed = 20;
this._x = _root.tank._x+60;
this._y = _root.tank._y;
}
onClipEvent (enterFrame) {
this._x += laserMoveSpeed;
if (this._x>600 or this._y<0) {
this.removeMovieClip();
Thanks,
Andy
Art-barn.com
Calculating An Angle
hi,
the math I was tought in highschool has left my brain along the years, so that's why now i have to ask this question here:
what is the correct syntax in actionscript for calculating the angle between two lines.
thanks in advance.
(The teachers told me I would need it some day, why didn't I believe them)
Checking Angle
i'm trying to figure out a way to to get the angle that the cursor is to a movie clip. if the movie clip was the center of a clock and the cursor was at 3 o'clock, it would be 90 degrees, 6 o'clock-180, and so on...
anybody have any ideas?
thanks
dougc
Angle Detection
this is a doddle, but I'm brain dead today.
all I want is some simple code to find the exact angle between the mouse and a movieclip. see I told you it was easy. nothing taxing here. Any ideas then?
cheers
Niall
Mouse Angle
I cant figure out. I need a simple mouse angle that says once the mouse is below 200(vertical) to tell target.
BTW thanks for all the help so far, this site is very cool.
Bubble MC From Different Angle
Please help. What am I missing?
I've decided to go different route with my bubbles. I have created a bubble via attachMovie method on level 4. Have called it "bubbleBottom".
Now I want to make it move and it's not going anywhere. I've tried a dozen different paths. Here is what I have latest:
function moveObject (mcName, number) {
name = eval(mcName);
speed = number;
moveSpeed = speed;
name._x += moveSpeed;
}
The call action on frame 1 is as follows:
moveObject("bubbleBottom",3);
When I debug, the variable level0.name=[movieclip:level0.bubbleBottom] shows in there and the moveSpeed=3.
Why am I having such a hard time passing the mc name when using attached movies on main timeline?
Please help.
Thanks MUCH in advance!
Gradient At An Angle?
I'm having trouble reproducing a gradient I made in illustrator. It is a linear gradient but it comes down at a 50degree angle. I can't seem to find any control that allows you to modify which direction a linear gradient is going in flash. Anybody have any tricks?
- Brian
the humble newbie
Determining An Angle.
I'm trying to find a tutorial or just the code if someone has it, showing how to determine the angle between two movie clips. For example, if I have two movie clips on my stage I want one of them to point towards the other. My trig is very rusty and I'm going crazy trying to find a good tutorial. Any help is appreciated.
Thank you.
The Mouse Angle
i would like to manipulate a frame inside a movie by a certian postion (x,y) on the stage. ive got stops on all frame,s inside the movie clip and i want to gotoandstop on certain ones depending on (lets say for this question )when the mouse rolls over an area between x400 and x500 can anyone help me? version 5 or mx
Help On Angle Formula
Im making a flash sorta 3d engine and I need a reliable angle formula (to get the angle with points X, Y, CX, CY)
Right now I'm using ACOS((X-CX)/Dis) where dis is the distance from X, Y to CX, CY. It seems that ACOS isnt all that reliable, and so I keep getting NaN. Does anyone know one thats fast and effective?
Angle From Coordinates
Hi,
whats a quick simple way of getting an angle (in radians) from an x,y coordinate?
thanks
phil.
Angle Move To X Y
i need to get a movieclip to move to a certain position when its roled over. i also need it to point to the position while its moving twards it. heres what i need.... onrollover change angle of mc and move to position. anybody got any ideas?
Height And Angle
how would i match the angle of a mc to the height of a mc like if its coming down then its facinf down and if its goin up hen its facing up, ect
Angle Input Box
How could i go about creating an input box which is rotated and slightly skewed. not perfectly horizontal
so when users type can type there name and it looks abit more funkier.
I hope you can do this, i tried putting in the input box into a movie clip and transforming it that way, but it didn't work.
Thanks for any help.
Dragging At An Angle
Hello again,
Need to drag an object fixed at a 45 degree angle. Any help would be appreciated. Thanks. Please also read my 'Obtaining Coordinates' post if you can help there too.
Mc Angle Detection
this script returns the angle of the mouse in a text box:
onClipEvent (mouseMove) {
x = this._xmouse;
y = this._ymouse*-1;
angle = Math.atan(y/x)/(Math.PI/180);
if (x<0) {
angle += 180;
}
if (x>=0 && y<0) {
angle += 360;
}
_root.angletext = angle;
updateAfterEvent();
}
Is there a similar script that will return the angle of a dynamically rotating mc that is constantly and randomly offset from the mouse angle, and post it in a text box.
Determing Angle
Hey all, somethin's been bugging me. In a pong game that I made, so that I didn't have a set angle for the ball, and rather it depended on how high or low on the paddle it hit, I wrote this code:
code: speedY = (ball._y - paddle1._y)/4;
speedX *= -1;
This way, the ball is always going at different angles. In the Pong game though, the angle of the paddle never changes, it is always at 180 degrees. In my newest game, the paddle's angle is determined by where your mouse is using this code:
code: function onEnterFrame() {
myRadians = Math.atan2(_ymouse-paddle._y, _xmouse-paddle._x);
myDegrees = Math.round((myRadians*180/Math.PI));
paddle._rotation = myDegrees+90;
}
Now I have a ball as well, and I want to make it work like it did in my Pong game - the difference is that now I can't just simply flip the X, because now the paddle's x and y coordinates, and its angle are constantly changing. I thought this would work:
code: speedX = (ball._x - _root.paddle._x)/4;
speedY = (ball._y - _root.paddle._y)/4;
But it always seems to be going in the same direction. I figured that was because of how my MC was set up (the x and y coordinates always stayed the same, only the angle changed). So I tried many things, but it still doesn't seem to be working.
I attached the FLA. The code for the ball is on the actual ball MC, and I added some notes...
Thanks in advance.
|