Related
I have a question about Flash. I am writing my first browser game, and I am trying to decide on a technology.
I have a few requirements:
I don't want to have to pay to write code and a not-complete-crap free IDE would also be good.
I want most (or > 70%) of "normal" computer users to have it installed, so, Unity's pretty much out.
I don't really need performance too much
I need 2D, not 3D
Needs to be able to communicate with the server, and no extra downloads required.
Preferably works with the Facebook platform, but, this isn't a requirment.
Now, I would go with Flash as it fills all of my requirements, but, to my understanding, I need to pay for CS5 to get coding with Flash. Is an alternative around this possible?
Are there any other alternatives I'm missing?
To add onto what ColinE mentioned, FlashDevelop also provides you the ability to download and install the Flex SDK. However, if FlashDevelop as an IDE doesn't work for you, you can also download the Flex SDK yourself.
This is essentially the same thing that's included with Adobe's Flash Builder application, which is basically built on top of Eclipse. This should at least give you a start on creating things in Flash, though you'll be limited to ActionScript 3. I'd suggest sticking with AS3 as it provides a lot of power compared to AS2.
If you do choose to use the Flex SDK, I'll give you a bit of knowledge I've gained since I started using it for developing games. This may be a little long-winded but hopefully it'll answer some of the initial starter questions.
You can develop apps/games using the Flex library but this may increase the size of your SWF file. However, it's worth noting that it's not required to use the library. You can use the compiler (mxmlc) provided in the SDK to build against .as files as well.
From here, there's a few gotchas that might creep in when it comes to assets. Flex provides you the ability to embed assets within your class files. Out of the box, it allows for the embedding of a handful of formats, most notably PNG, TTF, XML and SWF. There's a lot that you'll be able to do with Flex from a code standpoint but it's not very pretty for creating the assets themselves. Primarily, I use the Flash IDE only for cases where a project requires a SWF asset, however, most of my projects tend to use PNG.
When using an embedded SWF asset, you may come across an issue where any code that's included in the asset, such as any hover or animation logic as ActionScript, gets stripped out of the copy embedded in the resulting project's SWF. A workaround for this is forcing the mimetype to "application/octet-stream" and using a Loader object's loadBytes() method.
Finally, you should be able to make some sort of progress provided you have some sort of ActionScript knowledge. There are plenty of resources out there but be aware that a fair amount of them still use AS2. The knowledge can be applied with some modifications but may require some extra legwork to implement. The language is fairly easy to work with.
With all that, I wish you luck. Flash gets a lot of flack these days but even with HTML5 nearing final, there's still a lot of features that it will never be able to touch without leveraging Flash in some way.
Flash, Silervlight or HTML5 will tick pretty much all of those boxes for you, however Silverlight is only installed on ~65% of computers at the moment.
HTML5 can be tough to develop with, so perhaps Flash is your best bet. See the following question which discusses Flash IDEs:
Flash Developer IDE
FlashDevelop is a free development environment for Flash.
I believe your question is about which type of development you should use to get this game going, but I would also urge you to consider the future of each of these software sets, and choose based on what you would like more experience in.
Flash has been holding it's ground pretty well, but I've seen it less and less on major sites these days, and I believe HTML 5 is taking pretty good stabs at it. Even Pandora doesn't use flash anymore, and that was a pretty well designed little flash app (they still use AIR for Pandora One, but not their main site). Instead, like many other websites, it's using HTML and JavaScript.
So, while flash is slowly losing ground to HTML and JavaScript, where does Silverlight stand? Microsoft is still pushing their Silverlight technology, and based on Microsoft's support scheme, they'll still be using it for the next few years at least. At the same time, it's based on the .NET framework, so you'll be gaining some valuable WPF and .NET skills by using Silverlight.
There is no right or wrong decision here, it's really just based on which technology you see yourself using past this product, and which technology you want to learn.
I'd give it a shot in Silverlight, myself, but that's simply because I dislike flash, and there's already too many HTML and JavaScript developers.
edit:
Silverlight is a relatively small 30 second install. I generally hate installing new plugins, but Silverlight is relatively painless, imo.
I don't know if it's just me, but I really enjoy some application's GUI designs, apps like iTunes/Avast, or some media players like KMPlayer. So I was thinking of making my GUIs look different and I later found out that it's called a GUI skin (am I right?).
I read somewhere that it's not such a good idea to use or make them regarding app's speed, usability and all that. So the question is: Is it good and safe to make GUI skins? and if so, how could I start programming one (cos I don't want to use off-the-shelf ones unless they're really great). What's the main idea behind them. I am expecting to be able to change the whole form's look and feel and possibly change it's shape.
Any idea on this is greatly appreciated.
Good or Bad?
Bad. I don't have a nuanced answer for you. I don't have a bunch of exceptions. I don't have a thoughtful essay to write on when skins might or not be appropriate. I have an unequivocal: Bad.
Custom skins are the cancer that is killing the Windows UI, turning it into an ugly, unusable jumble of mixed metaphors.
If you must theme because your app is the exception and you're just so cool, please provide an option to turn it off and use the regular OS theme. Not a skinned approximation of Aero, Luna or Classic, but the actual normal OS theme, whatever (potentially custom) theme is chosen.
As far as I am concerned there are two kinds of applications that might be skinnable: Media players for example might benefit from looking like an actual physical appliance (PowerDVD or so did that, iirc). However, the actual use cases for such things are very few, if any – the trend today seems to be that such applications have little to no UI and instead concentrate on the content (VLC is an exception).
Then there is the large host of applications where either developers or managers got creative or too much time on their hands. Raymond Chen calls this “I bet someone got a really nice bonus for that feature.” – a sentiment I deeply agree with. First of all, skins are often a non-feature; the novelty wears off really fast, they don't actually help a user with whatever problem they're having to use your program and finally, for many programs that exhibit skins, there is really no need at all. I mean, come on; how often do you open your AV program, or your graphics card settings panel, revelling in the glory of its beautifully and carefully-designed skin? Never, right.
So then is the question why you even want to devote development resources (either your own or others') to create something that serves no useful purpose, except making your application stand out visually. The windows UX guidelines also have something on window frames and branding. Note here especially the following section:
Don't use custom controls for branding. Rather, use custom controls when necessary to create a special immersive experience or when special functionality is needed.
Incorrect:
This example shows a custom control incorrectly used for branding.
Gadgets are another type of application that can get away with custom designs, but then again, those are often only used shortly and serve generally as either informational things or with ephemeral interaction.
If you do skins, do everyone a favor in making it (a) optional and (b) use the standard controls and just paint them yourself. This enables accessibility tools to still know what your program displays instead of just seeing a bunch of picture boxes that are used as buttons.
I have read a range of articles on advantages/disadvantages of Microsoft Silverlight framework in comparisson to Flash.
Fact that there were two version of Silverlight in the past 18 months worries me, as well as the fact that over 97% of web browsers already have Flash pre-installed.
I'm a .NET developer and I'm very happy with what I can do in the framework. At the moment I feel like I have to put my own preference to a side and decide whether I need to integrage flash with .NET instead of using Silverlight with WPF.
Did anybody try integrating Flash with .NET? What challanges did you come across? How easy was it in comparisson to working in Silverlight?
I have also read about recent talks between Microsoft and Adobe. Whatever way I go It feels very unstable. Can HTML 5 really compete with what's offered by Flash and Silverlight?
Thank you
I have integrated both Flash and Silverlight into my ASP.Net applications. I have to say that working with Silverlight was by far the easier way to go. Communication with the server is easier, initial setup was easier (along with a ASP.Net application or a simple HTML page). Integration into the ASP.Net application was the easiest part (as I'm sure you imagined it would be). If you're a .Net developer, then this is the way to go.
Also, I wouldn't worry about either of these technologies going away anytime soon. HTML5 is not going to take over. It'll take some of the market share, not all.
EDIT
Here are some links to other SO posts on the subject:
Which is the future of web development: HTML5 or Silverlight(or other RIA framework)?
Should I Abandon Adobe Flash for HTML5 and ?
Can HTML5 do most of what Flash does today?
This is basically the way I pick web technologies:
do you need to support every available platform made now, in the past and in the future? HTML4 (yes, 4!)
Do you have to make stuff that is not possible with HTML4, and are ready to sacrifice some user base? HTML5
Can you limit yourself to desktop users (no mobile devices) and need a very interactive application (more so than a "website")? Flash or Silverlight
Do you need to integrate with .NET? Silverlight
Are you familiar with .NET (more so than Flash)? Silverlight
Do you want to reach the absolute maximum number of users? Flash
Do you know Flash/ActionScript (more so than .NET)? Flash
Do you need even more features than what Silverlight provides, and can you limit your deployment to intranets? WPF/XBAP
The whole debate around Silverlight being dead is completely flawed in my opinion: those that thought Silverlight would be completely multiplatform really were not connected with the reality: just by looking at Flash it was clear from the beginning that iOS & co. would never support Silverlight.
HTML5 will probably be the real "universal multiplatform" environment (what is HTML4 now), but with all the nightmares we all know of html. If you are targeting desktops and need more interactivity, better tooling, unit testing & co. then Flash and Silverlight will still be the first choice.
Silverlight's user base is quickly coming close to Flash, so between those two it really comes down to the one you know better and the ease of integration with an existing backend.
The fact that Silverlight got a new major version every 9 months until now is just a sign of how much they are pushing it. Now that it's reached a mature stage you can expect to see larger intervals.
Frankly, AS3 is not hard to learn if you already know OOP. It will take a week or so. If you don't like all the frames stuff in Flash, you can create a single frame app and then manage everything from your custom AS classes.
I'm also a .NET developer, and I had no trouble learning AS3.0. Of course, one week is not enough to become an expert (it takes years to become an expert in any field). But if you simply need to create video or mp3 players, create drag and drop basic games/apps to add to an ASP.NET page, it's worth spending 20 or 30 hours on AS3. There are great video trainings out there . Seven or 8 hours training should take the 20 to 30 hours I mentioned. I went for AS3.0 a few years ago, rather than SL, simply because everybody has Flash plugin installed.
AS3.0 is typed (simple types like Number, String etc), but at least it's typed. There are plenty of functions, classes and methods allowing to implement hit tests, drag/drop, event listening (mouse events, keyboard events etc). Really cool and fun language.
Take care.
HTML5 has SVG and Canvas and video.
It's perfectly possible that at one point someone creative is going to create a very nice animation package that generates SVG files. There already are SVG generators there of course, but obviously they're not good enough because SVG and Flash is, so far, never mentioned in the same sentence.
But is ought to be possible. SVG does structured vector graphics, embedded scripting. The things you see done in Flash has to all be possible in SVG. Flash also has this awful notion of frames, which was a major design flaw from day one.
They should have just let you determine that you want to move an object from point A to B along a path determined by a line or curve or freehand path, and that the times of A and B can be anything and not just confined to a particular frame.
Then at playback, the faster your computer is, the better the frame rate ends up being. Slower computer, slower frame rate. As long as the object moves from A to B.
Then there are the bugs and just overall clumsy handling of Flash.
Flash can be done so much better.
So, I think that someone will at one point soon make an amazing SVG animation package that will just crush Flash.
I'm against Silverlight because it's Microsoft. Microsoft means proprietary. They do whatever they want to do. You've already mentioned different version numbers. This means your customers have to have the right version downloaded. You can count on your customers having to download major upgrades, and before you know it their entire .net install needs updating, before you can show your animations and applications.
Silverlight also doesn't work on Linux. It's supposed to, through Novell's efforts with Mono, etc, but in practice, in the field, it just does not work where you need it to.
I don't know if and how well, in practice, Silverlight works on the Mac, but I don't trust it.
Eventually, I think, that future HTML5/SVG (Canvas maybe?) is the way to go. It'll even do 3D using OpenGL accelerated graphics... (but I don't know if that's portable enough).
In the meantime, Flash is your safe bet, and it's almost guaranteed to run anywhere.
I wonder if anyone has created an animation package that outputs to swf files that's better than the Flash IDE. Shouldn't be too hard, given Flash IDE's clumsiness.
Microsoft recently announced a "change of direction" with Silverlight with more emphasis on mobile rather than desktop.
Flex/Flash and SilverL. now are very similar... using webservice for the clientt/server comunication you can work well with both.
Sure, for .NET developer with Visual Studio to use SilverL. is much more FAST and you need C# only.
But, Flash is more available on PCs, also for mobile devices... you could think for Flash if you need portability.
I see a lot of talk how HTML5 video tag will kill Flash. But while video is the most widely used part of Flash/SL, it's only a small part of their technical abilities. For instance you can write a game using full 3D graphics and socket connections in Flex, and serious business applications, etc.
Is the thinking that Javascript will kill those parts of Flash/Flex/SL? Because while that seems feasible now for even quite rich web-apps, what about any kind of high-performance app like real-time graphics?
You can do some pretty cool things with HTML5, Canvas and the like. Check out the Google-hosted http://www.chromeexperiments.com/ (which, really should be named HTML5 experiments, as most run fine on HTML5 browsers). You can get an idea of what is possible, including 3D rendering, complex games and some pretty amazing animations.
(source: chromeexperiments.com)
Sketchpad by Michael Deal
basically, this question has been around already.
The answer in short: no, HTML5 will not replace anything. HTML5 will however offer a standard for features currently only available through plugins. Once HTML5 is released, which is scheduled for 2022, it will be a great thing. Still, even by then, if IE survives, I doubt it's support will be outstanding.
There has been a very similar question to which I provided a rather lengthy but detailed answer: should web developers learn flash
My personal opinion about anyone who thinks HTML5 will replace 3rd party plugins is, that they lack basic understanding of HTML5's role or sufficient knowledge about any plugin and have little if any grasp of how the web evolves.
Yes, the day HTML5 is sufficiently spread for large companies to rely on it, many of them will be able to replace 3rd party plugins within their web applications. However, as pointed out in my other post, the web is constantly evolving. HTML5 does not provide new features, that weren't available using plugins. And HTML5 does not provide all features currently available using plugins. New types of apps, services and content distribution mechanisms will arise. Also, as long as JavaScript stays fully dynamic, JS runtimes will never be able to provide the same speed as runtimes designed to run bytecode generated from statically typed languages.
Personally, for the client side, I basically only target the Flash Player, because to me it is the most convenient platform. I am not afraid that HTML5 might kill flash, for a simple reason:
Until HTML5 is really usable and largely supported through sufficient user adaptation, it will take several years. In the same time, all major plugins will continue to evolve, as well as their eco-system, including developement tools, cross-compilers and compatibility layers.
Today, you already need no knowledge of HTML, CSS and sometimes even JavaScript to create webapps, using GWT, qooxdoo or other tools.
HTML+CSS+JS represents nothing more than a platform that more and more languages are able to target. Using reasonable amounts of abstraction, one will sooner or later be able to develop apps in a totally platform agnostic manner, causing virtually no overhead for the lion's share of all apps: GUI (including localization, validation etc.) and application logics.
In the end, there's no reason to get excited. Currently, both Flash and Silverlight exceed HTML+JavaScript implementations in speed and features exposed through the available API. That is, why people use it. Altough unlikely, some day they may become obsolete. In this bright, bright future, far, far away, I will be happy to compile my sources to run in a JavaScript interpreter rather than on AVM2.
On a vaguely related note: check out Haxe.
There are many high-performance apps with real-time data streaming and graphics in production today that have been built with Flex. You can see some examples of these in the flex.org showcase. As always, deciding on a technology comes down to what is being built, who it's being built for, and who is building it. Flash, Flex, Silverlight, HTML5, etc will all coexist.
The discussions I've been part of on this subject, pretty much always seem to come to the conclusion that, while the HTML 5 standard will be a a great thing, once it's in place. It will by definition be a standard, standards take a long time to change, therefore innovation will be driven largely by plugins like Flash and SL.
And yes you can do a lot of what Flash and SL can do with Javascript, however Flash/Flex has the strong point of being used for desktop installed Air applications, and Silverlight has the similar thing with their "Out Of Browser" functionality. These are things where they clearly have the upper hand over Javascript.
At the end of the day it's not a matter of who will kill who, but rather which tool is the right one for the job and what skills does you / your development team have.
That's my 2c anyway...
Did Flex replace HTML forms? Have HTML forms killed Flex? Has C++ replaced C? Has Ruby or Lua or Python killed Haskell or Scheme or assembly?
Seriously, what is the obsession lately over whether HTML5 will kill plugins? Is it so hard to imagine people using Flash for content that needs to stand out and maximize expressiveness, and using HTML5 for content that needs to utilize standard metaphors and maximize accessibility?
In other words, no - the thinking among thinking people is not that the HTML5 stack will kill Flash/Flex/SL. If things work as they should, the plugins will keep innovating what you can do with proprietary techniques, and HTML will keep taking the most successful of those innovations and standardizing them. And if things don't work well - if a plugin fails to innovate, or a new version of HTML is done badly, then they'll fade into obscurity as developers stick with whatever solves their problems.
I think it depends on the authoring tools and the efficiency of the browsers. It is reported that the upcoming Flash CS5 export content directly as a HTML5 canvas. So the canvas can be a quite reasonable flash substitution.
For "high-performance app like real-time graphics", see WebGL. Mozilla and WebKit already have experimental support for WebGL, which is based on the <canvas> element.
For sockets, there are WebSockets, which are also experimental in some browsers.
For background processing, which can improve the user experience, there are web workers (experimental again).
A lot of experimental stuff, but they are improving them constantly, so at some point, even without an HTML5 standard defining them, we might see games specifically targeted for a certain browser (actually, there is some proof of concept but I can't find the link right now).
I think JS already has killed Flash/SL/JavaFX. JS is the most used language on the web, so just add a few features, enhance some tidbits and voila. Flash is alive because of videos and games, no serious website uses Flash nor any other RIA. Just wait, it's going to be a hell of a ride the next few years.
I'm looking for some arguments to pitch to my boss and fellow developers.
We're currently finishing up the preliminary UI mockups and getting ready to move on to the next phases of development. In the meantime, I've been digging through the depths of the Carbon, Win32, and wxWidgets APIs attempting to make some of the controls have a more native look and feel on the Mac and Windows platforms.
The more I dig into the Win32 and Carbon APIs to implement the things we want in our project's UI, the more antiquated they feel, and the more I'm beginning to think that we should be implementing the project as described in the last paragraph here.
We're using wxWidgets for our current projects. wxWidgets is coming along on the wxCocoa port, but it doesn't look like it's going to be ready for prime-time before we start major development efforts on our new application. On the Windows side of things, it wraps the Win32 API rather than WinForms or WPF (likely due to native vs. managed code).
We're already designing the system with the MVC pattern in mind, thus aside from having to write two native UIs, it should be very doable, and, IMHO, easier to get the desired UI effects using modern APIs such as Cocoa and WPF.
I've been trying to push these points subtly, but the start of major development is coming soon. Does anyone have any suggestions on how to pitch using native UI toolkits in our next application vs sticking with wxWidgets?
Thanks in advance.
Create your core code in Standard C++ and use Objective-C++ with Cocoa to create your user experience on the Mac and C++/CLI plus C# with WPF to create your user experience on Windows. Follow the platform guidelines for the Mac in your Mac version, for Windows in your Windows version, and don't even bother thinking about trying to share user interface code.
One good way to manage this is, instead of just Model-View-Controller, following a Model-Model Controller-View Controller-View architecture. Your Model Controllers are platform-independent and manage the higher-level functionality of your application. (For example, its entire concept of documents, file format, job queues, and so on.) Your View Controllers are platform-dependent and mediate between your Model Controllers and your user experience.
Of course you'll probably also want some platform-dependent code at the model level too; for example to use NSOperation on the Mac and thread pools on Windows to implement job queues. Just create your own lightweight abstractions for that sort of thing.
Actually I think using Qt has become very interesting since it's now LGPL
Every time you add a layer of abstraction, you trade control over the details for more rapid development. You'll be able to get a lot done up-front using some cross-platform framework. On the flip side, when you want to do something that the framework doesn't support—and lets face it: it isn't going to implement all possible things those native APIs can do—you either have to implement it (for all platforms) using the native API, or do some other wierd hackery to get a "good enough" solution. And of course, when things go terribly wrong, having that extra layer of code you don't own makes it harder to debug. There really is something to be said for owning your entire stack as much as possible.
Writing two font ends is a lot of work, maintaining two front ends is a huge amount of work, if you need your program to run on multiple platforms go with a multi-platform toolkit.
If you write platform specific front-ends, each using the state of the art tools for that particular platform, you will get a much better user experience - but the cost of developing and maintaining those will be on the same order of magnitude as developing the entire application from scratch for each platform (yes, even with MVC).
Personally, I'd rather stick multiplatform and don't give a damn for that eyecandy, but if I wanted to pitch the use of those native APIs, I'd work out the (end-user-visible) differences between how things are done in different GUIs. If you can convince them that, in order to feel native, the program's user interface has to look and feel very differently on Windows and OSX (because of different design guides/philosophies/whatever), they should understand that, even with wx, you would still have to implement it twice, to accommodate those different requirements, so you might just as well use the real thing, i.e. the native API.
Also see this thread on the Google Chrome mailing list discussing the same choice of UI for Chrome on different platforms.
Win32 is definitely waay to old, but you might want to look into something like Microsoft Foundation Classes which is designed to do native development with C++. I assume that a similar thing exist for MAC.
Personally if I was in your situation I would properly also go for QT or WX.
Does anyone have any suggestions on how to pitch using native UI toolkits in our next application vs sticking with wxWidgets?
No one likes a corridor-wiseass.
I think action speak louder than words...make a small prototype of how you think it could be done, and show it. Maybe you have to do this in your spare time.
Cocoa is really great so I think that with little code you can show an idea...well, this require that you know Cocoa enough.