Skip to main content
Participant
October 17, 2006
Answered

Is there any limit on number of variables?!

  • October 17, 2006
  • 4 replies
  • 584 views
Hi everybody,

I'm currently in the final squash bugs phase on my one-year, one-developper project. Sneak-peek at:
www.showeaver.com/testDrive/

I'm experiencing some strange things. I have a canevas where you can build room setups. I can select one or multiple elements (chairs, tables, stages, etc.) on that floor when holding SHIFT. Everything works fine (well, there's some other small bugs...) But when I open a dialog window, which is called from within my UI controller class, -- that is not at all connected with my other MVC set of classes for my 2D view (yes, there's a 3D view!) -- the mecanism for the selection of object is completly screwed up. I'm not able to select correctly my objects that are repeated several times. (suppose you drop 4 chairs, the only chair that is selected is the first one...).
Is there a limit in the size of my classes of in the number of variables I can declare in one SWF file? Some of my biggest class files have 2000+ lines of code... I heard that when you use #include on a frame script you better keep you file size bellow 2000 lines or something, but for classes? Anyway I don't use #includes, I have a one frame, one line of code that starts everything...

If you have any clue, or want to share some experiences with the limitations of the MX classes (which I extends a lot in that project)...
I also welcome other feedbacks on that project!

P.S. If you need to be guided in my project: To start the application, click on [English] or [Français].
log as user: demo with password: demo. and then "Connect"
You then need to open a project, and then a Floor Plan. Maybe it will open as read-Only, as maybe more than one Demo user will want to open that "file" at once.
There you can drag your furnitures in place on the floor.
To open the window responsible for my headache, you select menu: Settings > Groups and then select one group to edit. After that, it is broken...

Thanks!!!
This topic has been closed for replies.
Correct answer calmchess333
approx 16,500 objects and/or variables are allowed in a single flash app.

4 replies

calmchess333Correct answer
Inspiring
October 19, 2006
approx 16,500 objects and/or variables are allowed in a single flash app.
ZalAuthor
Participant
October 19, 2006
Thanks!
While I have to mark my question been answered, I still don't know where to start to find my bugs...
But just by curiosity, I found 1590 MovieClips and 6147 variables in my runnig SWF (via Debug > List Variables)
So, it's not that.

I wish I could trace and dissect easily all the calls made by the EventDispatcher. I suspect that I've made something wrong somewhere with that.
But where?!?! You can imagine that I use it a lot in my project.
The debugger? Well, let's suppose that I simply succeed in making it go (the script just run too slow) where do I put my break points, I don't even know where my problem is. And I have over 23,000 lines of code...

But! I have some ideas... I'll have to mega-trace my project! A chance that I have a second monitor....
Thanks anyway.
Participating Frequently
October 18, 2006
Oh yeah, forgot to mention is does it here as well. No php. XML
http://www.nswmd.com/nsgallery

Or did. Did not do it just now. But I noticed it before when loading the images it was doing it. If the loader just hangs for a particular, move your mouse.

I really should try this on other hosts. Was one of the things I was meaning to test. Seeing if that was the problem. But how?
Participating Frequently
October 18, 2006
Hmm...
I do use include and seperate the files as if it was like creating an actuall application with different files.

Like:
functions.as
protoypes.as
post.as

So much more organized.

ect...
Splitting my functions up. Then call all includes on one frame. No problems with it at all.

But I experience different issues with my applications. Did not notice it on your site however.

if you visit: http://www.nswmd.com/nsforums
I as well have a strange one. Some people will notice a hang time. The dialog boxes just hanging displaying "Verifying User" when in fact it is done, but the dialog is still showing and not displaying the results.

Until you move your mouse. Does this on all of my query resquests, in which I am using my own component to make SQL connections and querys, sending emails with one PHP file containing only 9 lines of code. create_funct () is your friend.

Any ways. Opera and IE7 it works smoothly and simply screams. FireFox and IE 6? Pfft. You have to move your mouse. I tried this on numerous comps and players.

Coming to a conclusion...
Its Flash Player 9.

I contacted Adobe (last week) and like most multi-billion dollar companies.
No response.

Maybe its me or whatever. But man, I like Adobe... for photoshop. Their attempt to compete with Flash by developing LiveMotion, failed. So now they bought Macromedia and, well... I am seeing a decline in the product performance and usability like in the past. ESPECIALLY Dreamweaver. But hey, thats me... the consumer.

I can understand if my issue was in only one of the browsers I tested. I would say its the browser (even though FireFox does handle flash poorly). But when 2 different browsers do the same thing, on both ends and one being different versions of one another. I'm gonna guess its the player itself. Not your script or the coding.

My issue makes no sense. Finshes by moving your mouse?
I have no mouse detections or movement mumbo jumbo. Only thing your mouse is used for is 'clicking'
ZalAuthor
Participant
October 18, 2006
quote:

But I experience different issues with my applications. Did not notice it on your site however.


To experience the bug I'm trying to nail down you have to follow this sequence, as mention in first post:
quote:

To start the application, click on [English] or [Français].
log as user: demo with password: demo. and then "Connect"
You then need to open a project, and then a Floor Plan. Maybe it will open as read-Only, as maybe more than one Demo user will want to open that "file" at once.
There you can drag your furnitures in place on the floor and select them freely.
To open the window responsible for my headache, you select menu: Settings > Groups and then select one group to edit something. Close that window.
After that, it is broken...

After that you wont be able to select correctly any object that have duplicates on the same floor (like if you have 4 tables, if you select the table #4, it's the table #1 that is selected . . . )
Inspiring
October 17, 2006
Hello, I can't offer any kind of help with your problem as I am a complete beginner, however, the site looks really cool. Is With expception to the 3d stuff is the whole thing built entirely using flash and some server side language for saving? J
ZalAuthor
Participant
October 18, 2006
Yes, beside the 3D, everything is done in Flash, and the server calls are done with AMFPHP.
I had to write almost averything from scratch, the udo/redo mecanism, the open/save operations, the layout logic of the interface. What I did though is use a lot of Macromedia's MX componenents and build on them.

Thanks a lot for your feedback!