Alright, I need help here, Ive been trying all day to figure this damm thing out.
What I have is a dynamic textbox within a movie clip.
The textboxes INSTANCE name is “newsBox” (no quotes) and the movie clips instance name is “newsClip”
newsClip is being masked by a rectangle shape. Now as everyone knows (or will soon find out), you need to embed the font outline for a dynamic textbox to work when being masked. That is all well and good… BUT… and it is a big but… When you want to render the text as html and read it as htmlText it doesn’t work!!!
Am I to assume that you can’t use HTML formatted text in a masked clip with a textbox? If so this really friggin sucks because it defeats the whole purpose of what I was trying to do!!
Is this a bug in Flash? Is there a reason they did this? Is there a way around it?
Ok… I know I posted this in the Flash MX section already, but I figured I would post it here as well because most likely the one to be able to solve my problem is a mod (sen, ilyas, eyez, etc, etc), so I figured you would see this here because I REALLY need to know whats going on here.
Hey lost - I don’t think HTML text can be modified a lot like similar text. For example, I don’t think you can alpha text in a movie clip that contains text that is HTML formatted. I am not sure though.
Ok, since this is in the Top Secret section I can post what I am using this for…
DO NOT SHOW ANYONE!!! Its still work in progress I just started it last night.
And yes, I know a lot of that HTML isn’t accepted by Flash, but it will still format that stuff that is accepted (tried it, it does) and I just copied the .txt file from my php news updater so that is why it is like that, I just needed something long that could scroll so I could test out my scroller.
Ok, I sorted out a workaround to my problem (a much better workaround at that).
I used the knowledge of XML that Sen gave me a while ago (OMG I am still so grateful for that!!!) and I created a sort of XML backend for my news.
My news is now an XML file that gets loaded into Flash and each news entry is then loaded into a duplicated movie clip of 3 textboxes… title, date, and content. The duplicated clips contain the text of each childNode inside the XML file. Each duplicated clip is also the same width and height as my content area and is moved on the _y by its _height.
This allows for 1 entry to show at a time instead of 1 and part of the 2nd, etc.
I am very proud of this creation :beam:
Go to the link in my last post if you want to see it in action.
Ok, I will try and explain better what my XML in Flash script does…
This is my set up…
_root.newsClip.content
So on the stage I have my clips called “newsClip” (this clip is being masked).
Inside newsClip I have a clip called “content”.
Inside “content” I have 3 textboxes. Each have an individual instance name, the top being “title”, the middle being “date”, and the bottom being “content”.
What my XML script does is when it loads all the XML data from my external .xml file it then proceeds to create a for loop that takes how many entries I have in my .xml file and duplicates the clip “content” that many times (so there are as many content clips as there are news entries)
As it duplicates them, so they don’t overlap (and since it is how my news scrolls anyway), I move them on the _y axis according to the _height of the clip.
This creates a string of these clips going straight downward in order.
I also use the XML functions in Flash to input the text into the proper text fields, but if you don’t know XML in Flash I won’t go into that.
Since “newsClip” is under a mask, only 1 entry shows at a time, where my up and down buttons use an easing formula to move the clip up or down according to the _height of the content clip, so basically they go back and forth between entries.
Here is an example of my external .xml file if it helps you better understand at all.
There are three entries (represented by the NEWS nodes)
<NEWS>
<TITLE>First Entry To Date</TITLE>
<DATE>Posted Today</DATE>
<CONTENT>This is the content</CONTENT>
</NEWS>
<NEWS>
<TITLE>Second Entry To Date</TITLE>
<DATE>Posted Yesterday</DATE>
<CONTENT>This is the content</CONTENT>
</NEWS>
<NEWS>
<TITLE>Third Entry To Date</TITLE>
<DATE>Posted Two Days Ago</DATE>
<CONTENT>This is the content</CONTENT>
</NEWS>
he mentioned today that AS is a good language to start in… maybe this one will stick for a while. I have a big problem with computer languages after I don’t use them for a couple days. Human speech is totally different…
I think AS is a great language to start with, its not that hard to learn (compared to languages like C++ and such) and it teaches you how to get into the coders state of mind so that when you tackle other languages you kind of already have an idea of how things should work and be set up.
I was able to help my friend in her C class because I know AS. She had a few problems with for loops crashing her program and whatnot… I was able to actually fix and optimize some of her coding. And I have never seen C before that ever.
Every language is of course different, but I think AS teaches you the fundamentals that pretty much tie into most if not all computer languages… IMO, but I only know web languages, so I can’t really speak from experience.
JavaScript is my bain… I can understand it, slightly modify it even, but as far as writing it, no way…
I have been working with Flash for so long, I just translate whatever I need to. I am still much faster with Generator than I am with MX. It took me less than 2 hours to do my site with Gen, but it would have taken me 2 days with MX…
just the way my mind works. I am having a much easier time learning MX coding, since I kinda ignored Flash 5 becuase of Gen…
To be honest… Flash MX coding I feel is easier than Flash 5 coding anyway.
I still can’t speak from experience, I started Flashing with MX, but after seeing some Flash 5 source files of awesome effects and then seeing how hard it was to do them when some of the things could have been easily optimized with Flash MX.
Like that spider experiment I posted in Random recently, it was a Flash 5 tutorial that required like 6 movie clip symbols with movie clip symbols and buttons inside them.
I redid it in MX syntax and was able to squeeze it all into 1 frame and draw the entire thing with the drawing API… no movie clip symbols in the library.
It takes getting use to, but I am sooooo glad I never had to code in Flash 5… I honestly think I would have given up Flash then and there if I did.