Is it possible to convert php to c? and other help!

C++, C#, Java, PHP, ect...
Post Reply
rapid3642
Posts: 45
Joined: Thu Nov 26, 2009 9:38 pm

Is it possible to convert php to c? and other help!

Post by rapid3642 »

Hey everyone,

I got a question that i tried researching on Google and found some interesting results but still doesn't satisfy for what im trying to do.

I wanna create a droid application but the code needs to be written in c and well i wanna make a mmorpg for the droid and i already have my game in beta right now and well is there any way to make an app for the droid to connect to my game? maybe any clients i can use or something?? i greatly appreciate any suggestions besides on learning c. links to programs would be very useful! im aiming for free programs or clients but if i really have to then i will look into a paid program or client.

Thanks for your time!
User avatar
Jackolantern
Posts: 10891
Joined: Wed Jul 01, 2009 11:00 pm

Re: Is it possible to convert php to c? and other help!

Post by Jackolantern »

So you have a PHP web game, and you want to make a Droid game that can connect to it? I can see the draw to that, since it would give a way to spread awareness of your game rather than just having it tucked away on a website. Now I know that the iPhone has a way to basically provide what amounts to a link as an app, and when executed it simply runs the browser and sends it to that website. Maybe Droid has something similar? Otherwise, it sounds like you would have to basically make a web browser as a Droid app so it can run your game, and that would be a crazy undertaking, not to mention completely redundant considering the browser already on every Droid phone. PHP and C do not directly convert because they serve such different application spaces: PHP is strictly a web scripting language, and C is a general purpose programming language with no out-of-the-box web capabilities.

However, I basically know nothing about the Droid platform, so maybe there is a better way to do this. But barring any option in the Droid platform itself or a way to distribute a link as a Droid app, I don't think there is much hope of making an executable to connect to a live PHP game.

Have you asked in a Droid-specific development community? They would definitely know more than us about how to do things like this.
The indelible lord of tl;dr
User avatar
Noctrine
Posts: 928
Joined: Thu Apr 23, 2009 9:57 pm

Re: Is it possible to convert php to c? and other help!

Post by Noctrine »

You can use Java also.

In general no, the nature of what you would be trying to do goes further than what PHP is scoped to. But check this topic out on StackOverflow:

http://stackoverflow.com/questions/1090 ... 91#1090191
Jesse Dorsey
ProjectANI - Lead Developer Person
http://about.me/jessedorsey
User avatar
hallsofvallhalla
Site Admin
Posts: 12026
Joined: Wed Apr 22, 2009 11:29 pm

Re: Is it possible to convert php to c? and other help!

Post by hallsofvallhalla »

you can program droid apps in C??

Since when, I thought it was all java
User avatar
Noctrine
Posts: 928
Joined: Thu Apr 23, 2009 9:57 pm

Re: Is it possible to convert php to c? and other help!

Post by Noctrine »

Google released the NDK for Android awhile ago.
Jesse Dorsey
ProjectANI - Lead Developer Person
http://about.me/jessedorsey
Post Reply

Return to “Coding”