Wrestling with the MyFlashLab Scrollbars

Now I’m back and actually working on the scrollbar stuff. I overlooked the download of one I was going to try, and it looks good. No fancy dependancies or requirements, just a couple of classes. Now I’ll test it.

*work work work* Okay it has some errors when I try to compile. It looks like it was meant to be done in the flash IDE using a pre generated library image. I’ll just create a thing for it to display instead…

Hmm, it only works with movieclips. And it has a hell of a lot of movieclips. I should be able to fix that but first I want to get it to actually work, so I’ll make a movieclip first.

Hmm… It looks like there’s another thing in the library that isn’t in the code, a skin object. Let’s see what I can do about that. *read read* Yeah it looks like it assigns various properties of it to variables. I can just instantiate the properties at those variables and it’ll be the same difference. Except, I only have clues as to what they’re supposed to look like. I guess I can compare the demonstration swf from the website though…

This brings another question, now that I think of it. Should I make the interface out of vectors or bitmaps? I’m hoping to make the text game scalable, later, so people with high res monitors or bad eyes can change the size of the text and UI elements. The text in Flash is represented as vectors, I think, so I should make the ui elements vectors too. But then, how to do that? I mean, there are options. I could draw them by code, which is hard and makes them hard to update, but there should also be a way to import vector images into flash apps. Never actually done that, only bitmaps. I should do that, just to say I have!

First I’ve gotta look up the deets though, ’cause it might be different than doing it with bitmaps. I want to know what kind of file format to use too. I know you can save vectors as .svg but there’s probably other options too.

Also we’re having a bit of connection trouble at the cafe I code at, and I’ve got to say it’s a pet peeve of mine when a browser downloads and displays a web page but can’t get the CSS, and displays it ANYWAYS. What is up with that? If you can’t download the whole webpage, don’t display it! Give me an error or something. People who are less computer savvy probably don’t realize that the .css isn’t loading properly. Geez.

Okay now that the internet is workingish, I’m able to do research. It looks like I was right, all I have to do is make it a sprite instead of a bitmap. Way to go, embed command.

Now to actually make the vectors. This’ll be interesting, since I haven’t got a lot of vectoring experience. Well, there’s only one way to get that!

Now if anybody is curious, I use a copy of Jasc Paint Shop Pro 8 for most of my arting. It’s a pretty decent program I’ve used quite a lot over the years. I guess it’s pretty old now. Why do I use it? Well, my Dad got a legit copy of it a while back, and I love legit copies of software. I also use Paint.NET for things where Paint Shop Pro is too big and powerful and I just want to do some cheap pixel art. My laptop is pretty weak, you understand, and graphics processing is intense.

*finishes an up arrow* Oh. Well, I just learned something today. Apparently Paint Shop Pro 8 can’t save images as .svg files! I guess that’s what I get for using decade old image processing software.

I’m starting to consider drawing the elements by code anyways. I mean, for one thing, I don’t have an art program that’ll let me save vector art. But also I realized as I was working on it, that anyone who used this scrollbar would have to bring the art in as well, and I was already complaining about dependancies and things.


Oops I got lost on the internet for a while, but I’m back now.

So, right. I’m going to generate the vectors by code. BECAUSE I CAN. I’m a foolish fool, sometimes.

Hokay, it looks like Controller_H and Controller_V are container objects, so they don’t need graphics. Oh, also it looks like they spelled controller wrong. Well, I can refactor-rename so that’s no prollem.

*work work work* Well that’s not right. I’ve gone ahead and made all of the elements into magenta squares, and when I run the app they flash on screen then disappear. What’s up with that? Le-sigh. I can only guess the size and shape was important in some way to the scrollbar. I really have to wonder if this isn’t more trouble than it’s worth.

If there’s one thing that’s clear about these MyFlashLab people, it’s that they love nesting MovieClips. These classes of theirs will be pretty much unrecognizable when I’m done with them.

Only twenty minutes left before the cafe closes. Time is so fleeting. I have plans for when I get home, that I’m looking forward to, but I wish I could get more done here first. Alas.

Hmm… This is perplexing. From everything I’ve read, it should be displaying properly, with magenta boxes for scroll bars, but whenever I run it, it just shows up big boxes then they disappear.

Hmmmmmmm… I know they’re on the stage since I can see them for a moment, but their positions are all wrong. They appear in the middle of the stage and then vanish.

Aha! I figured it out. The content they were supposed to scroll wasn’t big enough, so there was no need for scrolling. I’ve fixed it, and now they appear, though they’re positioned wrong. I can fix them though. This should work out.

For now, though, I’m afraid I need to pack up and go home. Just five minutes to closing. At least I did something productive today!

Tagged , , ,

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.