Hey guys. My job is to make the interface of a new browser-based game. (No, i'm not some 14 year old trying to make habbo ;)).
The game includes JQuery + SWFObject at each page, since they're both used. Then, it uses a common script, approximately 500 rules, for some common things. Then, the larger pages have a +- 600 rules script of themselves + the plugins. My most used plugins are Draggable and Droppable from interface.eyecon.ro In firefox, each page goes rather slow. The biggest page, we'll name it Q, has 4200 rules of javascript. It also has an interval, running a HTTPRequest each 14.7 seconds, sending some post dat and getting a rather large amount of JSON, 4kb. In Opera9, everything works fine. It has the 'normal' pause before rendering the 'new' or changed elements, but that's opera. Dragging, for instance, is great. The CPU in task manager of opera is: 0 between ticks, 30-60 at a tick. Firefox however, gives a very different view. At a tick, the cpu is 70-90. between, it's 40-75. It slows up a lot, giving the client the feeling that there's an infinite loop or something. Anybody knows how to speed things up? I can't make the code much smaller; i've already deleted a part of jQuery (mostly the ajax part, i just use normal xmlhttprequests), splitted some files, and so on. I also use YSlow's performace rules (i'm getting 64 points on the moment, javascript/css = A) Any ideas? Much thanks in advance, J. de Boer