开发者

Starting to develop a backend for my Flash game, Java or PHP? [closed]

开发者 https://www.devze.com 2023-03-16 09:10 出处:网络
Closed. This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing th
Closed. This question is opinion-based. It is not currently accepting answers.

Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.

Closed 8 years ago.

Improve this question

quick question, Im starting to develop the backend for a F开发者_如何转开发lash game, and Im very used to AS3 sintax, and I know that Java has a very similar sintaxis, in the other hand I heard that it could be a little more complex to do than with php.

So, Im kind of new to php, and I could get used very quickly to Java, whats my best option?

(I need to do things like: user login, highscore table, etc)


It depends on the complexity that you have in the server side. Usually a Flash game do not need a complex business logic in the server side, I would use PHP in this case, Java otherwise.

If you are going to host this application, Java hosts are way more expensive than PHP ones also.


From what I understand here, Actionscript is more like JavaScript, not Java.

PHP and Java are both very suitable for a back-end to your game. I prefer PHP, but I am biased.

However, you are looking to stay within familiar territory, you should look at using Node.js, which is basically server-side JavaScript.


Yeah, I jumped from java to AS3 without any problem:D The one big advantage of php is that almost every server has it and with java is harder to find some reliable hostings. PHP could be also easier and little faster to develop some simple backend.


In terms of a similar programming experience one will find more comfort in Java than PHP. The main difference is that PHP is dynamic and the other two are compiled. The consequence is that debugging of Java and AS3 happens when it is being compiled, and in PHP when it runs. You also do not deal with predefining types in PHP for that matter and can totally ignore Object Orientation in it. Java and AS3 are more strict and require all these things. So in terms of choosing a language, Java will be more familiar (and easier) to pick up for a AS3 developer.

In terms of support for web based hosting and development, you'll find PHP more suitable since a majority of cheap hosting companies will have those installed by default. In addition, PHP was developed especially with the web in mind where precompiled web applications are not the best option in most cases. PHP in this regard deploys extremely easy (you just move the files onto your server). In terms of support for webdevelopment and specific examples for web based problems in combination with the support for PHP and deployment, you'll be better off with PHP.


Both have integration libraries, BlazeDS for Java, and AMFPHP for PHP, I haven't tried out the PHP integration I know from experience that Blaze is INCREDIBLY faster than XML or JSON for moving data back and forth. Assuming they're fairly equal then the question is where is it easier to find hosting, and which is better for you to develop and maintain.

0

精彩评论

暂无评论...
验证码 换一张
取 消