OpenArena Message Boards

OpenArena Contributions => Development => Topic started by: pelya on June 15, 2012, 07:53:23 AM



Title: Android port
Post by: pelya on June 15, 2012, 07:53:23 AM
I want to port OpenArena to Android, and put some advertisements inside (in the menu/scoretable, not in the actual game).
I believe the license allows that, however I would like to get some approval from the developers and community (or at least to know I won't be blamed).
And I would like to give 20% of the money back to the OpenArena developers (I don't think it will be more than $20/month).

There are already three Quake 3 ports on the Android market (or Google Play, as they call it now), each one of them is paid to download and based on the Kwaak3 engine (I'll use parts of it too).
They follow the common control scheme of Android 3D shooters - you're dragging your finger to rotate the camera and aim, you're tapping to shoot (or there's a dedicated shoot button).
My port will be free, and with touchscreen-optimized controls (hopefully).
The basic idea is borrowed from the Destroy Gunners game - you have a crosshair that follows your finger all over the screen (along with shooting your gun there).
Dragging the crosshair to the screen edge rotates the camera (there are dedicated on-screen buttons for rotating camera in the Destroy Gunners, they are inconvenient so I won't be copying them).
Also it has the third-person view, which gives you a wider look at the things happening around you (if you consider third-person view a cheat, I can assure you that touchscreen controls cannot ever possibly beat the mouse in 3D shooters, and I'm not adding an aimbot).
I will add a bit of accelerometer control - tilting your phone will instantly rotate the camera 90 degrees, so it's more for a quick maneuvers, not aiming (aiming with accelerometer is a pain).
Another addition is a weapon selection buttons, located around your crosshair/finger in a ring-shaped list, you will press them with another finger (I'll probably make previous/next weapon buttons, and dedicated buttons for rocket, railgun, gauntlet, and sniper view). Also there will be usual weapon selection buttons near the screen edge (although I've kept missing that button in Destroy Gunners, it's hard to switch your focus away from crosshair during game action).
And of course there will be on-screen joystick for running and jumping, you can't make a touchscreen-oriented 3D game without a joystick.

I think I'll have something to show at August, also no promises that I'll succeed and the result won't suck.
Edit: You can download it here: Google Play (https://play.google.com/store/apps/details?id=ws.openarena.sdl), compiled binaries and source archive (https://sourceforge.net/projects/libsdl-android/files/OpenArena/), SDL for Android (https://github.com/pelya/commandergenius), OpenArena engine (https://github.com/pelya/openarena-engine), OpenArena game logic (https://github.com/pelya/openarena-vm), compilation instructions (https://github.com/pelya/commandergenius/tree/sdl_android/project/jni/application/openarena)


Title: Re: Android port
Post by: kealper on June 15, 2012, 05:00:48 PM
Hmm... If you get the go-ahead for this, it could turn in to something very nice... The ability to play on normal OA servers against PC players would be very cool, though if that were to happen, the Android game client would have to provide some sort of simple aim helper (similar to the ones in console FPS games) so the PC players won't curbstomp the Android players.

If it's done right and advertised in places, it could also help bring new blood to the game.


Title: Re: Android port
Post by: GrosBedo on June 27, 2012, 10:24:00 AM
The idea might be nice and indeed bring a new audience, but is it really fair to make such an application paid, and in plus that you keep 80% of the benefits just for porting it, when the dev did all the work (except your port ofc)?

Making a port is nice, but if you're going to monetize an opensource projet, it needs to be carefully thought out and it better be done in a fair way.

/EDIT: also it might be redundant with Zeus Arena.


Title: Re: Android port
Post by: PopeJo on June 28, 2012, 12:03:49 AM
The idea might be nice and indeed bring a new audience, but is it really fair to make such an application paid, and in plus that you keep 80% of the benefits just for porting it, when the dev did all the work (except your port ofc)?

yes it is fair.
you can look it up in the license, the dev's have agreed to. (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/DeveloperFAQ

if it brings big loads of money a donation can be considered. but you shouldn't try to turn the GPL/public domain against those who make use of it.

it is actually very nice from pelya to offer some share on the income. and as it, in all likelyhood, wont be 10.000 bucks, but rather 10 bucks a month, he will get out of it, it is just a friendly gesture anyway.


..sry if this sounds a bit harsh .. I just woke up. there's no offense ment  ^-^


Title: Re: Android port
Post by: Gig on June 28, 2012, 12:33:44 AM
Of course, it should be GPL'd, too (and you cannot forbid other people to sell it, too).

And I read somewhere that very, very few app developers get much money from the apps... only those very popular!


Title: Re: Android port
Post by: pelya on August 12, 2012, 01:47:07 PM
A bit of progress here - I've made an alpha version (http://sourceforge.net/projects/libsdl-android/files/OpenArena/), it's not playable yet, and some textures are shown incorrectly. It runs on my Galaxy Note with rather bad FPS (like 5-10 FPS when bots are around). Also, no ads yet. It's based on the Undeadzy ioquake3 sources, and uses ioquake3 renderer.
The sources are here: SDL for Android (https://github.com/pelya/commandergenius), OpenArena engine (https://github.com/pelya/openarena-engine), compilation instructions (https://github.com/pelya/commandergenius/tree/sdl_android/project/jni/application/openarena)

The idea might be nice and indeed bring a new audience, but is it really fair to make such an application paid, and in plus that you keep 80% of the benefits just for porting it, when the dev did all the work (except your port ofc)?

Making a port is nice, but if you're going to monetize an opensource projet, it needs to be carefully thought out and it better be done in a fair way.

/EDIT: also it might be redundant with Zeus Arena.

No one can prevent you from compiling your own version without ads from my sources, an even publishing it on the Google Play.
Did you manage to get the sources of that Zeus Arena game by the way? The app extracts them into 7z archive, which is either broken or password-protected, anyway they are pretty much inaccessible.


Title: Re: Android port
Post by: GrosBedo on August 26, 2012, 09:28:23 PM
I didn't know that you planned to keep the sourcecode available on the web, nice initiative!

About Zeus Arena, no and I did not even play it (my old phone will be quite mad at me if I force it to run such a game). The only sourcecode on the web that I've found is this one (now unavailable it seems so I attach it to this thread). It's v1.0C compatible with Xperia, but it seems that now Zeus Arena is v3.0a, which sourcecode you can download from Google Play or here:

https://play.google.com/store/apps/details?id=zeus.arena.source&feature=more_from_developer#?t=W251bGwsMSwxLDEwMiwiemV1cy5hcmVuYS5zb3VyY2UiXQ..

But I guess that's what you're talking about, with the broken archive. You may try BlueStacks to install it on your computer directly and try to unpack it on your filesystem, maybe it'll work better, or if that still doesn't work, you can always buy the game and ask for the sources, the dev will have to comply since it's necessarily GPL'ed.

Good luck for your project, I hope it will turn out as you expect.


Title: Re: Android port
Post by: pelya on November 30, 2012, 11:27:51 AM
Some news here - I've made a playable beta version (https://sourceforge.net/projects/libsdl-android/files/OpenArena/). I would be glad if you try it and give me some feedback.
Enabling hardware floating point in compiler options did wonders to the framerate - it's now between 20 and 60 on my Galaxy Note.

There are three ways to control the camera - touch near the screen edge, accelerometer, and multitouch.
Shaking your phone on the side will make camera rotate 90 degrees instantly, tilting it will rotate the camera gradually.
While shooting, touch the area to the left or right to the crosshair with second finger, that will make camera rotate, touching below or above will toggle switching weapons or sniper view.
If you need to jump - tap the joystick, there's small delay between your releasing joystick and your game character slowing down, so you can jump while running without losing speed.
There are your usual pack of on-screen buttons above joystick, they will toggle weapon, toggle sniper view, show scores, and toggle QWERTY text input (you can invoke Quake console by typing ~ or ` there).

I'll work on this port for one more week or two, before publishing it, it still has some bugs - it does not draw any helping hint about multitouch controls, controls are not configurable yet, in-game chat is not working, camera rotates too fast in sniper mode, and I want to make railgun shoot when you release your finger, not when you hold it, so you can aim precisely.

I've decided that I will not use advertisements, because it's too much trouble for me (I don't want to visit my local citadel of bureaucracytax agency), so I'm offering OpenArena devels to have all the revenue - just register at http://www.google.com/ads/admob/ and give me your publisher ID.
I don't mind publishing it without ads either, however if I'll do that, I won't be able to add ads later, because that will irritate users, so I would like to hear your decision about ads in two weeks.

Every online server I've tried to join uploaded me it's own .qvm files, and that of course breaks touchscreen support, so I guess I'll have to change the network ID of the game, so that it will see only Android servers.
Also, I've added an Arachna skin from this thread (http://openarena.ws/board/index.php?topic=4578.0) to the installation, I wonder why you didn't add it to SVN yet, because it's awesome.

Edit: I've released an updated version (0.8.8.05) (https://sourceforge.net/projects/libsdl-android/files/OpenArena/).
I've disabled accelerometer controls, they are of no much use (I've tried to play while walking, that was awkward).
I've tried to use two additional buttons for turning camera around, but that was also not very comfortable.
So I've settled with one big button above the joystick, which will point camera in the direction you were running to before clicking that button. It won't activate if you're sliding your finger from the joystick - you have to let go of the joystick first.
That kind of controls are comfortable to me, but they definitely need some time to get used to, and I don't know if other people will like it that way, so your comments and suggestions are welcome.


Title: Re: Android port
Post by: fromhell on November 30, 2012, 05:58:47 PM
I wonder why you didn't add it to SVN yet, because it's awesome.

My policy is to only add things posted by authors in the SVN Commits thread.


Title: Re: Android port
Post by: mogadishur on December 03, 2012, 10:27:25 AM
Nice job!

Seems to work really well, but is it possible to have it run like ordinary OA? I use an android-stick(MK808) with a keyboard and mouse, so it's much like a regular PC and would be better fit to ordinary OA.


Title: Re: Android port
Post by: pelya on December 03, 2012, 10:59:29 AM
You cannot play it like "ordinary OA", even with mouse, because when you move mouse to the edge of the screen, you're done, and your crosshair won't move any further - Android does not allow application to capture and re-position mouse, and it does not report relative mouse movement, only absolute coordinates.

Maybe it will be possible in the future to play with keyboard, but this is low priority for me - you can use Kwaak3 to play OA with keyboard (actually, there's no other way to play it). My main priority are phones and tablets.


Title: Re: Android port
Post by: pelya on December 15, 2012, 03:13:59 PM
I've published my Android port to Google Play (https://play.google.com/store/apps/details?id=ws.openarena.sdl). Also I've made a handy source archive with all repositories, it can be downloaded here (https://sourceforge.net/projects/libsdl-android/files/OpenArena/).


Title: Re: Android port
Post by: Peter Silie on December 16, 2012, 04:13:56 AM
Great work!
But what about using the gyroscope to improve movement? I realy dislike the movement on all FPS so far.
Imagine the fun you could have, if you move your phone/tab to the direction you like to watch!
The crosshair is alway in the centre of the screen. You just need "keys" for actions like run, shoot, weapon select and so on.
This is an os project, so you are free to try this new way of control.
This is what i mean:
https://play.google.com/store/apps/details?id=com.google.android.stardroid


Title: Re: Android port
Post by: MegaAIM on December 16, 2012, 10:09:35 AM
Ive finally gotten a chance to download this .apk file, zeus arena wasnt working anymore. Ive installed the file and ill post here for some feedback on my experience with it.

EDIT: As far as i got was to the start men. It appeared blocky with large box text it was hard to see what exactly the words were. Im sure it could be something wrong on my part, the phone I installed it on is Pantech Crossover (http://www.google.com/shopping/product/12946085047746158070?hl=en&sclient=psy-ab&q=pantech+crossover+p8000&oq=pantech+crossover&gs_l=hp.3.2.0l4.901353.904308.0.906576.17.10.0.7.7.2.487.1364.6j2j0j1j1.10.0.les;..0.0...1c.1.oh_N7fbZqgc&pbx=1&bav=on.2,or.r_gc.r_pw.r_qf.&bvm=bv.1355325884,d.dmQ&bpcl=39967673&biw=1600&bih=798&tch=1&ech=1&psi=7_LNUIXGMamj0AHus4CwBg.1355674340800.3&sa=X&ei=e_bNUIShLeis0AH8ioCADg&ved=0CMgBEMwD) anyone feel free to say what could be wrong.

Looks like it could be a really good addition to the Google Play store !


Title: Re: Android port
Post by: pelya on December 22, 2012, 10:03:53 PM
So, a week have passed, and OpenArena gained a paltry 191 downloads on Google Play (to compare: SuperTux (https://play.google.com/store/apps/details?id=org.lethargik.supertux2), a much simpler game, got 471 downloads in a week after release, and I've put much less effort in that port).

I've played some of the "competitors" games (that is, other Android 3D shooters, there are surprisingly many of them, if you search for "FPS shooter"), and fixed the swipe-to-aim controls, so that you can aim while shooting. I've even made them the default controls, because that control scheme is very common. I still think my control scheme is much better for closed or semi-closed maps, however big open maps, such as wrackdm17, will benefit from swipe aiming, because you're doing more sniper-things on such maps.

Speaking of maps - I'm finding most OA maps very inconvenient for touchscreen, because narrow corridors and sharp corners and hard-to-climb sidewalks suck. I've went through DM maps, and picked five of them for my dedicated server: pul1duel-oa, am_underworks2, am_galmevish2, mlca1 and wrackdm17. (pul1duel-oa is quite small for 16 players, on the other hand noone visits my server anyway :'( ) So, it would be nice if you'd advice me some more maps, suited to mobile devices (open maps with no lava and no cat-walks preferred).

But what about using the gyroscope to improve movement? I realy dislike the movement on all FPS so far.

I've tried a simple accelerometer left/right controls, and they've failed. Here you're proposing a complicated gyroscope controls, and I think they will fail even more miserably.
Google Sky Map may work okay with gyroscope, but it's not a game, and there are very few game concepts that work okay with tilt controls (Papi Jump, Naught, and that tower-building game which name I've forgot).
So, I'm challenging you to try this game (https://play.google.com/store/apps/details?id=com.shinybox.sw3d) with "Motion controls" option, or this hilarious game (https://play.google.com/store/apps/details?id=com.extrareality.SpaceInvadars). And now imagine you need to rotate your phone 360 degrees... while sitting on a toilet :P

Pantech Crossover (http://www.google.com/shopping/product/12946085047746158070?hl=en&sclient=psy-ab&q=pantech+crossover+p8000&oq=pantech+crossover&gs_l=hp.3.2.0l4.901353.904308.0.906576.17.10.0.7.7.2.487.1364.6j2j0j1j1.10.0.les;..0.0...1c.1.oh_N7fbZqgc&pbx=1&bav=on.2,or.r_gc.r_pw.r_qf.&bvm=bv.1355325884,d.dmQ&bpcl=39967673&biw=1600&bih=798&tch=1&ech=1&psi=7_LNUIXGMamj0AHus4CwBg.1355674340800.3&sa=X&ei=e_bNUIShLeis0AH8ioCADg&ved=0CMgBEMwD)

Eh, that device has 3.5 inch screen, I was thinking of something with at least 4.3 inches when I was porting OpenArena. At least you can navigate menus using the arrow keys.


Title: Re: Android port
Post by: Neon_Knight on December 22, 2012, 10:15:11 PM
Perhaps for that port you might want to take the "UT Console Version" route and include DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Unofficial_OpenArena_Maps]some GPLd small maps (http://([b) which aren't included into OA but which will fit better to the overall system of that port?

The console versions of UT (http://liandri.beyondunreal.com/Unreal_Tournament#Maps) scrapped the big maps and included many console-exclusive small maps which fit better with those ports.


Title: Re: Android port
Post by: MegaAIM on December 22, 2012, 11:07:08 PM
Quote
Quote from: MegaAIM on December 16, 2012, 11:09:35 am
Pantech Crossover

Eh, that device has 3.5 inch screen, I was thinking of something with at least 4.3 inches when I was porting OpenArena. At least you can navigate menus using the arrow keys.
So im guessing im a bit shut out from this :P


Title: Re: Android port
Post by: pelya on January 04, 2013, 04:08:31 PM
DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Unofficial_OpenArena_Maps]some GPLd small maps (http://([b)
Thanks for the link, however small maps do not play well with touchscreen - I need some big, open maps, like this one (https://www.youtube.com/watch?v=ssSdTy9Ynr0#t=44s) (it's a video of a another Android 3D shooter, it was published at the same week when I've published OpenArena, and those bastards already have 1M downloads  :'( ).


Title: Re: Android port
Post by: pelya on January 25, 2013, 10:26:17 AM
I've added support for PlayStation 3 gamepad, it should work though with any gamepad, which has two analog sticks, and which is recognized by your Android device (most gamepads work with USB-OTG cable, I did not try Bluetooth).
You'll need Android 4.0 or newer to support analog sticks.
My impression from playing with PS3 gamepad is not that good - it seems to be easier to play with touchscreen, however you'll probably get used to it over time. Also, I did not try to play other 3D shooters, would be nice to check how competitors implemented gamepad support.

Also I've compiled a special PC-compatible Android build (http://sourceforge.net/projects/libsdl-android/files/OpenArena/OpenMisery-0.8.8.18.apk/download), you may use it to join PC servers and get humiliated there (I've just been told "pelya has mouse sensitivity 0.1 lol" on some random AfterShock server, then I've miserably died).

My future plans are to add two more types of touchscreen control, which are minor variations of the default swipe controls, and to add support for gyroscope aiming, as Peter Silie suggested (I realized I have to try it first before I can really tell if it sucks or not, also gyroscope is way more accurate than accelerometer which I've tried to use before).
My more ambitious plans are adding VoIP support (requires adding support to SDL and Java layer), and 4-player split-screen mode, with the help of Spearmint (https://github.com/zturtleman/spearmint) engine.
Spearmint (formerly ioq3ztm) is a heavily modified ioquake3 engine (both engine and VM files), with split-screen support, it's used for Turtle Arena game, and it also supports the original Quake 3 data files.
Did anyone tried to run OpenArena on Spearmint engine? How many differences are there in OpenArena, compared to ioquake3 code? I guess most differences are cosmetic, OpenArena does not change Quake 3 gameplay a lot.
I hope I can get it working when Ouya will be released.


Title: Re: Android port
Post by: Neon_Knight on January 25, 2013, 10:37:53 AM
Never heard about Spearmint. I might as well try it.


Title: Re: Android port
Post by: Peter Silie on January 25, 2013, 11:14:10 AM
Works fine on my tablet.
I am curious about the gyroscope version ;D


Title: Re: Android port
Post by: Gig on January 25, 2013, 12:13:46 PM
Pleya, maybe a way to tell if your PS3-gamepad controls are responsive enough, could be to play a little of DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Q3A/Quake_III_Revolution]Q3 Revolution (http://([b), if you have a PS2, or a PS2 emulator (there are even USB converters to attach DualShock/DualShock 2 (PS1/PS2) controllers to the PC). You may somehow compare the "feelings"...


PS: About the differences between OA and ioquake3, you mentioned gameplay. Gameplay is managed by game logic (see OAX thread), and OpenArena added various features to it. However, it's also true that there are some features use both gamecode and engine improvenents, IIRC. I'm sorry I have to go now, however I'm not very expert in such things..


Title: Re: Android port
Post by: pelya on January 28, 2013, 08:51:17 AM
Some more news: Android release reached 5000 downloads on Google Play, and we've got a second dedicated Android server, located in US east coast, thanks to a generous guy named CyberXZT.
There are still not many people playing daily, hopefully that will change, as more people download it.


Title: Re: Android port
Post by: Neon_Knight on January 28, 2013, 09:00:38 AM
Perhaps adding more maps or a mappack as DLC might work?
Some special versions of current maps can even be done to adapt to the portable gameplay.


Title: Re: Android port
Post by: pelya on January 28, 2013, 10:10:59 AM
I don't want to push some specific maps onto users (except oa_akomdm3, when we'll get the final version), I would rather make users to pick up the best maps, and I'd just add them to the game directly (and I'll be happily coding the game engine instead of playtesting each map found across internetz).
I can make an optional download package, if you'll tell me which maps to include, SDL already includes the download dialog, so it's quite easy.


Title: Re: Android port
Post by: pelya on February 06, 2013, 01:36:58 PM
I've added gyroscope aiming, and it's surprisingly good. Not all devices have gyroscope, and it eats battery. Also, minor fixes here and there:

New touchscreen control mode - tap to fire, the fire button will appear under your finger when you lift it up from the screen.
I asked my friend to play-test it, he mostly used gyroscope, and was puzzled about abscense of fire button. After I've told him that you should tap the screen, he kept tapping it frantically all over, instead of holding a finger on the screen - OA reacted by shooting once each three taps. There was some swearing, so I did not set the new mode as the default one.
If you have any good ideas about touchscreen controls - say them, I'm willing to add every idea.

Fixed white textures on old Android 2.3 devices with broken OpenGL drivers. Sony devices are especially bad about this, because they have tough casing, so users won't dump them for newer, better, and less buggy devices, and complain instead that apps are bad.

Railgun auto-zooms. No way to disable that yet.

Swipe screen to instantly rotate 180 degrees. Now OA feels more like a game designed for mobile, than a straight port from desktop.


Title: Re: Android port
Post by: Peter Silie on February 06, 2013, 03:15:05 PM
Unfortunately it didnt work very well on my sony device :(
But i had great fun to look around!

EXCELENT


Title: Re: Android port
Post by: pelya on February 06, 2013, 03:39:57 PM
The guy behind US-located dedicated server proposed to have some weekly game event, because there are lot of players, but they join at random, see empty server, and leave.
The easiest way is to create an online calendar, in iCal format, and I'll update OpenArena so it will ask users to subscribe to it.
I would like to ask, is it possible to create such calendar on openarena.ws server, so it will be official, moderated by fromhell, and admins of dedicated servers will have some centralized place to post their events?
I don't mind creating it on some random free hosting service - there are only two Android dedicated servers anyway, but there might be some problems later, when you want to post your event but don't know whom to ask, etc.
What do you think?

Unfortunately it didnt work very well on my sony device :(
Do you have some imprecise or noisy gyroscope? It should have asked to calibrate it at the beginning, did it calibrate okay? Is it a physical device, or virtual device, calculating phone angle from accelerometer and compass? You can check that with one of these apps (https://play.google.com/store/search?q=sensors&c=apps) - if your gyroscope manufacturer is "Google inc", then it's a combined accelerometer/compass, and it's shaky and generally bad.


Title: Re: Android port
Post by: pelya on February 21, 2013, 11:12:50 AM
Android release reached 10 000 downloads, yay. Now there are actually some people playing on dedicated servers, one time I even saw 4 players, including myself.
Next release will probably be just a bugfix - I've got a bunch of requests to add more configuration options, most popular is to disable swipe gesture.
I'm currently a bit busy, so it may get postponed to the March.
Also, I've uploaded OpenArena to the beta version of Ouya store - it does not have any statistics, so I cannot even tell you the number of downloads.
Someone already tried my build on Ouya, and told me that it works okay with it's gamepad. I would also like to support the touchpad part of Ouya gamepad, but it's currently impossible (as far as my little test app reports), hopefully they will add touchpad support in the future.

DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Main_Page#cite_note-2]Quote from Wiki: (http://([b)
Quote
Even if these third party people may visit the official OA forums by now and then, we have no direct control over their works, that may be considered "forks" of the original project. We are not responsible if they ask for payment.

If you wish, I can transfer the Android project ownership to some trusted member of community - you only need to create an Android developer account on Google Play (it costs $25 one-time). Also, it would be nice if you'd have an actual Android device that can run OA.


Title: Re: Android port
Post by: Gig on February 21, 2013, 12:07:02 PM
I added DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/index.php?title=Main_Page&diff=13570&oldid=13506]this statement (http://([b) not only for your port, but also for other ports (well, I mentioned Android also to give hint to players that an Android version of the game exists).
Considering anyone can re-package and sell the game without the need to inform here, there may be some ports of the game we don't even know the existence. I wanted to specify that the official game is the one pleople finds on the official site, also because I was thinking that the other versions may have differences (e.g. I know your port changes the game from first person to third person, and I suppose you had to drop out MOD support -I suppose you had to change the gamecode to allow the touch interface, isn't so?-, so the whole part about MODs does not apply to your port).
Also, there is the Zeus Arena Android app: I don't know/remember if its author ever posted on this forum, but anyway he actually asks for some money to download the app.

I have noting against making your port an official part of the OpenArena project... but this would require Fromhell's OK, I suppose. I suppose Fromhell or Sago should have access to the accounts that hold the project (I don't know if they are Android users or not).

I think we can already create a Wiki page about your port... let's think about the best name before creating it. But until Fromhell states it's an official port, we just have to mention it as third-party stuff.
PS: also a "list" page with links to all known OA portings may be nice.

PPS: Your port is a nice idea (it can give some advertising to the game, a thing we really lack!), and I wish to try it when I will have resolved some problems with my Android phone. I don't know anyway how well will it run on a single-core phone...


Title: Re: Android port
Post by: pelya on February 21, 2013, 01:05:54 PM
Yes, there are differences, however it's still compatible to mods (more by chance than intentionally, you also need to select "fire button" touchscreen controls). You can also disable third-person view from options. Also, I made gamespeed configurable - it's marked as "cheat" in vanilla OA. There are other changes, most of them are just options in UI.
Anyway, I suppose the official status for this port won't happen until Fromhell gets some kind of Android tablet. I'm open to suggestions though, how to make it more official, as long as that won't break controls or gameplay.


Title: Re: Android port
Post by: Suicizer on February 21, 2013, 06:36:54 PM
Is strafejumping actually enabled?

I seriously never see people playing except,those bots.
The number of downloads are very unaccurate as I download OA-Android 3 times now.


Title: Re: Android port
Post by: pelya on February 22, 2013, 12:14:45 AM
I did not modify game physics at all, so strafejumping should be enabled. On the other hand, my screen joystick code cuts speed vectors values at the corners, so it's not 127 when moving diagonally, but 127/sqrt(2), which is 89. On yet another hand, game code normalizes these vectors, so that final target speed is still 127. And performing it with touchscreen is almost impossible, so I cannot test it.


Title: Re: Android port
Post by: Gig on March 02, 2013, 05:39:10 AM
Pelya, I've downloaded the app and it's downloading the pk3s.

In the meanwhile, I can suggest you to write in the app description that it is actually possible to also use firstperson (maybe you may also include a screenshot taken with firstperson), because I've seen comments on the store complaining the lack of first person mode.

Another thing may be some kind of "pause" or "abort" button when you are downloading the initial PK3 files. It takes a long time also if you are using Wifi+ADSL, so people may have to abort downloading (due to real life) and to do resume it later.


Title: Re: Android port
Post by: Suicizer on March 02, 2013, 12:39:30 PM
I did not modify game physics at all, so strafejumping should be enabled. On the other hand, my screen joystick code cuts speed vectors values at the corners, so it's not 127 when moving diagonally, but 127/sqrt(2), which is 89. On yet another hand, game code normalizes these vectors, so that final target speed is still 127. And performing it with touchscreen is almost impossible, so I cannot test it.

Well, as it's nearly impossible, I suggest to put it off by default.


Title: Re: Android port
Post by: Gig on March 03, 2013, 04:41:47 AM
I did not modify game physics at all, so strafejumping should be enabled. On the other hand, my screen joystick code cuts speed vectors values at the corners, so it's not 127 when moving diagonally, but 127/sqrt(2), which is 89. On yet another hand, game code normalizes these vectors, so that final target speed is still 127. And performing it with touchscreen is almost impossible, so I cannot test it.

Well, as it's nearly impossible, I suggest to put it off by default.
Do you mean something like setting "dmflags 128" by default?
(DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Special_game_options#Non-accelerated_jumping
I don't know, I still have to figure out how to enable cg_drawspeed.

@Pelya. If someone forces program closure during the initial pk3 downloading, does it resume downloading that file the next time, or it does keep an incomplete file, downloading the next one because feeling the previous one as already existing?
In any case, I know you warned about using wifi for first run in the app descritpion, anyway you may repeat that at program launch, to allow people to attach wifi if they forgot, or to quit the program and launch it again later.


Title: Re: Android port
Post by: pelya on March 03, 2013, 06:06:20 AM
It will resume downloading from the place where it stopped, so you can just kill the app, then launch it later.
I think I can show a dialog if you press Back, which will tell you that, and another dialog, when the app lainched first time.


Title: Re: Android port
Post by: Gig on March 04, 2013, 04:23:18 AM
Yes, I think a way to exit the program from there may be useful. Maybe not all android users know how to force the closure of an application. I think almost all "apps" should have an "exit" feature. Fortunately, after OA is completely installed, one can use the game's own "exit".

For the moment I haven't yet seen the "manual" video... anyway, after some use of the app, I can start asking/telling you some things/suggestions:

1) I like the fact it's free and that it does not contain ads. It's in the mood of OA. Anyway, if you will decide to add ads in the future, please place them in the initializing screen only.

2) In "Device configuration" (and sub-menus) you may add more infos (using a second line with smaller fonts?) to many of the options, to explain better what they do.... sometimes also mentiong the suggested value.

2.1) "Data installation location" may write down the path used in the two different cases. Also a question: if I change it, does it move the already downloaded files to the new location and deletes the old location?

2.1.1) Another thing: Android (apps management) tells me the app is just 8 MB, it does not count the 400+ MB downloaded to the SD. Will they be automatically deleted if I would uninstall the game?

3) In "Additional controls": I thought you said Accelerometer was not supported, instead I find this option here. And why is the "enable accelerometer" option there (in initial "Device configuration"), while the "gyroscope on" option is in the OA main menu and Controls menu? Maybe the two should be one next to the other?

4) In "On screen keyboard", you may place "preview" screenshots of the various keyboard themes/size/size of images/transparency.

5) In "on screen keyboard", "Cusomize on-screen keyboard layout" should show you your current layout before starting modifying it, then you should be allowed to choose "modify layout/back/restore default". Also after having modified the layout, I think it should ask "accept changes/discard changes".

6) I suppose "Calibrate gyroscope" may tell "It seems your device doesn't have a gyroscope." or similar, if you don't have one. It may also warn there that gyroscope is much more accurate than accelerometer, but uses more battery (as you said in the app description... I don't have it, so I can't test).

6.1) Isn't there a "calibrate accelerometer" option? Playing with accelerometer is quite difficult to me, because if I hold the device in normal position the character goes back... I suppose some kind of accelerometer calibration may be needed.

6.2) Maybe you may give the option to choose if to use the accelerometer/gyroscope to move the character (go forward/back/strafe left and right) or to aim (turn left and right, look up and down).

7) Some settings, such as "Remap physical keys", should have a "reset do default" button. You may also tell that the game itself has got "setup"->"controls" menu to associate keys to controls.

8 ) In "What kind of navigation keys does your device have?", what's the difference between "Arrows" and "touchscreen only"? I tried both and noticed nothing different. My device has got a physical Qwerty keyboard, with arrows keys.

9) Once loaded the game, there is always an icon in the upper left corner. If clicked, it allows to type text, but I don't know what it does. While in-game, it allows to "say" (chat), but when not playing? Console commands maybe?  ???

9.1) By the way, while pressing it in-game and so entering the text for to "say", maybe the screen may show "Chat:" or "Say:" to let users understand what are they supposed to type in the text field.

10) Is there a way to show the console, at least its output?

11) How to select the gauntlet? The first time I played, I had the impression the weapon bar was touchable, and in that way I suppose one may have selected it. But in later tests, I've seen the weapon bar is not touchable, so how to select the gauntlet, unless binding it to some physical key?

12) I'm not good playing with the touchscreen. So I binded the up/down arrows of my qwerty keyboard to look up/look down (and fire to a button different than ctrl, that I don't have), and I play with the keyboard quite happily.  :) This way, I noticed that if I press the "t" button to start writing a chat text, the "say:" appears for an instant and immediately disappears, so I can't use it. This makes me suppose I would not be able to bind "say_team" to a key....  :-[

13) Entering the "demos" menu, the "back" and "play" buttons seem to do not work.

14) Is it possible to enable "cg_drawspeed" and "cg_drawfps"?

15) You may consider using a DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Manual/Graphic_options#Weapon_bar]weapon bar (http://([b) of those that give an indication of how many ammos you have got. Just an idea, considering switching weapon is not so comfortable as when you have a mouse wheel.

16) In the battery usage statistics screen of Android (I have Android 2.3.4), the line of OpenArena takes three or four times the height of any other program, with a lot of empty space. I have no idea about the reason, but it does not look good.

17) I can't use my "shift" physical button to "walk" with the touchscreen (while it works together with the physical WASD keys)... it's a little strange considering that the "c" physical button actually allows me to move crouched, also moving with the touchscreen. Maybe it's due the fact "c" is a standard button and "shift" is a special one? I don't know.

17.1) Any way to crouch using the virtual keys? It is also used to go deep in water. I suppose one has to manually remap a virtual button, like the sixth, to the "c" key, right?

18) In the various "themes" for the virtual keys, there is no one that uses images or letters that refer to the actual effects of the virtual keys (e.g. a "J" or "up arrow" to jump, a "W" or "a stylized weapon or bullet" to change weapon, a "S" or a "table" for the score table...). Is this due to the fact one may remap those buttons and they may do different things?

Is this enough feedback for the first impressions?  :)

Pelya, anyway you deserve contratulations. It looks a very good porting.  :)
Nice job!  ;D

P.S.: Just a few of things more:

19): If I enable virtual button 6, it is displayed on all game screens. Is this voluntary?

20) The "four ways" virtual stick is used for movement (like the WASD keys), but its sections do "light" if you press the physical keys that correspond to aiming (turn left/right and look up/down). This sounds a little strange. Is there a purpose for that?

21) I suppose some players may like a layout where you see two virtual joysticks. One for movement and the other one for aiming.
Just like the double tap on the movement one makes you jump, I suppose a double tap on the aiming one could make you fire. But I don't know how to deal with the fact some weapons need continue firing and some weapons need single shots...


Title: Re: Android port
Post by: Gig on March 06, 2013, 06:33:56 AM
Pelya, are you still there?

Another thing:
At least at first times, one may have to come back to change those "device settings" quite often. This means you have to close the game and launch it again from your app drawer each time. If possible, it may be nice to recall that "device settings" menu from within the game, without closing it (from the SETTINGS menu of OA, maybe); if this is not possible (e.g. because one would need to restart the game anyway to appy some changes), you may however consider to place a button in OA main menu, that would automatically close OA and re-launch it, passing through the initial loading screen (and thus, giving the ability to access the "device settings" menu quickly enough).


And I'm quite interested into knowing how does this OA Android port manage "homepath" and "basepath", and their relationship with Android's "move to SD" and the option in device settings that allows to select the folder where to download the 400 MB of the game.

By the way, I think you really could write a page in the wiki (with sub-pages if needed) providing help and useful infos for your Android users. I can help if you need some help with wikia.


Title: Re: Android port
Post by: pelya on March 06, 2013, 08:21:52 AM
I'm still there, sorry for not replying.

At least at first times, one may have to come back to change those "device settings" quite often. This means you have to close the game and launch it again from your app drawer each time. If possible, it may be nice to recall that "device settings" menu from within the game, without closing it (from the SETTINGS menu of OA, maybe); if this is not possible (e.g. because one would need to restart the game anyway to appy some changes), you may however consider to place a button in OA main menu, that would automatically close OA and re-launch it, passing through the initial loading screen (and thus, giving the ability to access the "device settings" menu quickly enough).

That's part of SDL Java code (and I hate Java), it needs rewriting for a long time, so it won't happen anytime soon. I'm not a fan of closing-and-restarting idea.

And I'm quite interested into knowing how does this OA Android port manage "homepath" and "basepath", and their relationship with Android's "move to SD" and the option in device settings that allows to select the folder where to download the 400 MB of the game.
On Android port both "basepath" and "homepath" equal to current directory, SDL will change current directory to SD card before launching OA code. Android "move to SD" will move shared libraries (SDL + OA executable) from internal storage to SD card, this will save you around 3Mb space on internal storage, it has nothing to do with OA 400Mb data location.

By the way, I think you really could write a page in the wiki (with sub-pages if needed) providing help and useful infos for your Android users. I can help if you need some help with wikia.
Uh, okay, I'll write it eventually. I still have lot of bugs to fix.

1) I like the fact it's free and that it does not contain ads. It's in the mood of OA. Anyway, if you will decide to add ads in the future, please place them in the initializing screen only.
It will not contain ads, because adding them later after releasing ad-free version is kinda lame. I also thought of allowing individual servers to show ads, to encourage more servers (by copying server admin AdMob ID to the g_motd or something like that, then parsing that in OA and showing ad), but I don't think it will ever be necessary, because both Android dedicated servers are under-populated (and I think people will run more servers in the future).

2) In "Device configuration" (and sub-menus) you may add more infos (using a second line with smaller fonts?) to many of the options, to explain better what they do.... sometimes also mentiong the suggested value.
Standard Android controls do not support a second line with smaller fonts, and I won't write my own UI controls for that. I can add header/footer text for option lists, but they will make the lists smaller and more cluttered. You may suggest better descriptions for that options.

2.1) "Data installation location" may write down the path used in the two different cases. Also a question: if I change it, does it move the already downloaded files to the new location and deletes the old location?
No, it does not move anything, it will try to download data again. And you generally should not change it - by default it will install data to the /sdcard/Android/data/<app-name>/files, which will be cleared when you're uninstalling app, and the size of this dir will show up in system settings.

2.1.1) Another thing: Android (apps management) tells me the app is just 8 MB, it does not count the 400+ MB downloaded to the SD. Will they be automatically deleted if I would uninstall the game?
It should show 400Mb, when you go to the individual app settings (the screen with Uninstall button) - that feature is available in Android since Froyo.

3) In "Additional controls": I thought you said Accelerometer was not supported, instead I find this option here. And why is the "enable accelerometer" option there (in initial "Device configuration"), while the "gyroscope on" option is in the OA main menu and Controls menu? Maybe the two should be one next to the other?
Yes it's not supported, I've forgot to hide that option. If you enable it from that menu, accelerometer will send up/down/left/right keyboard events, if you ever need such thing. It's a left-over from the times when SDL did not have on-screen keys.

4) In "On screen keyboard", you may place "preview" screenshots of the various keyboard themes/size/size of images/transparency.
Won't likely to happen, that dialog is written in Java, and I hate Java.

5) In "on screen keyboard", "Cusomize on-screen keyboard layout" should show you your current layout before starting modifying it, then you should be allowed to choose "modify layout/back/restore default". Also after having modified the layout, I think it should ask "accept changes/discard changes".
I'll add that feature. The initial layout will not be shown, because it is configured inside OA code when running the game, not in SDL.

6) I suppose "Calibrate gyroscope" may tell "It seems your device doesn't have a gyroscope." or similar, if you don't have one. It may also warn there that gyroscope is much more accurate than accelerometer, but uses more battery (as you said in the app description... I don't have it, so I can't test).
I'll just hide that dialog if gyroscope is not available.

6.1) Isn't there a "calibrate accelerometer" option? Playing with accelerometer is quite difficult to me, because if I hold the device in normal position the character goes back... I suppose some kind of accelerometer calibration may be needed.
I'll remove all accelerometer-related options, so you'll never know it's supported, because playing with it is frustrating.

6.2) Maybe you may give the option to choose if to use the accelerometer/gyroscope to move the character (go forward/back/strafe left and right) or to aim (turn left and right, look up and down).
It will suck anyway.

7) Some settings, such as "Remap physical keys", should have a "reset do default" button. You may also tell that the game itself has got "setup"->"controls" menu to associate keys to controls.
I can add option to reset whole SDL config to defaults.

8 ) In "What kind of navigation keys does your device have?", what's the difference between "Arrows" and "touchscreen only"? I tried both and noticed nothing different. My device has got a physical Qwerty keyboard, with arrows keys.
I'll remove that option, it's only useful to configure trackball, and there are no devices with trackball since HTC Widfire, and it's 3 years old.

9) Once loaded the game, there is always an icon in the upper left corner. If clicked, it allows to type text, but I don't know what it does. While in-game, it allows to "say" (chat), but when not playing? Console commands maybe?  ???
If you enter "~" symbol, it will toggle console, then you can enter commands there as usual. I'll make it to toggle console without entering "~" key, to make users less confused. Or I can remove it altogether.

9.1) By the way, while pressing it in-game and so entering the text for to "say", maybe the screen may show "Chat:" or "Say:" to let users understand what are they supposed to type in the text field.
I'll try to make that screen to show the last chat/console messages, instead of "Enter your text here" message, I think it will be more useful (but also more confusing).

10) Is there a way to show the console, at least its output?
The "~" symbol in the text input box. I'll fix that.

11) How to select the gauntlet? The first time I played, I had the impression the weapon bar was touchable, and in that way I suppose one may have selected it. But in later tests, I've seen the weapon bar is not touchable, so how to select the gauntlet, unless binding it to some physical key?
You should be able to select it by touching the gauntlet icon in the weapon bar at the top of the screen (and any other weapon too), you need to press the weapon selection button to show it, or enable "always show weapons" in settings. How did you manage to break it?

12) I'm not good playing with the touchscreen. So I binded the up/down arrows of my qwerty keyboard to look up/look down (and fire to a button different than ctrl, that I don't have), and I play with the keyboard quite happily.  :) This way, I noticed that if I press the "t" button to start writing a chat text, the "say:" appears for an instant and immediately disappears, so I can't use it. This makes me suppose I would not be able to bind "say_team" to a key....  :-[
It's a bug, I'll fix it.

13) Entering the "demos" menu, the "back" and "play" buttons seem to do not work.
Play button works for me, but it cannot play that one demo I have. Back button does not work (does it work on PC?), but you can press Back hardware key on your device.

14) Is it possible to enable "cg_drawspeed" and "cg_drawfps"?
You can enable drawing FPS from the Video settings menu. To enable drawspeed, you'll have to use console.

15) You may consider using a DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Manual/Graphic_options#Weapon_bar]weapon bar (http://([b) of those that give an indication of how many ammos you have got. Just an idea, considering switching weapon is not so comfortable as when you have a mouse wheel.
I can change to style 1, with small bars at the bottom of weapon icons, if you think it will look better. Or maybe at the top? What do you think?

16) In the battery usage statistics screen of Android (I have Android 2.3.4), the line of OpenArena takes three or four times the height of any other program, with a lot of empty space. I have no idea about the reason, but it does not look good.
No idea either.

17) I can't use my "shift" physical button to "walk" with the touchscreen (while it works together with the physical WASD keys)... it's a little strange considering that the "c" physical button actually allows me to move crouched, also moving with the touchscreen. Maybe it's due the fact "c" is a standard button and "shift" is a special one? I don't know.
Most probably that. try to remap it to some other button.

17.1) Any way to crouch using the virtual keys? It is also used to go deep in water. I suppose one has to manually remap a virtual button, like the sixth, to the "c" key, right?
Nope, I did not implement crouch, because there are already way too many buttons on the screen. You can enable the sixth on-screen button, and bind Crouch to it.
Crouching is for cowards, campers and bots :D but I can add it, if you think it's essential for the game. Or maybe I should remove crouching at all from the game physics (but I don't want to touch that).

18) In the various "themes" for the virtual keys, there is no one that uses images or letters that refer to the actual effects of the virtual keys (e.g. a "J" or "up arrow" to jump, a "W" or "a stylized weapon or bullet" to change weapon, a "S" or a "table" for the score table...). Is this due to the fact one may remap those buttons and they may do different things?
Draw me some button images, and I'll include them into the next release. Images of current button themes, included in SDL (https://github.com/pelya/commandergenius/tree/sdl_android/project/themes)

Is this enough feedback for the first impressions?  :)
Yes, even a bit too much :) I've spent 40 minutes writing replies.

Pelya, anyway you deserve contratulations. It looks a very good porting.  :)
Nice job!  ;D
Thank you.

P.S.: Just a few of things more:
Oh no :D

19): If I enable virtual button 6, it is displayed on all game screens. Is this voluntary?
I've fixed that.

20) The "four ways" virtual stick is used for movement (like the WASD keys), but its sections do "light" if you press the physical keys that correspond to aiming (turn left/right and look up/down). This sounds a little strange. Is there a purpose for that?
I've fixed that. This should have happened only with legacy keyboard themes, and not happen when using Sun keyboard theme, am I correct?

21) I suppose some players may like a layout where you see two virtual joysticks. One for movement and the other one for aiming.
Just like the double tap on the movement one makes you jump, I suppose a double tap on the aiming one could make you fire. But I don't know how to deal with the fact some weapons need continue firing and some weapons need single shots...
Second on-screen joystick is not yet supported by SDL, I'll add support in the future, but that won't be soon.
You can enable firing by double-tap in OpenArena main menu, the option is called "tap to shoot". And I don't see a problem with continuous-firing weapons - you double-tap the screen and do not release your finger afterwards, so you can shoot while aiming.


Title: Re: Android port
Post by: Gig on March 06, 2013, 08:36:33 AM
2.1.1) Another thing: Android (apps management) tells me the app is just 8 MB, it does not count the 400+ MB downloaded to the SD. Will they be automatically deleted if I would uninstall the game?
It should show 400Mb, when you go to the individual app settings (the screen with Uninstall button) - that feature is available in Android since Froyo.
In my case (Android 2.3.4) it does show "Total 8,20 MB - Application 8,20 MB - Data 4,00 KB).

For other things, I cannot reply now, I really have to go. But I would suggest to do not completely remove crouching from the game: I suppose there could be some maps that may require it to reach secret places... and anyway can be useful while swimming, to go deeper.


Title: Re: Android port
Post by: Gig on March 06, 2013, 10:07:21 AM
Quote from: Pelya
At least at first times, one may have to come back to change those "device settings" quite often. This means you have to close the game and launch it again from your app drawer each time. If possible, it may be nice to recall that "device settings" menu from within the game, without closing it (from the SETTINGS menu of OA, maybe); if this is not possible (e.g. because one would need to restart the game anyway to appy some changes), you may however consider to place a button in OA main menu, that would automatically close OA and re-launch it, passing through the initial loading screen (and thus, giving the ability to access the "device settings" menu quickly enough).

That's part of SDL Java code (and I hate Java), it needs rewriting for a long time, so it won't happen anytime soon. I'm not a fan of closing-and-restarting idea.
D'oh! Well... it may have been useful, but patience.

Quote
2) In "Device configuration" (and sub-menus) you may add more infos (using a second line with smaller fonts?) to many of the options, to explain better what they do.... sometimes also mentiong the suggested value.
Standard Android controls do not support a second line with smaller fonts, and I won't write my own UI controls for that. I can add header/footer text for option lists, but they will make the lists smaller and more cluttered. You may suggest better descriptions for that options.
Those standard controls do not seem extremely comfortable for various resons, but I understand the second line itself isn't enough to create a whole GUI. Maybe one may made some tests with a footer text when having some spare time in the future... or thinking to better descriptions, in the future.

Quote
4) In "On screen keyboard", you may place "preview" screenshots of the various keyboard themes/size/size of images/transparency.
Won't likely to happen, that dialog is written in Java, and I hate Java.
D'oh!

Quote
5) In "on screen keyboard", "Cusomize on-screen keyboard layout" should show you your current layout before starting modifying it, then you should be allowed to choose "modify layout/back/restore default". Also after having modified the layout, I think it should ask "accept changes/discard changes".
I'll add that feature. The initial layout will not be shown, because it is configured inside OA code when running the game, not in SDL.
Good.

Quote
6.1) Isn't there a "calibrate accelerometer" option? Playing with accelerometer is quite difficult to me, because if I hold the device in normal position the character goes back... I suppose some kind of accelerometer calibration may be needed.
I'll remove all accelerometer-related options, so you'll never know it's supported, because playing with it is frustrating.
Without the ability to calibrate it, I can't give opinions about accelerometer responses... so I will believe to your words. :)

Quote
7) Some settings, such as "Remap physical keys", should have a "reset do default" button. You may also tell that the game itself has got "setup"->"controls" menu to associate keys to controls.
I can add option to reset whole SDL config to defaults.
This may be good. Of course, asking for a clear confirm.

Quote

9) Once loaded the game, there is always an icon in the upper left corner. If clicked, it allows to type text, but I don't know what it does. While in-game, it allows to "say" (chat), but when not playing? Console commands maybe?  ???
If you enter "~" symbol, it will toggle console, then you can enter commands there as usual. I'll make it to toggle console without entering "~" key, to make users less confused.
It may be good. Or the text may show "Type ~ to show/hide command console".

Quote
9.1) By the way, while pressing it in-game and so entering the text for to "say", maybe the screen may show "Chat:" or "Say:" to let users understand what are they supposed to type in the text field.
I'll try to make that screen to show the last chat/console messages, instead of "Enter your text here" message, I think it will be more useful (but also more confusing).
If possible, yes... if not, you may write something like "Type ~ to show command console, or type text to chat".

Quote
11) How to select the gauntlet? The first time I played, I had the impression the weapon bar was touchable, and in that way I suppose one may have selected it. But in later tests, I've seen the weapon bar is not touchable, so how to select the gauntlet, unless binding it to some physical key?
You should be able to select it by touching the gauntlet icon in the weapon bar at the top of the screen (and any other weapon too), you need to press the weapon selection button to show it, or enable "always show weapons" in settings. How did you manage to break it?
I don't know how, but it seems I somehow broke it. Maybe when modifying on-screen buttons positions? I don't know, maybe some button went too next to the weaponbar area?

Quote
13) Entering the "demos" menu, the "back" and "play" buttons seem to do not work.
Play button works for me, but it cannot play that one demo I have. Back button does not work (does it work on PC?), but you can press Back hardware key on your device.
On PC (tried on Windows), the BACK button works (don't you have a PC OpenArena installation? :) I think you should). Yes, the play button works also on Android, but that demo does not run: maybe it's too complicated, or has been recorded with a too different game logic. So I recorded a very short demo directly on Android, but it didn't play it either. I don't know if it is due to some error or because the touchscreen continuosly provides some input to the game (when playing a demo, pressing almost any key of the keyboard -e.g. any arrow- stops playback and brings you back to main menu)... and I haven't figured out how to scroll the console back and forth (usually it's PageUp/PageDown) to check if it shows any error.

Quote
15) You may consider using a DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Manual/Graphic_options#Weapon_bar]weapon bar (http://([b) of those that give an indication of how many ammos you have got. Just an idea, considering switching weapon is not so comfortable as when you have a mouse wheel.
I can change to style 1, with small bars at the bottom of weapon icons, if you think it will look better. Or maybe at the top? What do you think?
Not sure, usually (not with default weaponbarstyle, obviously), the indicators are below the weapons icons, but usually the weaponbar is in the lower part of the screen, while in your port it's on the upper part. So, I don't know.

Quote
16) In the battery usage statistics screen of Android (I have Android 2.3.4), the line of OpenArena takes three or four times the height of any other program, with a lot of empty space. I have no idea about the reason, but it does not look good.
No idea either.
D'oh!

Quote
17) I can't use my "shift" physical button to "walk" with the touchscreen (while it works together with the physical WASD keys)... it's a little strange considering that the "c" physical button actually allows me to move crouched, also moving with the touchscreen. Maybe it's due the fact "c" is a standard button and "shift" is a special one? I don't know.
Most probably that. try to remap it to some other button.
No, I remapped "run/walk" to the "v" key, but it does not work together with touchscreen movement... it works only with physical keys movement... so it looks like we can't silently walk with touchscreen.

Quote
18) In the various "themes" for the virtual keys, there is no one that uses images or letters that refer to the actual effects of the virtual keys (e.g. a "J" or "up arrow" to jump, a "W" or "a stylized weapon or bullet" to change weapon, a "S" or a "table" for the score table...). Is this due to the fact one may remap those buttons and they may do different things?
Draw me some button images, and I'll include them into the next release. Images of current button themes, included in SDL (https://github.com/pelya/commandergenius/tree/sdl_android/project/themes)
Not it the immediate future, sorry.

Quote
20) The "four ways" virtual stick is used for movement (like the WASD keys), but its sections do "light" if you press the physical keys that correspond to aiming (turn left/right and look up/down). This sounds a little strange. Is there a purpose for that?
I've fixed that. This should have happened only with legacy keyboard themes, and not happen when using Sun keyboard theme, am I correct?
Yes, it seems "Sun" theme is not affected.

Quote
21) I suppose some players may like a layout where you see two virtual joysticks. One for movement and the other one for aiming.
Just like the double tap on the movement one makes you jump, I suppose a double tap on the aiming one could make you fire. But I don't know how to deal with the fact some weapons need continue firing and some weapons need single shots...
Second on-screen joystick is not yet supported by SDL, I'll add support in the future, but that won't be soon.
You can enable firing by double-tap in OpenArena main menu, the option is called "tap to shoot". And I don't see a problem with continuous-firing weapons - you double-tap the screen and do not release your finger afterwards, so you can shoot while aiming.
Okay, if it's SDL, it's SDL... We'll wait. :)


Title: Re: Android port
Post by: pelya on March 15, 2013, 08:22:48 AM
@Gig: I've fixed some bugs you've mentioned in the release 0.8.8.21, published last Sunday.

Currently I'm trying to enable VoIP voice chat (it crashes somewhere inside Android code, I'm fixing that). And I would like to hear your opinion.
Is voice chat needed at all? Should it be activated with some button, or using voice auto-detection?
I don't have another on-screen button to use (SDL has limit of 6 buttons, because I never needed more), also I don't know where to add it, the screen is already cluttered enough.
Voice auto-detection will just record everything, as long as the sound/noise level of microphone is higher than some margin, but you don't need to press any buttons, which is good. But you'll get high probability of recording random noises around you, and sending them to other players (and by random noises, I actually mean something like flushing :P ).
Maybe it should get activated with some cheesy gesture, like, shake your phone and talk? Shaking won't impact your aim, because gyroscope filters linear movements really well, at least on my device.
As you possibly know, every Android device has a microphone, so it's way easier to add than on PC, and it does not need any configuration.
When I'll implement it, I want to enable it by default for all users (because it seems to be an awesome feature), but that may result in users complaining, because suddenly, you've got your voice heard by everyone. So, should I do that?

The OA rating on Google Play slowly slipped from awesome 4.25 to 4.02 :( no 4.5 stars for me anymore.

Also, I've tried to publish it on recently opened Ouya store, but no luck.
Quote
Hello Sergii Pylypenko,

Unfortunately we can't yet distribute OpenArena (0.8.8.21) on OUYA.

Here is our team's feedback. Please consider it. We'd be thrilled if you resubmitted.
1. "U" button is used to select.  Per OUYA interface guidelines, "O" is the preferred button to select.
 https://devs.ouya.tv/developers/docs/interface-guidelines
2. In "Settings" under "Controls" PC controls are listed.
3. Initial load time exceeds 25 min
4. System button does not pause game or return ot Open Arena Menu

Our goal is to be the most developer-friendly gaming platform. If you have questions about our process or our feedback onn what you submitted, please feel free to reach out to us at app-reviews@OUYA.tv
So, my lazy coding effort was not enough :'( and it seems like I'll need an actual Ouya hardware to fix all those things, which won't happen anytime soon, so I'll postpone Ouya release until better times (there seem to be a lot of 3D shooters on Ouya anyway, published by big fat companies with heaps of money, so Ouya gamers will definitely not suffer if they won't find OA at their store).
Remapping buttons and adding Ouya-specific button names is easy, but it will require creating a separate package, because those changes will break compatibility to the previous Android release on Google Play, and I'll have to reset config files, and users hate that, and I hate creating separate platform-specific packages.
Initial load time is most probably the time needed to download .pk3 files. This can be solved by putting all .pk3 files inside the .apk file, so that the data will get downloaded by Ouya store, not by OpenArena. There are two possibilities - just extract those files to SD card (so we'll get 400Mb .apk + 400 Mb data files), or make OpenArena read .pk3 files from inside .apk file without extracting them - .apk file is just a zip archive (similar to .pk3), and OpenArena already can read data from inside zip archives, that will just add another layer of archiving. But anyway, it still requires some development effort.


Title: Re: Android port
Post by: Gig on March 16, 2013, 03:16:41 AM
Hi! I'm sorry my Android phone is out-of-order again, so I cannot test if you did more changes than those I can read in .21 changelog (what happened to .20? IIRC, my version was .19).

By the way, it seems you have a new competitor, now. While searching for OpenArena in the app store, I found this: QIII4A (https://play.google.com/store/apps/details?id=com.n0n3m4.QIII4A). Like Zeus Arena, it can be used to play Q3A if you own it, or else it automatically downloads OpenArena; but unlike Zeus Arena, it requires no payment.

About voice chat, you may want to make more easy to configure it than in standard OA, it may be good.

Istructions for using it in OA: (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Manual/Voice_chat
Note: that was one of the first pages I created in OA wiki, and maybe it may have some small defects (e.g. I'm very unsure about the required "rates" part -if that 25000 is a real requirement or not, and if it is clientside, serverside, or both-). I wrote it mostly by reading ioquake3 documentation (that may have been updated in these years) about their VoIP feature. I did some tests locally, years ago, and achieved to show the sound meter while I was talking... but I really never used it in-game. I have no idea if servers actually have it enabled, or how many players really use it. I suppose it is a feature that may be especially useful for clans... but "pro" players organized into clans would probably use the PC version (with the mouse) instead of the Android one (just a guessing!).

Of course, since you run the Android-OA servers, you can set "sv_voip 1" on them... but I would not enable VoIP by default on clients, for two reasons:
1) Privacy reasons (also consider your speaking may be even recorded)
2) Higher bandwidth usage

I don't know if you may use the sixth button for it. Maybe you may even add support for optional 7th and 8th buttons, that players may bind to what they prefer (especially if they have a tablet with a lot of space to touch).




Title: Re: Android port
Post by: pelya on March 16, 2013, 04:57:08 AM
I know about QIII4A port, it was started at the same time with my port, ± a month, by a Russian developer, mainly for a Russian community, but published to Google Play only recently  (well I also speak Russian, but I don't care about my local community, because, let's say it straight, they are the greatest noobs I've ever seen, they tend to buy cheapest devices, and then complain that nothing works).
It shares almost nothing with my port, probably because we developers are arrogant :P well it's also open-source, but my port is better  ;D well let's watch the ratings.
http://4pda.ru/forum/index.php?showtopic=417358 (http://4pda.ru/forum/index.php?showtopic=417358) - here's forum of that port, there is some drama inside, if you understand Russian ;)
The main difference of that port (aside from that they prefer Quake3 and shun OA), is that it supports mouse on rooted devices (and I don't care about rooted devices, I'm doing port usable by everyone, but the mouse is definitely a big advantage, so it's unfair). Also it has a crouch button, and in total 7 buttons+joystick on the screen (my port has 6+joystick). And the button config dialog seems to be better than mine.

There was no .20, because I've messed up it a bit, and quickly published .21, before anyone noticed.

I think I will make shake-to-talk the default option for VoIP, but make sensitivity high, so you will need a considerable long shake, and won't trigger it by accident. If I will disable it, I think most users will just miss it out, and will never find out about that feature (and of course I want everyone to know, because I am not just arrogant, as other developers, but also an attention whore  :D )


Title: Re: Android port
Post by: Gig on March 22, 2013, 07:20:09 AM
Decide yourself. I would not set VoIP enabled by default, but it's your decision. however, you may consider to add the option to enable or disable it also in the "first connection" screen.


Title: Re: Android port
Post by: pelya on March 22, 2013, 02:55:02 PM
Today my new server (http://www.hardkernel.com/renewal_2011/products/prdt_info.php?g_code=G135341370451) arrived, so I've set up another OA Android server, now Android players have three servers in total.
The new hardware is quite powerful, so I've also migrated the old "Hackberry DM" server there, so now it's running both server processes. CPU utilisation is around 70% max, and it can only drop when users connect, because there are 6 bots, and they eat CPU more than normal players. I've retired my old server (https://www.miniand.com/products/Hackberry%20A10%20Developer%20Board), it easily got 100% CPU usage with one server process and two bots, and froze for 1/3 second when reading or writing to SD card. I'll probably use it for it's original purpose - as a cheap Android TV-box.

The new server is running Elimination, and is accordingly named "CounterStrike", because I wanted to run a team server, but CTF seems too complicated for me (you still can vote for it, but it sohuld switch back to Elimination after a while). It has 4 bots, isn't that too much?
Players usually hate bots, but with our under-populated servers, it's better to play with bots than run on empty server, waiting for someone else to join. On the other hand, some players might want to team up against bots, then maybe 6 bots are better?

Decide yourself. I would not set VoIP enabled by default, but it's your decision. however, you may consider to add the option to enable or disable it also in the "first connection" screen.
I'm going to add that option to that screen, to settings, and to the main menu, so you cannot miss it.


Title: Re: Android port
Post by: unclebob on March 28, 2013, 09:45:34 AM
Hi

older ports of Quake have the Stereoscopic 3d code included.  Does yours?

I have tried to get the consul to work but alas to no avail.  Comes out as saying to other players.

Help much appriciated.

UB


Title: Re: Android port
Post by: pelya on March 28, 2013, 10:17:21 AM
No, my Android port does not include stereoscopic 3D, and I'm not planning to support that, because phones that support it (HTC Evo 3D and LG Optimus 3D) are not very popular, they've got a proprietary API to output 3D, also they are a bit outdated to run OpenArena.


Title: Re: Android port
Post by: Gig on March 29, 2013, 04:14:00 AM
OpenArena inherited "old-school" Anaglyph Stereoscopic 3D support from ioquake3, and it looks like the Android port still has it.
r_anaglyphmode <number> (different number uses different colors... 1 is for red-cyan glasses).
More infos: (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Manual/Graphic_options#Stereoscopic_view

The problem is that, due to a bug somewhere in OA, you don't see the crosshair.... (see also http://openarena.ws/board/index.php?topic=4446.msg45110#msg45110 for a possible -but yet untested- solution)

--------------------
@Pelya: I've re-installed the game on Android. Nice to see now you can easily interrupt initial download.  :)

Just a few of things I noticed:
1) Multiplayer mode: the "local" browser shows internet servers, too.
2) The multiplayer browser uses "space" to stop browsing... but touchscreen devices don't have the spacebar. You may add a "stop" button (or maybe showing the "jump" yellow button there?)? At the moment, there are only two servers, but maybe in the future they could be more, and thus the wait could be longer.
3) If I try to pull down the console from the menu (instead of from a match), it immeditalely closes.
4) Using the physical keyboard, "ALT-ed" and "SHIFT-ed" keys work only when I use the "input window" (I don't know its exact name... the one activated from the upper left corner icon). If I type directly (e.g. after pulling down the console), ALT and SHIFT are ignored.


Title: Re: Android port
Post by: GN--Gigabit on April 04, 2013, 02:07:51 PM
Started running an android client only server. Its pretty much the recommend config, but if anyone has suggestions I am open.

Access through the in game browser

GeezerNET.co.uk *FFA* - 5


Title: Re: Android port
Post by: pelya on April 04, 2013, 04:44:18 PM
Thank you. That recommended config is composed of the maps which I liked, and there's too little statistics of what other players would like to play, so it's pretty much up to you to experiment and find out what's better (and share what you will discover  :D ). The only thing I'm sure about is that gameplay on cellphone differs a lot from gameplay on PC.
Maybe you can try running some team-based game mode, for example Elimination against bots seems rather fun on the Counterstrike server. CTF or Overload maybe?
I can try to add some kind of poll to the loading screen in the future, asking players if they liked last played map, what do you think? Or maybe a button "Write message to server admin" (on the other hand, chat messages are saved to server log anyway).


Title: Re: Android port
Post by: GN--Gigabit on April 06, 2013, 07:38:55 AM
Changed the server a little bit, now running as CTF server with of cause CTF maps in rotation.

"GeezerNET.co.uk  *CTF* 5"


Title: Re: Android port
Post by: Gig on April 09, 2013, 01:27:37 AM
Pelya, a problem I noticed.
Considering that my device is a little old and that I don't get high framerates, I tried to use a different resolution (from "graphics" menu) to get some more fps.
The result was that the game took only the lower-left part of the screen, instead of adapting to full screen (although "fullscreen" option was enabled). Touchscreen inputs (including the virtual "mouse" pointer), instead, continued to work as if the game was using all the screen, making it quite difficult to change the option again, because to have the pointer click on a part of the screen, you had to touch a different part of it.

I suppose the best thing would be to allow to really adapt the screen to different resolutions. I don't know if that is easy or possible with the designing tools you are using. If that's not possible, you may consider removing the resolution options from the GUI at all.


Title: Re: Android port
Post by: GN--Gigabit on April 09, 2013, 08:45:23 AM
I also have the above problem on a Motorola Xoom.

Can keyboard and mouse play be enabled for gameplay?

Although the settings are there, for key bindings, it doesnt work. Mouse look only works if you hold down left click.


Title: Re: Android port
Post by: Gig on April 09, 2013, 10:10:29 AM
I think Pelya said he voluntarily kept mouse support out, because that requires a rooted phone and because that would give an unfair advantage against other Android players who use touchscreen controls.

Maybe he could include mouse support in the special version that is compabile with "standard" OA servers (renouncing to many Android version customizations, I suppose), if he wants. That version is not available directly on Google Play, but has to be installed as an APK -the link is in the app description in Google Play-. Note: I never tried it, I don't even know if you can have both versions installed at the same same!

However, physical qwerty keyboard actually works with my phone... although with some problems (ALT and SHIFT work only while displaying the "input window").


Title: Re: Android port
Post by: GN--Gigabit on April 09, 2013, 10:12:31 AM
Yeh I kinda forgot that OTG usb required root.

Cant install both version at the same time, one replaces the other.


Title: Re: Android port
Post by: pelya on April 09, 2013, 11:01:49 AM
@Gig
You cannot have multiple resolutions on Android, because 1 pixel on screen = 3 bytes in the video framebuffer, it does not scale up picture as PC monitor. I can implement something like off-screen rendering to the small-ish texture, then copy and stretch that texture to the video framebuffer, that may give some speed improvements, because framebuffer is filled just once. But it's too much work for too little gain, also you'll see big ugly pixels.
I guess I should remove the option to change resolution at all.

@GN--Gigabit
I've played on GeezerNET CTF server with 6 bots, it's okay on open map, but playing on oa_thornish, when everyone gathered at the center and started shooting, my FPS dropped to 1-2, then my poor Galaxy Note rebooted  :RIP:
So I suggest removing oa_thornish from the map rotation, or lowering number of bots. Also, would be nice to set g_teamAutoJoin to 1, so you won't need to press Back -> Join.

Neither version of my port supports mouse, the "PC-compatible" port will only allow you to connect to PC servers, nothing more.
If you want mouse support you may try installing this other port (https://play.google.com/store/apps/details?id=com.n0n3m4.QIII4A), it's not mine, but it supports mouse on rooted devices, you'll need to know the location of your mouse device though, like /dev/input/event3 or /dev/input/mouse0, depends on your kernel.


Title: Re: Android port
Post by: GN--Gigabit on April 09, 2013, 11:13:23 AM
Removed the map, kept bots the same as I think CTF realy needs 3 vs 3, to really play. Added the team auto join.

The server sees quite a few users, possibly because of the low ping to EU players.


Title: Re: Android port
Post by: Gig on April 10, 2013, 12:49:06 AM
Pelya, I think that allowing the "PC-compatible" version to co-exist on the same device of the "standard Android" version could be very nice. I think that having someone insterested in trying both versions could be a (relatively) probable scenery (however, I suppose that playing against PC users without mouse would be a losing game - But I haven't seen gyroscope aiming, so I can't tell for sure.).

Gigabit, a clarification: I said that the physical keyboard works on my phone, although with some problems (Pelya, any news about that?)... I forgot to mention that keyboard is integrated in the device, it's not a bluetooth keyboard. Considering you are using a Motorola Xoom, I imagine you are using a bluetooth keyboard, right?


Title: Re: Android port
Post by: GN--Gigabit on April 10, 2013, 03:01:30 AM
Yes bluetooth keyboard, but also tried using a usb keyboard.


Title: Re: Android port
Post by: pelya on May 07, 2013, 04:28:11 PM
I've made another update to OpenArena, and added voice chat support. Users need to enable it in the settings first, and then shake the phone during the game to send 3 seconds of voice, so I expect that traffic impact on the server will be low.
@GN--Gigabit
Please replace file pak7-android.pk3 on the server with the file I've attached (it's the only file that contains changes).
Voice chat is allowed on the server by default, if you want to disable it - add string "seta sv_voip 0" to the file ~/.openarena/baseoa/q3config_server.cfg (and not to any other config file, because it fails to set the value any other way, even through command line).
Also, HTTP download is broken on your server (or maybe it's missing Android-specific .pk3 files). Could you please disable or fix it? In one week only around half of all users will update OpenArena app through Google Play, so they will keep downloading file pak7-android.pk3, however it's small, and UDP downloader will handle that task fine.


Title: Re: Android port
Post by: GN--Gigabit on May 08, 2013, 03:15:21 AM
All done & fixed.


Title: Re: Android port
Post by: Gig on May 10, 2013, 10:23:06 AM
Pelya, I just updated to version 0.8.8.22.

It seems you made some changes to voip than its standard impementation, right?
It seems your cl_voip works as "0 = disabled", "1=enabled with shake to talk", "2=listen only".

I read you said it's disabled by default in program description. Console reports that cl_voip default value is 2. Seems good. But when I launched the game the first time, the GUI already showed "shake to talk" (and, IIRC, cl_voip was set to 1). Thus, in reality, players find it ENABLED by default, because for some reason it starts from a value different than the one considers cl_voip default value. Maybe a problem with the GUI, I don't know. I supose you should give it a look.
Note: I cannot completely exclude the case I previously changed it do to some tries and I don't remember about it anymore.

Another thing I would be curious... what if one would prefer to bind voice chat to a key (bind v +voiprecord) or to use the auto-record through volume level (cl_voipUseVAD), to avoid shaking the phone? Would they work?

About the console, now I see one enters console commands directly, without having to use ~ to pull console down before. The problem is that the console also automatically closes at the end of the command, so you don't see its response!


By the way, what do you think about the idea of allowing co-existence of "Android-only" and "Android-PC-compatible" versions on the same device?


Title: Re: Android port
Post by: pelya on May 10, 2013, 10:52:58 AM
It seems that when you're upgrading, it reads the value 1 from config file, because VoIP support was already there compiled-in in the previous version (but SDL audio input was not working of course). Dunno, should I publish another upgrade, that will remove user config file? I'll surely hear some complaints about that. Or swap the value meanings, making 1 listen-only?
It's possible to bind VoIP to a key, and it will work.
With console it's one way or another, but both ways are bad :( anyway, I don't want to touch it anymore, because it will be used by only a tiny fraction of the users.
Co-existence isn't very hard to do, just change the Android class name, but it will download all data files again into different dir. Should I do that?


Title: Re: Android port
Post by: Gig on May 10, 2013, 11:22:13 AM
It seems that when you're upgrading, it reads the value 1 from config file, because VoIP support was already there compiled-in in the previous version (but SDL audio input was not working of course). Dunno, should I publish another upgrade, that will remove user config file? I'll surely hear some complaints about that. Or swap the value meanings, making 1 listen-only?
It's possible to bind VoIP to a key, and it will work.
With console it's one way or another, but both ways are bad :( anyway, I don't want to touch it anymore, because it will be used by only a tiny fraction of the users.
Co-existence isn't very hard to do, just change the Android class name, but it will download all data files again into different dir. Should I do that?
I think it may be ok if you could make an update that would simply delete the cl_voip variable from users q3config.cfg file (ONCE ONLY), that would be re-created immediately after (at first launch), taking the correct default value this time (disabled or listen only). You may warn in changelog that users may have to choose VOIP mode again.
Of course you shold do some test to be sure you will not mess up users config.

About console, I have not time to think about it now... I must go!!

About the dual version, I would do it. Anyway, the pc compatible version is not on market, thus will be downloaded only by people who know what they are doing. Anyway, warning that data would be downloaded separately for each one of the two installations, if installing both, is just a few words of text to write.

The current not knowing that changing the data location (from your "external" menu) would cause re-download again and to do not free space from the old location is more dangerous, IMHO.


Title: Re: Android port
Post by: pelya on May 10, 2013, 05:57:50 PM
Quote
I think it may be ok if you could make an update that would simply delete the cl_voip variable from users q3config.cfg file (ONCE ONLY)
That's already too complicated.

Quote
About the dual version, I would do it.
Recompiled, here it is (http://sourceforge.net/projects/libsdl-android/files/OpenArena/OpenMisery-0.8.8.22.apk/download)


Title: Re: Android port
Post by: Gig on May 11, 2013, 03:22:49 AM
Quote
I think it may be ok if you could make an update that would simply delete the cl_voip variable from users q3config.cfg file (ONCE ONLY)
That's already too complicated.
Then just update the description, telling that for new installs, it's "listen only" by default, but if updating from a previous release, users may find it already "enabled", and may wish to disable it.
Quote
Quote
About the dual version, I would do it.
Recompiled, here it is (http://sourceforge.net/projects/libsdl-android/files/OpenArena/OpenMisery-0.8.8.22.apk/download)
Good. I will try it when I have some time. :) I have very little time in this period.
Advertise this new opportunuty in description. (Possibly, telling users that already had the old pc-compatible version installed what should they do now).

Another question. Does cl_voip 2 really set incoming only, or simply disables the "shake to talk" feature? I mean, if I bind a key for voice chat, or enable the VAD feature, will they send data also with cl_voip 2?


Title: Re: Android port
Post by: pelya on May 11, 2013, 04:23:26 AM
It just disables shake to talk, the key should work.


Title: Re: Android port
Post by: pelya on May 19, 2013, 10:13:01 AM
Google recently added a game support to their Google Play services, and I can integrate it into Android build of OpenArena. More info (https://developers.google.com/games/services/common/concepts/matches)

Pros: You can invite your friends or totally random players to some server right from OpenArena, they will receive a notification to their phone, and if you click it OA will start and auto-connect to that server. There are also leaderboards, achievements and pushing savegames to the cloud, however those features aren't of much use for OA (proper clanwars cannot be represented with simple leaderboards).

Cons: you have to sell your soul create an account in Google+, which is hard not to do if you own Android device. Also, OA will look a bit more like Farmville with all that social stuff  ::)

There is also a "realtime multiplayer" feature, which as I understand is like your game network stream pushed through Google Talk voice stream, also you've got to route network packets through that Java API, which is butt-ugly ;D but you don't need to worry about NAT, it will perform UDP punch-through automagically, or route data stream through Google servers, as far as I can tell. Anyway, that's too complicated to use, and even if I'll integrate that, I expect stellar-high pings. And it is not available on PC, it's Android/iOs/webbrowser only.
Also, I am currently busy with my job, so I won't be able to develop OA for at least two months :(

So, what do you think?


Title: Re: Android port
Post by: Gig on May 20, 2013, 12:01:49 AM
I do not like "social networks" in general, because I like my privacy (a thing that new generations do not care about, or at least so seems).
I have a google account, but I try avoiding clicking on anything related to "google+" (too bad recently everything seems related to google+... I even stopped giving "stars" to Google Play Apps due to the fact now they are connected to g+).

Some features could be nice... however I'm quite cautious about these "social" things. Of course, this is only my humble opinion.


Title: Re: Android port
Post by: pelya on May 20, 2013, 02:33:52 AM
Well okay, less work for me.

Edit: Some statistics from the Play Store. It seems like active installs got stuck at 3900, and won't go further :( so, as of now, the development of this port is finished. I'll add an OA community map pack, when it will be released, and maybe I'll add an option to switch between Android and PC server lists, because currently it's two separate releases.

(http://i256.photobucket.com/albums/hh163/_pelya/OpenArena/screenie3_zps41178704.png)


Title: Re: Android port
Post by: Gig on June 10, 2013, 02:03:13 AM
Well, almost 4000 active installs after a relatively short time for an indie game is not so bad, IMHO. I would not give up.  :)

I still hope you may fix some of the small issues we previously talked about (e.g. some physical keys working only when you open the input window)...

And about the way the console works (now it automatically opens, but also automatically closes after an input -this is a problem to read console answers-)... what about adding an option in the SDL menu to allow people to choose the way they prefer (manually closing and opening it if they prefer)?


Title: Re: Android port
Post by: madnax2069 on July 02, 2013, 10:51:12 AM
I run the openmisery.apk on my OUYA.  Being that this version plays against PC players. Would it be possible to enable mouse for gameplay instead of just navigating the menus. The OUYA controller works great but not against PC players using a keyboard and mouse.

I was sort of bummed out when I hooked up a keyboard and mouse up to my ouya only to find out you could not use the mouse to look around.


Title: Re: Android port
Post by: pelya on July 02, 2013, 11:54:48 AM
Ouya does not have proper mouse support - once your mouse cursor reaches screen edge, the game will not receive any more mouse events, and it's not allowed to move cursor to the center of the screen, as PC does. This is limitation of Android itself, so I cannot really do much about that.
There is another Quake3 engine port (https://play.google.com/store/apps/details?id=com.n0n3m4.QIII4A), by different developer, which uses root access to read raw mouse events, so you can play Quake with mouse on your Android device (and you may need to reboot your device afterwards).

I was really hoping that Ouya makers will add some extra info to the input events, with relative mouse movement or raw coordinates of your finger on touchpad, that would make it possible to at least use touchpad for aiming, pretty much as if you were playing Quake3 on notebook. I've even created a special app that will log all input events happening on your Ouya (https://github.com/pelya/AndroidInputEventsLogger/blob/master/InputEventsLogger.apk?raw=true). Last time I've checked that a month ago, maybe they added those extra coordinates since then - you may try to install that app on your Ouya, move mouse cursor around screen using touchpad and mouse, and copy here your adb logcat output (as you may have guessed already, I don't own Ouya).


Title: Re: Android port
Post by: madnax2069 on July 03, 2013, 03:42:29 PM
Ouya does not have proper mouse support - once your mouse cursor reaches screen edge, the game will not receive any more mouse events, and it's not allowed to move cursor to the center of the screen, as PC does. This is limitation of Android itself, so I cannot really do much about that.
There is another Quake3 engine port (https://play.google.com/store/apps/details?id=com.n0n3m4.QIII4A), by different developer, which uses root access to read raw mouse events, so you can play Quake with mouse on your Android device (and you may need to reboot your device afterwards).

I was really hoping that Ouya makers will add some extra info to the input events, with relative mouse movement or raw coordinates of your finger on touchpad, that would make it possible to at least use touchpad for aiming, pretty much as if you were playing Quake3 on notebook. I've even created a special app that will log all input events happening on your Ouya (https://github.com/pelya/AndroidInputEventsLogger/blob/master/InputEventsLogger.apk?raw=true). Last time I've checked that a month ago, maybe they added those extra coordinates since then - you may try to install that app on your Ouya, move mouse cursor around screen using touchpad and mouse, and copy here your adb logcat output (as you may have guessed already, I don't own Ouya).

It might be better if you was to explain it then I would about how its not properly implemented.  The person I'm talking to is named Piers http://forums.ouya.tv/profile/27/Piers (you shoukd join that forum and send him a message about it) he is apart of team OUYA and can communicate with the engineering team to possibly fix the issue so where it can fully support the extra coordinates, so people could implement proper mouse support.


Title: Re: Android port
Post by: shinkamui on September 17, 2013, 01:17:16 PM
looks like im late to the party.  I follow and use a LOT of your ports pelya.  This is your masterpiece.  Plays really well especially on my shield.  I hope you revisit it from time to time.  Despite what the others say, adding the play features would be a plus.  Especially for matchmaking, and if you could get the peer to peer working, that would be a bonus too.  I like the 3rd person view, but the character head is in the way, would be pretty cool if you could offset the character position so its an over the shoulder view instead of shooting through the head.  If thats doable via the console, someone drop me a hint.  Anyway, BIG fan, wanted to register to say just that if nothing else.  keep up the excellent work. 


Title: Re: Android port
Post by: pelya on September 17, 2013, 02:13:26 PM
You can change camera distance from settings. I'll move it to the shoulder, and add another option to settings.
I'll probably release it when OA community map pack will be released, because those maps are heavenly good and I want to include them to my server, I hope you won't mind 70Mb download.

Google+ is too complicated for me, also the example project provided by Google refused to work, so I won't likely to do it.
There are too little players anyway on Android, and the difference in device quality is too big - devices produced in 2013 can give you stable 60 FPS, devices of 2011 - 20 FPS if you are lucky, so any serious clan wars will use PC of course. We can safely bet on the progress though - a gigabyte of RAM is the minimum today, while two years ago 512 Mb was norm, this matters more for UfoAI than OpenArena though (and I should update UfoAI sometime, because I'm their semi-official and only Android developer, they probably forgot me already).


Title: Re: Android port
Post by: Gig on September 18, 2013, 12:37:50 AM
Pelya, do you think the next version will bring some improvement about typing? E.g. the ability to choose between the two ways for typing text in the console (the one that automatically open/closes it, and the previous one)?


Title: Re: Android port
Post by: pelya on September 18, 2013, 03:57:32 AM
If you have QWERTY keyboard plugged, you can invoke console directly using tilde key, it will not bring up  Android input window, the fix is already in Git. If you're not, you only can use that Android input window.


Title: Re: Android port
Post by: Gig on September 18, 2013, 04:07:49 AM
If you have QWERTY keyboard plugged, you can invoke console directly using tilde key, it will not bring up  Android input window, the fix is already in Git. If you're not, you only can use that Android input window.
Tilde key requires "alt" on my phone... and if I recall correctly, "alt" does not work in Android-OA...
However, that thing of the console that auto-closes is not so comfortable, if you have to check its output...


Title: Re: Android port
Post by: pelya on September 18, 2013, 04:49:37 AM
This is also fixed, also you may bind another key to showconsole command.


Title: Re: Android port
Post by: pelya on September 22, 2013, 05:19:07 AM
I've pubished another update, to sync with Ouya release.

Owner of Cool Mediatech Open Server, please update .pk3 files on your server (just re-download dedicated server package). Thank you in advance.


Title: Re: Android port
Post by: Gig on September 23, 2013, 01:50:54 AM
Hi Pelya!
It was some time I did not launch the game on Android... and I did not do it before installing the update.
But I have the impression that now OA runs even slower than before on my phone. Is it possible that this update changed something in renderer or something that may have lowered performances, or maybe it's just my phone that has become slower due to some other reason?

Uhm... probably, it's just my old device...


Title: Re: Android port
Post by: pelya on September 23, 2013, 02:44:15 AM
It's quite ppssible, I've added several checks for aOuya to the code, they are mostly in GUI part.
If you compare to OA two versions ago, there is accelerometer added, which sends a stream of events OA must process, that can impact performance considerably.


Title: Re: Android port
Post by: Gig on September 23, 2013, 05:05:40 AM
It's quite ppssible, I've added several checks for aOuya to the code, they are mostly in GUI part.
If you compare to OA two versions ago, there is accelerometer added, which sends a stream of events OA must process, that can impact performance considerably.
What is the accelerometer used for, considering you don't use it for aiming? Is there an option to disable it, to check how much it does affect performances?


Title: Re: Android port
Post by: pelya on September 23, 2013, 06:06:09 AM
It's used for VoIP 'shake to talk'. I'm not sure if you can disable it, I'll look at the code later.


Title: Re: Android port
Post by: Gig on November 13, 2013, 03:26:21 AM
Hi! Can I ask you if it may be possible to add another aiming style? I'd like something mid-way between "tap to shoot" and "single-touch shooting" (from the second one, the thing of firing to the point you are touching).
I mean, keeping the usual back-from-the-shoulders view from "tap to shoot mode", but the game should automatically move my aim to the point I touch, starting to shoot following the place I'm touching (when I double tap). In other words, like "one touch shooting" but keeping a more "fixed" camera angle, and requiring "double touch" to start shooting.

Do you think a such thing would be possible/relatively easy to implement?


Title: Re: Android port
Post by: pelya on November 13, 2013, 06:50:09 AM
I'll add that new aiming mode in the next release. I'm not sure about double-tap, I think it will be clumsy, so I'll probably add two modes, with and without it.
But I don't know when I'll update it, the installs number keep shrinking (3732 active/36000 total installs), and I'm working on some other (https://play.google.com/store/apps/details?id=x.org.server) stuff (https://play.google.com/store/apps/details?id=org.gimp.inkscape).


Title: Re: Android port
Post by: Gig on November 13, 2013, 07:30:56 AM
I suppose that making the game more comfortable to control may help keeping people who try the game continue using it. Releasing an update may remember people that they have the game on their device.

Maybe you may insert the new mode together with the update that will include OACMP...

By the way, about Google Play description about "single-touch shooting", maybe you may modify it to "single-touch shooting mode allows for faster aiming, but harder to master - touch next to screen borders to look around, touch anywhere else to shoot at there; watch the video for instructions." Just an idea.

PS: Isn't the current "tap to shoot" a "double tap"? I was thinking to a feeling similar to that one, to start shooting (but shooting at where your finger is)... Although it's not technically a "double tap", it's still okay, I can guess...


Title: Re: Android port
Post by: Gig on November 14, 2013, 03:26:16 AM
Hey Pelya... what do you know about Android terms of use for apps that download files from the web? I contacted the author of "DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/Ports_and_markets#Android_-_Zeus_Arena]Zeus Arena (http://([b)" app (one of those that allow to play Q3A if you own it, or else to automatically download OA), that days ago disappeared from Google Play (but its source code is still available).
He answered to me, saying that Google removed it because it seems that apps downloading files from the web are not allowed in Google Play. And that he should fix that problem in the future, but at the moment he's too busy with real life.

Pelya, considering many apps from yours download files at first launch, do you know something about this rule?


Title: Re: Android port
Post by: pelya on November 14, 2013, 04:10:16 AM
That sounds like nonsense to me. There is a rule that any game with online play shall be marked as medium or high maturity, but downloading something from internet was always allowed, and there are very many games doing this. The alternative is putting everything into .apk file, which will fail to install on Android 2.X devices, or using Google Play file downloader feature, which allows you to download two files up to 2Gb each, but does not allow to remove them afterwards, so if you'll download zipfile with data and unpack it you'll be wasting space.


Title: Re: Android port
Post by: Gig on November 14, 2013, 08:30:05 AM
I found some pages about Google Play policies:
http://developer.android.com/distribute/googleplay/publish/preparing.html
http://play.google.com/intl/en/about/developer-content-policy.html
In the second one, I found this line "An app downloaded from Google Play may not modify, replace or update its own APK binary code using any method other than Google Play's update mechanism." and this one "Apps must not create unpredictable network usage that has an adverse impact on a user's service charges or an Authorized Carrier's network.". Maybe it was just that he did not explain clearly enough in app description that it would have downloaded a lot of stuff, like your app does? But I thought that downloading OA was an user choice, in Zeus Arena...

Is this the "google play file downloader feature" you mentioned? http://developer.android.com/google/play/expansion-files.html

A few other links:
Google Play legal information: http://play.google.com/intl/it/about/play-terms.html
App Install Location: http://developer.android.com/guide/topics/data/install-location.html


Well... it's still a mystery for me...

I hope Android OA will not encounter such problems...


Title: Re: Android port
Post by: pelya on November 14, 2013, 08:50:11 AM
Yes, that's right pages. Clause about updating APK code appeared after Facebook updated their app bypassing Google Play, I think it's not applicable to OA, because downloading VM is not changing .apk file.
Second clause is to ban DDOS bots and other malicious stuff.


Title: Re: Android port
Post by: Gig on November 17, 2013, 03:54:53 AM
Another thing about Android OA... did you check what happens if you run a server (in dedicated mode or not, from the complete OA Android app or from the Android-OA dedicated server binaries.... by the way, for which OS is that dedicated server package for?) but you have the option for connecting to PCs active?
I can guess that android-oa has got some extra .pk3 files than PC version, and we have to be sure that PC users will not autodownload those extra .pk3 due to erroneusly connecting to an Android server. So, we have to be sure that an Android server will not be shown to PC users, even if it had the variable to search for PC servers enabled (I can guess that should be a client-side only variable, but I don't know)...

I can guess that checking this should have a relatively high priority...  :)


Title: Re: Android port
Post by: Suicizer on November 17, 2013, 08:04:19 AM
If PC versions would be able to connect to Android servers and still would be able to run (as a miracle), then they would kick their asses...


Title: Re: Android port
Post by: pelya on November 17, 2013, 08:09:37 AM
PC clients will never see Android servers, because of different server ID string.
Server package has executables for Windows and Linux. I can also give you Linux arhmf executable, if you have any hardware to run it (no it won't run on RasPI).


Title: Re: Android port
Post by: Gig on January 22, 2014, 10:49:01 AM
Pelya, I just tested the two new aiming styles added with version .24.
In firstperson mode, I do really have major problems firing. Shots are not where I tap, nor where the crosshair is shown. Please check that.

In thirdperson mode, they behave better.  :) But I find the effect of the view changing immediately (in 1 frame) when you tap on a different part of the screen is confusing. Couldn't that rotate the character instead of the screen (or the player first, and then the screen smoothly)?

It also happens that I disable third-person view and it continues to work in thirperson view (then, if I restart the arena, it correctly displays in firstperson)

Question: the SDL framework still does not allow to have two on-screen joysticks?


Title: Re: Android port
Post by: pelya on January 22, 2014, 11:35:46 AM
SDL does allow two on-screen joysticks now, but do you really want that? Swiping is much more precise IMO.
To check how two on-screen joysticks work, you can install a game called Critical Strike from Google Play, and enable it inside Settings -> Controls -> Second Aim.

I'll fix new aiming modes with first-person camera, I've only checked third-person when I've added them.

I can only rotate screen smoothly in "aim under finger" mode, because the crosshair is fixed in the center of the screen, so in "shoot under finger" mode you need to rotate camera instantly, to be able to shoot where you tap.

I can also implement something like "half-floating crosshair", with crosshair detached from center, and camera following crosshair smoothly until it's in center of the screen, but this aiming mode will not work with PC servers and mods, because crosshair must be fixed at the center of the screen in any QVM, which does not contain Android modifications.

Currently, 4 of 5 aiming modes work well with PC servers, the only mode that does not work is "floating crosshair".

As usual, any modification brings a heap of broken things and incompatibilities, and I'll need to update it anyway, when re-re-re-release of OACMP Vol1 will be available. Fixing things is much easier on Android though - you just push new version onto unsuspecting users, and they have no choice to downgrade, hehe (I'm providing old version via my SF.net project though, so downgrading is still possible).

BTW how do you like new over-shoulder camera?


Title: Re: Android port
Post by: Gig on January 22, 2014, 12:01:19 PM
My initial idea for the new aiming style was to have crosshair control similar to old "one tap shooting" (I can guess now it has been renamed to "floating crosshair", maybe?), but requiring a double-tap to start shooting. In other words, controlling aiming after you already started shooting seem good enough, is it possible to keep the same feeling while aiming without shooting?

For the new camera, at first it reminded me "DBZ Budokai Tenkaichi 3" ^_^, rotated from the character... I have to test it more, but it does not seem bad at first.  :)


Title: Re: Android port
Post by: pelya on January 22, 2014, 12:06:26 PM
Oh, okay, what you're describing would be much easier to implement, but I of course interpreted it in my own way  ::)


Title: Re: Android port
Post by: Gig on January 27, 2014, 10:41:16 AM
Pelya, I just realized that fist person aiming is screwed up also with classic "shoot button" mode. Firstperson is almost impossible to play at the moment...


Title: Re: Android port
Post by: pelya on January 27, 2014, 12:26:58 PM
I've already fixed that, now waiting for OACMPv1ver4 to release everything together.
Also, I'm trying to replace ioq3 renderer with OA renderer, if I succeed - expect FPS drop :p

Edit: I've managed to compile OA renderer, and it works, but since there are no shaders available in GLES 1.1, bloom does not work, and flares do not work because I cannot read values from depth buffer, so the result looks identical to the old ioq3 GL1 renderer.
And I won't ever enable GLES 2, because all texture functions do not work - you have to use shaders exclusively instead of texture units, and even GL2 renderer still uses texture units.

Do you still want twin-joysticks touchscreen control? Did you try Critical Strike game to test it?


Title: Re: Android port
Post by: Gig on January 31, 2014, 04:48:01 AM
Pelya, a question: after I pull down the console (~), how to confirm a command from the virtual keyboard?
I type for example "/g_gametype" and then I tap "enter"/"ok"/"next" (depending from the virtual keyboard in use)... then it does report the text I wrote to the console, but it does not "confirm" it.
If I use the phone with the physical keyboard, I can press the physical "enter" key to confirm a command... but when using the virtual keyboard, I don't know how to confirm any command...

I noticed that, when using this virtual keyboard (https://play.google.com/store/apps/details?id=org.pocketworkstation.pckeyboard) in OA, the "enter" key, instead of showing the classic "enter" symbol (which is shown when I'm writing an sms, for example), shows the "next" text. Strange...


PS: will next version delete the pk3 of oacmp volume 1 v3 before downloading oacmp volume 1 v4, to save storage space on users' devices?

PPS: What about the aiming mode I was hoping for?  :)


Title: Re: Android port
Post by: pelya on January 31, 2014, 05:21:47 AM
You do not need ~ key - press button at upper-left and enter the command (first press Back to show menu, and prepend / while playing the game, you don't need that while in main menu) and it will get executed in console.
I'll try to fix that bug anyway, and delete v3 on upgrade.
I've added smooth camera rotation to 'touch to aim' mode, but not to 'touch to shoot', because it's more complicated. Now it feels weirder, because I've used for swiping, and that camera rotaton often swipes in the opposite direction than my finger.


Title: Re: Android port
Post by: pelya on February 03, 2014, 06:03:50 PM
I've published new Android release, with OACMPv3 for now, which should fix first-person view and mods, however I failed to fix a bug with Enter key in console.


Title: Re: Android port
Post by: Gig on February 04, 2014, 02:13:56 AM
Good. I have to try the updated version...  those firstperson bugs were really "major", and waiting for another week would have been worse.  :)


Title: Re: Android port
Post by: jastolze on February 20, 2014, 10:50:13 AM
Hey, I just wanted you to know that I love this port. So far, it's the only port that recognizes both analog sticks on my Nvidia Shield. I have a couple of suggestions, though:

1. Can you fix the console to where it has console commands working? Right now, after I load a map, when I type in a command, (i.e:  /give all) it just makes the player say it on chat, and does not apply the cheat. What's weird is, commands work before loading a map, (so I can type devmap) but not afterwards. Maybe you could look into this?

2. On the Nvidia Shield, the only buttons it doesn't work with are the directional pads. I'm not sure if you can fix this without actually owning a Shield, but that's 4 more buttons that could be available. Also, on the Shield, there are 2 R and L buttons, but both L buttons do the same (in my case jump) and R buttons (fire). I'm not sure if you can change how it reads the buttons, but if you could that would be amazing!

If you even get one of these working, that would be cool. Thanks for any help!


Title: Re: Android port
Post by: Gig on February 20, 2014, 11:24:40 AM
1. Can you fix the console to where it has console commands working? Right now, after I load a map, when I type in a command, (i.e:  /give all) it just makes the player say it on chat, and does not apply the cheat. What's weird is, commands work before loading a map, (so I can type devmap) but not afterwards. Maybe you could look into this?
IIRC, currently, to enter console commands from the game, you have to open the "DO NOT LINK[/b]) h t t p s : / / openarena . wikia . com/wiki/ESC_menu]ESC menu (http://([b)" first (on standard Android phones, by tapping the "back" button... I don't know on the Shield).

From Play Store description:
Quote
You can enter console commands using button at upper-left, you need to be inside game menu, and start command with / symbol.

More, entering ~ allows to drop down the console, but in that case I'm not able to enter the final "enter" at the end of a command, unless using the physical keyboard of my device (I think Pelya tried to fix this some weeks ago, but did not succed).


Title: Re: Android port
Post by: jastolze on February 20, 2014, 11:32:28 AM
Maybe Pelya could have the port use the android keyboard. By Long pressing on the console, an OSK could appear. Right now, that's not implemented. It should be fairly easy, too.


Title: Re: Android port
Post by: pelya on February 20, 2014, 12:35:43 PM
Nah, that's not easy, because the input handling code is already messed up, and I don't want to break it.
I'll fix the command with / symbol treated as chat text in game, it's fairly easy.


Title: Re: Android port
Post by: jastolze on February 21, 2014, 01:21:03 PM
Oh, that sounds good. :)

Also, is there a way I can run Open arena with a command line option? I'm using another mod called Reaction Quake 3, and I wanted to make it easier by starting the cmd file off with "-set fs_game RQ3 +devmap MAP_NAME"

But, in order to do that, do I need to create a file with those parameters in it? If so, what should the file name and extension look like, and where should I place it?

Thanks!


Title: Re: Android port
Post by: Gig on November 13, 2014, 01:45:15 AM
Hi Pelya, how are you?
It happened again that the "change weapon" on-screen button does not function anymore for me. I have no idea the reason. The icon changes when I tap it, but nothing happens.
I tried "change device configuration" -> "Reset config to defaults", but that didn't fix the problem. Any idea?

As a temporary workaround, I set /cg_alwaysweaponbar 1 (then tapping directly on weapon bar to change weapons).


Oh, that sounds good. :)

Also, is there a way I can run Open arena with a command line option? I'm using another mod called Reaction Quake 3, and I wanted to make it easier by starting the cmd file off with "-set fs_game RQ3 +devmap MAP_NAME"

But, in order to do that, do I need to create a file with those parameters in it? If so, what should the file name and extension look like, and where should I place it?

Thanks!
I don't know... maybe something like this may work? http://lifehacker.com/quickterminal-creates-command-line-shortcuts-1028944422 But I haven't tired it... and I'm not sure what's the command line to start OpenArena from console on Android...


Title: Re: Android port
Post by: pelya on November 13, 2014, 04:14:55 PM
Gig, you probably have this button reassigned in OpenArena config file, it is not cleared when you clear SDL settings, you can open file manager and delete directory Android/data/ws.openarena.sdl/files/.openarena

Jastolze, tap 'change device config' button when app starts, select 'Install location' then 'Custom', press OK, and there will be command line string to edit.


Title: Re: Android port
Post by: nrz on November 22, 2014, 01:24:22 AM
Hello, I wonder how I can mod server settings like seta sv_fps for an android server started from an android phone. Thanks a lot. Appreciate your work.

nrz


Title: Re: Android port
Post by: pelya on November 22, 2014, 05:44:18 AM
Start server, press Back to go to menu, press button in upper-left, then type
seta sv_fps ...


Title: Re: Android port
Post by: Gig on January 20, 2015, 10:39:58 AM
Gig, you probably have this button reassigned in OpenArena config file, it is not cleared when you clear SDL settings, you can open file manager and delete directory Android/data/ws.openarena.sdl/files/.openarena
Uhm... I also have the same problem "switch weapon on-screen button" also in a new device. Game just installed, the button doesn't work (I see the yellow button changing shape when I touch it, but nothing happens).
I tried deleting /"storage/extSdCard/Android/data/ws.openarena.sdl/files/.openarena" (hidden) folder, but still that button does not do anything.
SDL "Remap onscreen controls" tells me "Button 1 - Change weapon" sends "SLASH". In-game, Settings -> Control -> Shoot says "next weapon / or ]", "prev weapon [ or MWHEELUP]".
Any idea?

By the way, are game settings automatically backed up and restored by google's automatic backup (like how your new phone already connects to the same wifi networks of your old phone without asking for their password), maybe? Maybe this may explain the reason why a clean install already shows the problem... however not why deleting the .openarena folder does not fix them.

Some more things:
- I have 13,28 GB available on the SD Card, and SDL "Data installation location" screen says it has got 6219 MB free.
- Are you sure that also with latest SDL platform updates, you have no way to enable in-game brightness controls and resolution controls?
- "Gyroscope aiming" slowly rotates my view also if I keep the phone still.
- When I respawn, it is aiming up instead of in front of me...


Title: Re: Android port
Post by: pelya on January 20, 2015, 10:57:47 AM
That's strange, I'll check, maybe there is some bug.

SDL does not support changing screen brightness. As for video mode, decreasing it will result in video output to upper-left part of the screen, it will not stretch to the whole screen automatically.
You may use command "wm size 800x480" from ADB shell on your Android device to change screen resolution globally.


Title: Re: Android port
Post by: Gig on July 09, 2015, 02:03:19 AM
Pelya, did you investigate about those annoying problems?
- Change weapon button does not work. I have to always show weapon bar and touch direcly there.
- If I use thirdperson mode, every time I respawn or exit zoom mode, the game changes my view, looking at the zenith (vertically above me).
Is there some kind of test I can try to help you identifying the cause?

Gig from cell phone.


Title: Re: Android port
Post by: pelya on July 09, 2015, 02:58:51 AM
I've seen the second bug, did not fix that yet. Weapon switch button indeed does not work, no idea how did I miss that bug.
I'm currently rather slow with my open-source development, so maybe I'll release a fix next week.


Title: Re: Android port
Post by: Gig on July 11, 2015, 03:42:13 AM
That would be good, thank you. Also, maybe you may take the chance to stress more the note about how to enter console commands, in google play description (that's already there, but maybe it may be more stressed, e.g. with some asterisks, in case it is not possible to use italic or bold in app descriptions. Especially the part about being in menu first.)

Gig from phone.


Title: Re: Android port
Post by: pelya on July 13, 2015, 02:02:18 PM
I've published an update. Zoom button sometimes misbehaves, other bugs should be fixed.


Title: Re: Android port
Post by: Gig on July 14, 2015, 01:28:04 AM
Uhm... with this update, I see now the whole game is bundled with the app, which is now 437 MB on Play Store (before, it downloaded just a few MBs from Play store and then downloaded most pk3 files from whithin the app).
Why did you change this? Due to Play Store requirements?

So, my phone is downloading the whole game again... will it use the same path as before (sdcard/Android/data/ws.openarena.sdl/files), or data will be downloaded to a different place, doubling the space actually used?
Will this "big" download happen only once or every time you will post an update?



Title: Re: Android port
Post by: pelya on July 14, 2015, 02:21:43 AM
I did it because of user complaints, they like installing everything in one package, plus sourceforge servers aren't most reliable.

It uses the same place, amd this data is installed only once, then it's deleted so it won't take 2x space.


Title: Re: Android port
Post by: Gig on July 14, 2015, 04:51:46 AM
I did it because of user complaints, they like installing everything in one package, plus sourceforge servers aren't most reliable.

It uses the same place, amd this data is installed only once, then it's deleted so it won't take 2x space.
At first startup after the update, it looks like it downloaded something, but it was quite fast (maybe it just did some kind of MD5-like check on the files? Or maybe, looking at pak7-android.pk3 date/time, it downloaded that one.)...

"Aiming-up" and "change weapon button" problems seem fixed. Good!
I also like now there isn't the need to be in ESC menu, to enter console commands. Good!  :)

Thank you!  :)

PS: Is it possible this update included some "tech" enhancement which allowed the game to get (a few) more FPS? I have the feeling the game runs (a bit) smoother now, but maybe it's just an impression...


Title: Re: Android port
Post by: Gig on July 17, 2015, 08:34:14 AM
Have you ever noticed sometimes it happens the game does not get some buttons and requires you interrupt current tap before having the other button working again?

E.g. I'm running and press the jump button: it doesn't jump. I tap the button again, and still it doesn't jump. So I release movement thumb for a moment, and after that, jump button starts working again...


Title: Re: Android port
Post by: pelya on July 17, 2015, 09:36:06 AM
I've reproduced the bug, it's only happening with jump button, because double-tapping the joystick will make you jump, and the button stays pressed until you release joystick. I'll fix it.


Title: Re: Android port
Post by: pelya on July 17, 2015, 12:14:17 PM
Some time ago I was asked to add VR mode to OpenArena, with cardboard and stuff (https://www.google.com/get/cardboard/). Is anyone else interested in this?

OA already supports gamepad and gyroscope, which are prerequisites for VR, and some time ago the engine also supported stereoscopic rendering, until my Android changes  ::)


Title: Re: Android port
Post by: Gig on July 18, 2015, 04:17:17 AM
I've published an update. Zoom button sometimes misbehaves, other bugs should be fixed.
Yes, sometimes zoom goes up again, but I haven't understood when the bug occurs.

About virtual reality, may be interesting... although I have never tried the cardboard stuff. But how to play, with the phone on your head? You would look around moving your head, but how to shoot, change weapon, etc?
Not really a required feature, but you may use it to further enhance your programming skills...


Title: Re: Android port
Post by: pelya on July 18, 2015, 06:19:34 AM
yes, you look around, like it is now, with gyroscope, but you have separate picture for each eye. You play with ganepad, pretty much every VR game requires it.
Youtube app already supports 360° videos, you move your phone or swipe to look around. here's one video (https://youtu.be/ujYyE0lfSUk), hwlere's another one (https://youtu.be/K_J8k43gUhY)
I don't need to improve my programming skills, I need to balance my free time between all my projects  :)


Title: Re: Android port
Post by: Gig on July 21, 2015, 10:22:48 AM
About OA in VR, did you see this thread (http://openarena.ws/board/index.php?topic=5090.0)?


Title: Re: Android port
Post by: Gig on July 29, 2015, 09:46:15 AM
I've reproduced the bug, it's only happening with jump button, because double-tapping the joystick will make you jump, and the button stays pressed until you release joystick. I'll fix it.

Hi Pelya... this seems to be still happening...


Title: Re: Android port
Post by: pelya on July 29, 2015, 10:29:10 AM
Yes, because I still did not fix it. I'll do that probably this or next week.


Title: Re: Android port
Post by: Gig on July 31, 2015, 02:23:33 AM
Yes, because I still did not fix it. I'll do that probably this or next week.
Okay, thank you. I'll wait.  :)


Title: Re: Android port
Post by: Gig on August 08, 2015, 08:44:17 AM
Hi Pelya... I just did a try to set "dedicated 1" in the game, and it seems to work (after loading a map)... although I haven't checked yet whether another phone in the same wifi can actually find and connect to it.

At that point, all virtual button icons go away, included the one to enter commands... and if you touch where it is usually located, you can start typing text. But when you confirm the typing, it does not send the "enter" key.... so you can't actually execute any command and you have to forcely close the app from a task manager. Is it possible to fix it (showing "type text" virtual button and most important confirming commands, in dedicated mode), to allow usage of an android phone as a dedicated server?

I see in app description you link a dedicated server package, but considering it's a tar.gz instead of a .apk, I can guess it's to be execuded in Linux, not in Android, right?

As a further step, it would be also nice a way to run both a dedicated server and a client on the same phone, theoretically trying to get slightly better performances by diving server and client processes on two different processor cores...

Gig from cel phone.

PS: Today I saw cardboard 3d adapter in a store near my home... 15 euros for some cardboard!


Title: Re: Android port
Post by: pelya on August 15, 2015, 02:42:14 PM
Hi Gig. I've publiushed an update, which fixed Jump button not working.
Starting dedicated server from the game itself was never tested, so no surprise it's broken.
I can compile a dedicated server Android executable when I'll have some time, to be started from terminal, but I doubt anyone except you will use it, so it's low-priority task.

15 euros for cardboard VR adapter is stupid, you can download schematic from their site, print it on thick paper, then cut and fold (but you also need lenses, that's tricky): https://www.google.com/get/cardboard/get-cardboard/
More advanced VR helmets offer more comfort and adjustable lenses, but they at least are made from plastic.


Title: Re: Android port
Post by: Gig on August 17, 2015, 06:42:25 AM
Thank you.
I'm currently on holiday, and I will not have wifi for various days. I'm not downloading any app updates at the moment. Sure I will test when I will be able. :-)

About running Dedicated mode directly on Android, I agree it is a low priority thing.


Title: Re: Android port
Post by: Gig on August 20, 2015, 02:24:18 AM
Briefly got access to a wifi.
Quickly tested, jump button seems to work correctly.  :)

Unfortunately, now the whole game is re-downloaded completely (480 MB) at every minimal update (and google play does not resume interrupted downloads, but restarts them from the beginning).
Is it possible Google does not allow smarter updates?

Gig from mobile.


Title: Re: Android port
Post by: pelya on August 20, 2015, 02:57:00 AM
It should have downloaded only .apk file without data. I'll check.


Title: Re: Android port
Post by: Gig on August 30, 2015, 11:53:38 AM
Today I downloaded the update on another phone. This time, it has been a small download. Android mysteries...  :)


Title: Re: Android port
Post by: pelya on September 20, 2015, 03:34:46 PM
I've got back to OA Android development in the last week, I'm currently trying to add a stereo mode for Cardboard VR. I think I'll give it to you at the end of next week.
Unfortunately it looks like I cannot borrow the code from ioquake3 repo, as all they have now is Oculus compatibility, which does stereo rendering inside Oculus SDK, so you don't need to modify your rendering at all inside the game code.
With Cardboard, there's no such SDK, so I was trying to use Quake 3 built-in stereo rendering mode for blue/yellow glasses, and it kind of sucked, because their version of stereo is like this:
(https://encrypted-tbn1.gstatic.com/images?q=tbn:ANd9GcQRNmqu715cNX832-NOzUtfEkMviojdbHIF8ua0tILd2HownxgC)

It was implemented directly in renderer, and they messed up angles somewhere. So I moved stereo rendering code to VM, which will work domewhat slower.

I've borrowed Cardboard glasses from a co-worker, and when I've tried it out first I was thinking they'll suck, because I'm nearsighted in one eye, however the glasses surprisingly sucked not very much, I guess they got good lenses. Anyway it's still a gimmick, because my face was sweating in 5 minutes of wearing them, and they press on your face not very comfortably, also my phone would not fit because of the extended battery.
I still don't see how anyone can be shaken off balance by those 3D roller coaster videos - yes the magic is there, but not enough for 'total immersion' - you still sitting on your chair and don't feel that acceleration at all, it's just a moving picture.
Yes, rotating chair is pretty much a requirement for playing OpenArena in VR mode :)
If anyone asks for that, I can also compile PC build, if you can somehow strap your display to your head, but beware - VM foles are changed so it's not a pure client.

Now, back to fixing crosshair position not being 3D enough :)


Title: Re: Android port
Post by: Gig on September 21, 2015, 01:38:39 AM
Some fixes to stereoscopic feature may be useful also for base (PC) version of OA, maybe.
If you take a look to the "bugs" wiki page ((DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Bugs) there are some things you may like to take a look when you don't know what to do...  :)

About anaglyph stereoscopic view, surely current (0.8.8) bugs are some infos (framerate, speed..) in the upper right corner messed up, and the lack of crosshair (in PC version of OA, crosshair should not appear in thirdperson mode -for balancing reasons, I can guess-, but I suppose should appear in firstperson anaglyph).

Years ago, I asked tcpp (the guy who made "cascaded blur" bloom variant) to take a look into that, and he came with the code you can find here:
http://openarena.ws/board/index.php?topic=4446.msg45110#msg45110
I have no idea whether Fromhell or Sago updated OA sources with such stuff.

PS: When I read infos from ioquake3 readme file (years ago) about their stereoscopic feature (to write this pharagraph: (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Manual/Graphic_options#Stereoscopic_view), I read they also supported "OpenGL stereo rendering" (other than "classic" anaglyph mode), but it was reported as "untested" at the time. I don't know whether it has been actually tested or not nowadays (also, the link to ioquake3 readme file on github has changed since then, maybe now it may be this one https://github.com/ioquake/ioq3/blob/master/README.md -.md? What's .md? Markdown (https://en.wikipedia.org/wiki/Markdown)?-)

PPS: However, I have to admit It's unlikely I will buy a cardboard adapter soon, because I would also need to buy a bluetooth gamepad to be actually able to play, and I have very little time to actually play the game. Also, my phone is not of the latest generation (although better than the one I used up to past year), and using stereoscopic rendering would bring the framerate further down.


Title: Re: Android port
Post by: pelya on September 21, 2015, 02:26:39 AM
OpenGL stereo rendering is similar to anaglypth, except that instead of filtering specific colors, it's double-display setup kind of, and you select the for left/right eye 'display' to render onto. This requires some specific videocard and drivers.
Oculus makes things simpler, as far as I understood ioquake3 Oculus port - it has it's own OpenGL driver, which duplicates each drawing command to both 'displays', adding a stereo shift. I'm still not surr how it draws 2D stuff such as in-game menus, because those would get shifted too.
Having no crosshair makes the whole game kind of unplayable.
I'll check your other links, thanks.


Title: Re: Android port
Post by: Gig on September 21, 2015, 04:45:02 AM
Having no crosshair makes the whole game kind of unplayable.

That's the reason I asked someone to fix it for (anaglyph) stereoscopic mode.  :)

But in thirdperson, the crosshair is never shown since Q3A (not related to stereo mode). I'm not sure, but I can guess id software did that on purpose: Q3A is meant to be a first person shooter. Probably thirperson mode was there just for cool replays, followings, testing puporses (e.g. correctly sizing passages in your map) and mod makers. If a mod required thirdperson (Bid for Power?), its developers enabled thirperson by default and somehow enabled crosshair there. But if thirdperson would have been too good also in base game, players would have started using that instead of firstperson, changing the way the whole game was intended to be played.... so they did not include crosshair in thirperson to discourage people from playing in thirperson. In thirderperson, you have a wider lateral view, which may be unfair. This is just what I can guess, I don't know the "real" story about it!

PS: ioquake3 readme file (https://github.com/ioquake/ioq3/blob/master/README.md), when talking about stereoscopic-related features, links a wiki page, which I see has also got some notes about "3D Crosshair": http://wiki.ioquake3.org/Stereo_Rendering#3D_Crosshair. It should be noted that most of what's written in that page is dated back to 2008.


Title: Re: Android port
Post by: Gig on December 13, 2015, 11:50:30 AM
Hi Pelya... testing a new map (http://openarena.ws/board/index.php?topic=5200.0 third page), it has been noticed that Android version makes you spawn viewing at a different angle than expexted (at least in firstperson mode). I thought you fixed something similar in the past... could you please take a look to that?

Thank you in advance.


Title: Re: Android port
Post by: pelya on December 13, 2015, 12:44:10 PM
Yes, I fixed a part of this bug, but it still happens, mostly because of 3-rd person mode. If you set 1st person mode it should not happen.


Title: Re: Android port
Post by: Gig on December 13, 2015, 01:45:19 PM
Yes, I fixed a part of this bug, but it still happens, mostly because of 3-rd person mode. If you set 1st person mode it should not happen.

I do play in 1st and it happens. Haven't tried in 3rd today.

Also, sometimes it seems it also does the "swipe turn" when respawning (you respawn and immediately turn), but the main problem exists also with swipe turn disabled (you spawn already facing a wrong side). I use "tap to shoot" mode.


Title: Re: Android port
Post by: pelya on March 14, 2016, 06:39:58 AM
New release, with clunky Cardboard VR mode support, only works in 3-rd person view.
I also haven't fixed 'swipe turn' bug in 1-st person view yet. I hope I'll have a bit more time this week to fix this.

I am now thinking of adding Google Play Games integration, to make it possible to host public server on your phone. The same can be achieved with IPv6, but IPv6 is still not widely available unfortunately.
Also Google Play Games does not require Google+ login anymore.

There are currently 4281 active installations of OA on Android, and this number is not changing since 2013.
Most installs (1317) are from United States, and Android version does not even have a dedicated server in US.


Title: Re: Android port
Post by: Gig on March 14, 2016, 12:30:58 PM
I still don't have cardboard or bluetooth gamepad... however I downloaded the update... but I can't find the option to enable the carboard thing.... where is it?

Also, I have trouble connecting to android servers: invalid pk3 file...

About Google Play Games I have some thoughts, but it's too long to write them with the cell phone... I will say tomorrow.


Title: Re: Android port
Post by: pelya on March 14, 2016, 01:06:53 PM
I've restarted dedicated servers this morning, around 2pm, maybe that was the issue.

The cardboard thing is to the lower-right of the main menu screen, it looks like this:


Title: Re: Android port
Post by: Gig on March 14, 2016, 03:19:02 PM
Do you mean, instead of a classic "yellow dot" option, I should see a cardboard icon in the main screen? I can't find it.

Also, I still have those problems connecting with servers.

Baseoa/pak7-android.pk3 is dated July 2015... maybe Google Play did not update the application correctly?


Title: Re: Android port
Post by: Gig on March 15, 2016, 03:23:36 AM
Uhm... trying to install the update on a second phone... this one, for some unknown reason, had downloaded 437 MB from Google Play. About this, the two phones swapped their behaviors than what they did for August 2015 update (http://openarena.ws/board/index.php?topic=4577.msg52818#msg52818 - http://openarena.ws/board/index.php?topic=4577.msg52836#msg52836): I mean that back then, Phone1 did a big download and Phone2 did a small one... this time, Phone1 did a small download and Phone2 did a big one.  :-\
Now, on Phone2 I can see the "cardboard" option in the GUI (lower left corner of main screen), and it actually splits the screen in two if enabled. And can connect to servers.
Then, it's really Google Play which did NOT update correctly the game on Phone1. Who knows how many people are experiencing the same issue?


Spending some words about Google Play Games instead...
I have Google Play Games app installed, but I never used it. Launching it asks to create a Public Google+ Profile, which is something I'm not interested into... I don't like social networks a lot, I don't like other people know which game I am playing, when and how... As an example, I never played a Facebook game.
However, it is possible to close that screen ("cancel") without creating the Google+ Profile.... and then, it asks for which Google Account to use for Google Play Games. I can guess it should be safe enough, however for the moment I declined also this (by pushing "back" physical button, as there is no "cancel" button in this second screen), and the app exited.

Currently, the only app using Google Play Games I have installed is "Angry Birds Transformers"... each time I launch the game, the "Google Play - Create Google+ Public Profile" screen appears, and so i "Cancel" it... then the "Select account for Google Play Games" screen appears.... up to some months ago, it included a "cancel" button too, but after some update, now one has to use "back" physical button to continue to the game without logging in with any account (which is something I would define as "trying to trick the user" like Microsoft is making it unintuitive/difficult to avoid the "upgrade to Windows 10" when you are searching for updates in Windows 7). So, for the moment, the game is saved only on my device and not backed up to the cloud... however, I lost interest in the game (they are many months they do not add a new stage to play, they are still the same stages. And the game is stil buggy...), and will probably not reinstall it anyway when I will perform an hard reset on the phone. I don't know what would change in the game, by using either a standard Google Account or a Google+ Public Profile. I'm not even sure if accessing with a google account would actually keep my existing "local" progresses or I would have to start from scratch...

As you can see, at first impact Google Play Games is something which appears a little too much invasive for my taste. So, having "Create Google+ Public Profile/Select account for Google Play Games" pop up everytime one would launch OpenArena, would be really annoying. IMHO, it should be clear since the description that the "Google Play Games"  access would be optional, and it should show its popups only if the user enables an option for it in game settings, not automatically.
And would Google Play Games access be required only for HOSTS or also for CLIENTS wanting to play on those GPG host servers?

About the "not possible to host an internet server in IPv4", do you mean because one would probably use it wifi instead of 3g, and this would be behind a NAT, which would need to be appositely configured on router/firewall to work, right?

But, how well would work servers hosted by a cell phone over a wireless connection? Maybe in that case, the server browser shoud have a way to tell apart those "temporary" server from real servers?
By the way, about servers... the link for who wants to run an Android OA server you have in the Google App description brings to a .tar.gz, so I can guess it's meant for setting up a Linux OA server, right? Not Windows, not Android (however, for Android clients), right? Maybe this may be stated more clearly in the description.



Title: Re: Android port
Post by: pelya on March 15, 2016, 05:52:00 AM
Yes, the .tar.gz archive contains a dedicated server with game data, it also has a Windows executable though. Also, I'm the only one hosting dedicated Android servers currently, so let's forget about this option for now.

Yes, I'm talking about NAT, even if your internet provider gives you a public IP address you will probably also have a WiFi router with NAT, and most users won't know how to forward ports.

Google Play Games provide you Google servers to play games between clients behind NAT. Both server and client must enable it to play. The ping could be big or small, but it will still be lower then playing on a server in Ukraine from US.
Google' own guidelines tell to stop bothering user with a login screen if it was declined several times. Most games wil always ask you on start. I think in OA I'll bring up Play Games screen only when you're creating a public server, or trying to connect to a server which uses Play Games, and the regular IPv4 connection fails.
Google was rambling a lot lately how they won't even show login screen if the user logged in successfully the last time, I don't know how will that work if you don't have Google+ account. Some games require both Google+ and Play Games, maybe that's what Angry Birds tried to do.

3G actually has an advantage in US, because three biggest US mobile operators provide you IPv6 by default.

I've tried installing an old version and updating it through Google Play, and it worked okay, except that it did not delete the .obb data file that Google Play downloaded, and now the game takes 900 Mb instead of 400.



Title: Re: Android port
Post by: Gig on March 15, 2016, 12:24:54 PM

I've tried installing an old version and updating it through Google Play, and it worked okay, except that it did not delete the .obb data file that Google Play downloaded, and now the game takes 900 Mb instead of 400.



But how to fix a "broken" update as it happened to my phone1? Do I have do uninstall/reinstall? Wait for next update? Or could the initial launcher program detect an incorrect version of pak7 and replace it?


Title: Re: Android port
Post by: pelya on March 15, 2016, 12:33:21 PM
Simply uninstall and reinstall. Or clear app data.


Title: Re: Android port
Post by: Gig on March 16, 2016, 02:17:53 AM
I just uninstalled and reinstalled. This wiped out my game settings. For some reason, after downloading the game from google play, it also downloaded the pk3 files from the SDL launch menu...

VR mode works, apparently also in firstperson mode.

By the way, do you have some idea about the reason why lately the "awaiting gamestate" can last A LOT, when trying to connect to a server?


Title: Re: Android port
Post by: pelya on March 16, 2016, 02:33:32 AM
That's because the servers will typically start a new round and switch to a new map when you connect. When they have only bots, they end up in the game-over menu for most of the time for some reason. If there were more human players you wouldn't see it that often.


Title: Re: Android port
Post by: Gig on March 23, 2016, 03:46:31 AM
Hi! I installed the update (version 0.8.8.32).
On my phone1, again it looks like Google Play did not update pak7-android.pk3 correctly: when playing, I still often spawn looking at walls, and the cgame.qvm is dated 13/03/2016.

On my phone2, it has been updated correcly (cgame.qvm is dated 20/03/2016). There, it looks like in firstperson I do not spawn facing a wall anymore. However, sometimes I spawn looking down (not completely down), for some unknown reason. It looks like it happens in both "tap to shoot" and "shoot button" modes (I haven't tried in other modes).

On phone1, the game data files seem to be installed in the "real" sd card (/storage/extSdCard/Adnroid/data/ws.openarena.sdl/files/baseoa), while on phone2, game data seems to be installed in a "virtual" sd card named /storage/sdcard0 (/storage/sdcard0/Android/data/ws.openarena.sdl/files/baseoa), while the physical sdcard seems identified as /storage/sdcard1 there. I did not use "Move to sd" on any of the two phones.


Title: Re: Android port
Post by: pelya on June 05, 2016, 04:06:49 AM
I've fixed that other bug with wrong aiming after spawning in first-person mode.

The game selects the SD card which has more free space, during it's first start.

You can now start public online servers from the game. This will hopefully decrease reliance on my own dedicated servers for playing online, also there are still no dedicated servers for Android version in US, where the most players are.

I could not be assed to use Google Play services (also they are closed-source), so I've rolled out my own half-baked UDP hole punching solution, using my home server as a packet relay for initiating connection. So if you have symmetric NAT and no IPv6, or when I have internet outage at home, you cannot host online server and cannot join servers started by other players.

You can also change in-game brightness/gamma, independently from your Android screen brightness, I've bumped default r_gamma to 1.5 for new installations, because the game always was too dark, at least on my phone. This was the easiest fix, I've just enabled the slider in UI, and Q3 engine already supports software gamma.


Title: Re: Android port
Post by: Gig on June 05, 2016, 06:10:03 AM
Before I update, is there there some kind of log/debug I can activate, to check in case it would not update the pk3 correctly again?


Title: Re: Android port
Post by: pelya on June 05, 2016, 07:53:38 AM
You can run 'adb logcat > log.txt' on your PC. ADB itool s available from http://developer.android.com


Title: Re: Android port
Post by: Gig on June 07, 2016, 02:49:59 AM
You can run 'adb logcat > log.txt' on your PC. ADB itool s available from http://developer.android.com
This stuff?
https://developer.android.com/studio/command-line/adb.html

Do you mean the steps I have to follow are:
- download (1187 MB) and install Android Studio (https://developer.android.com/studio/index.html) on my PC
- enable "debug usb" mode on the phone and connect the phone to the PC
- enter somewhere in the PC (OS command prompt? Or does Android Studio have its own command console?) the command 'adb logcat > log.txt'
- download OpenArena update from Google Play
- check the log file on PC, and send it to you if necessary.
Right?

It looks like there are some Google Play apps (e.g. SysLog (https://play.google.com/store/apps/details?id=com.tortel.syslog)) to read logcat, but unfortunately it looks like they need root.  :(


Title: Re: Android port
Post by: pelya on June 07, 2016, 04:03:50 AM
Roughly yes. You only need to download SDK installer and platform-tools package, Google has been marketing their new shiny Android Studio lately so they hid the link to the old installer somewhere. You can also download ADB for Windows from any random site on the internet.

On Ubuntu or Debian, you just do like 'sudo apt-get install android-tools-adb'.

You cannot capture logs via an app since Android 4.0 or 4.1, for security reasons.


Title: Re: Android port
Post by: Gig on June 07, 2016, 07:28:37 AM
Okay, I downloaded the ADB Kit (adb.exe) from http://adbshell.com/downloads (525 KB).

I ran the command and updated the game on the phone from Google Play. It took some time to download "additional file" for OpenArena, however it did not report any error.
Then I opened OpenArena (the SDL launching screen briefly mentioned "no need to download") and exited it.

Brightness slider in OA GUI (which should have been enabled by your latest update) is still unavailable.
If I check in /storage/extSdCard/Android/data/ws.openarena.sdl/files/baseoa, pak7-android.pk3 last modify date does not seem to be changed. Also the .qvm files inside it seem to be dated back to March.
/storage/emulated/0/Android/data/ws.openarena.sdl/files folder seem to be empty.
/storage/emulated/legacy/Android/data/ws.openarena.sdl/files folder seem to be empty.
/storage/sdcard0/Android/data/ws.openarena.sdl/files folder seem to be empty.
It does exist a file named /storage/emulated/0/Android/obb/ws.openarena.sdl/files/main.8828.ws.openarena.sdl.obb which is 0 KB and is dated today.

According to Android Application infos, OpenArena is version 0.8.8.33, ad uses:
- Total 444 MB
- Applications 15,58 MB (where are they?)
- SD Card applications 0,0 B
- Data 20,00 KB
- SD Card data 429 MB

Plus 20,00 KB cache.
"Move to SD Card" button is available.

The phone (which is the one I mentioned as "phone1" in this previous post (http://openarena.ws/board/index.php?topic=4577.msg53614#msg53614)) is a Galaxy S4 running Android 5.0.1 (latest official Samsung firmware).

Can I send you my adb log file to the email address you specified in Google Play page?
Near to the end of the log, it looks like something interesting could be
Code:
 SS_ART_lib [I]: permission is absent: /data/app/ws.openarena.sd-1/base.apk
and later
Code:
Java.io.FileNotFoundException: /data/app/ws.openarena.sdl-1: open failed: EISDIR (Is a directory)


Title: Re: Android port
Post by: pelya on June 07, 2016, 08:06:07 AM
Please send me the log. The app should always update pak7-android.pk3, that's something not normal.
You can always uninstall and reinstall it, if you get tired of update issues.


Title: Re: Android port
Post by: Gig on June 07, 2016, 08:18:59 AM
Please send me the log. The app should always update pak7-android.pk3, that's something not normal.
You can always uninstall and reinstall it, if you get tired of update issues.
Email sent.  ;)
I already uninstalled and reinstalled the game at least once, but the update issue returned at the following update. Uninstalling and reinstalling 450 MB each time to get an updated 600 KB pak7-android.pk3 file is a bit uncomfortable.
Also, who knows how many people may have the same problem, but do not notice or do not notify? Google play does not mention any error, and reports the version of the app as the current one.


Title: Re: Android port
Post by: pelya on June 07, 2016, 11:24:12 AM
Thanks for the logs. I've found the bug - my code did not clear files from external SD card during upgrade. I've tested it on my own phone after freeing some space on SD card, and the bug was there.
I've fixed it and pushed another update, so looks like you'll get another 450 Mb to download, sorry about that.

I am using Google Play 'expansion file' to store OA data, and Google Play downloads that expansion file as often as it desires. On some phones it does not download it, on other phones it always does.
Google docs tell that you cannot touch that expansion file, however OA extracts it's data from there, and trims the file to 100 bytes to save space, that probably explains why it is always re-downloaded. I did not come up with a better way yet - downloading this file from external server on the first run made a lot of complaints from users, who don't have stable WiFi or install the game then try to play in in a subway or on a bus with no internet access.
At least the data won't be stored on your internal storage after it was trimmed.

OA was also accepted for Android TV distribution, I don't remember if I told that already. Android TV is pretty much like OUYA, but slightly less miserable, maybe it will not die so soon. And they still require borders around screen edges, so your app will work okay on shitty TVs which cover sides of the screen with plastic. I don't think you can buy such TVs for 10 years already. And you can disable that border in SDL options, but you need to know where to look.


Title: Re: Android port
Post by: Gig on June 07, 2016, 02:01:48 PM
I didn't know about OUYA having large debts and being acquired by another company past July. I was about asking if the OUYA version had those respawn problems you fixed lately and so if we had to try to contact Gamesboro to tell him to update OA OUYA edition with your fixes...

I do not know much about Android TV. Does it just use Google Play or has it got another market?

About the new update, I will try it in the next days, and will let you know the result. :)


Title: Re: Android port
Post by: pelya on June 07, 2016, 02:18:34 PM
Yes, Android TV uses Google Play, however Google employees manually review and approve each app before you can install it, so it must be above certain quality guidelines. They did it the 'Apple way' for Android TV, to battle the onslaught of poor quality apps you see everyday on Google Play, and I think it's okay, since Android TV is a totally new platform, and most of the time you must modify your app to look okay on the big screen.
They also require several usability features, such as pressing Back key shall always go back to the previous dialog, and close the app if you hit Back several times.
In most games (OA included) Escape/Back key just opens and closes game menu, but does not exit the game. So, now you can quickly close OA on Android by hitting Back 5 times in a row, from the game or any submenu, it may not be very convenient on phones, where you can hit that key accidentally, but eh, it feels more comfortable to me on my Samsung phone, when I can hit Back instead of pushing down that big physical Home button.
All in all, I've re-used OUYA code, and I only had to make yet another icon and background graphics of different size, because they could not re-use that 512x512 icon they already require from you on Google Play, lazy bums.


Title: Re: Android port
Post by: Gig on June 08, 2016, 03:48:53 AM
Downloaded, and it looks like it works, this time!  :)

It downloaded the whole package again, but if I understood correctly, the alternative would require wasting 450 MB more of space on the device, right? Or maybe another alternative could be having OA accessing data in the downloaded file directly, without exploding its content to the storage? But I can guess that would prevent users from accessing game folders to manually manage them... Uhm, it looks there is no optimal solution...

Changing brightness slider now works, but (unlike what happens on PC, IIRC), it looks like the change isn't immediately effective, but requires a vid_restart, right? Then, I can guess it would be good to make the "accept" button appear if you modify it (like it happens when changing graphics options such as Asinotropy. But attention, currently, modifying options under "graphics" and then pressing "back" does UNDO the changes, unlike what happens changing options under "display").

PS: I accidentally ended up in this "QVR" app Google Play page: https://play.google.com/store/apps/details?id=com.drbeef.qvr
It is is a port of Quake 1/Darkplaces engine for cardboard... and I noticed this line in its features:
Quote
* Command line params using a text file - create a text file in the QVR directory called commandline.txt and populate with any command line params you may wish to use
Sounds like a nice idea, isn't it?
UPDATE: I see your SDL launch options already allow to specify command line parameters, and that those parameters are also stored for the next time you lauch the app, so everything should be already ok that way... except the fact that it doesn't seem to work: I tried to add +map wrackdm17 there, but the game just brought me to the main screen as usual. Did I do something wrong?

PPS: Do you have a web page with the changelog of each version? Just for curiosity...

PPPS: I tried to switch off/on Change Device configuration --> Video Settings --> TV borders (was enabled by default) and it looks like nothing changed, the HUD still takes the whole screen as usual. Does the option have effect on Android TV only?


Title: Re: Android port
Post by: pelya on June 08, 2016, 04:22:20 AM
Works fine for me :) yeah it's poorly documented.
TV borders setting has no effect orln regular phones and tablets.
The alternative to 450 Mb updates would be to switch back to downloading data from sourceforge server when the app is launched first time. I prefer to have it on Google Play though, because if the download fails, it's Google fault and not the app fault from the user perspective.
There's no comprehensible changelog, the best I can do is Git commit logs: https://github.com/pelya/openarena-engine/commits/master


Title: Re: Android port
Post by: Gig on June 08, 2016, 04:56:50 AM
Works fine for me :) yeah it's poorly documented.
TV borders setting has no effect orln regular phones and tablets.

Uhm... what's that "oa" before "+map" in your screenshot?

About tv borders, what about adding "(Android TV only)" or similar to option text?


Title: Re: Android port
Post by: pelya on June 08, 2016, 04:59:42 AM
'oa' is parameter $0, which is ignored by almost all programs.


Title: Re: Android port
Post by: Gig on June 08, 2016, 06:43:11 AM
Okay, I finally got the command line options working, looking at your screenshot again. What seems to be needed:
1) type one random word ("oa" but also "test" or anything else) before actual parameters
2) place every single word in a separate line, with carriage return between them (I haven't tested with more complex commands yet, e.g. those which require " to mark start and ending of a long cvar value)
Example:
Quote
oa
+map
wrackdm17

We can't pretend people to GUESS a such thing without any hint...


Title: Re: Android port
Post by: pelya on June 08, 2016, 07:27:58 AM
I agree. I'll make it work the usual way, with spaces, for the first line of input.
If you want parameters with spaces inside,  like +set 'cvar value', you will have to do it multiline way, like

+set
cvar balue

because I'm not adding '' and "" and env vars substitution to my homegrown arguments splitter code.
I'l  add text like 'use new line to separate arguments' to the dialog title. Can you think of a better help text, which won't be too long?


Title: Re: Android port
Post by: Gig on June 08, 2016, 07:51:45 AM
Let me understand first... which ones of these examples would work?

+set cvar1 text1

+set
cvar1
text1

+set cvar1
cvar1a text1b

+set cvar1 text1 +set cvar2 text2

+set cvar1
text1a text1b text1c
+set cvar2
text2a text2b

+set cvar1
Text1a text1b
+set
cvar2
text2a text2b

+set cvar1
text1a text1b text1c
+set cvar2 text2

+set cvar1
text1a text1b text1c
+set cvar2 text2 +set cvar3 text3

Isn't it possible to add in the page a button which would open a window with extended help text, to include a couple of examples?


Title: Re: Android port
Post by: pelya on June 08, 2016, 08:10:50 AM
I'm happy to tell you that none of your examples would work  ;D

The text in the dialog:
Code:
openarena
+set
cvar1 text1
+set
cvar2 text2 more text

will be translated into following command line:

'openarena' '+set' 'cvar1 text1' '+set' 'cvar2 text2 more text'

I'm not happy about the idea of another button opening a separate help dialog. Please propose something that will require less than 30 minutes of coding. Like a help text in a dialog title :)


Title: Re: Android port
Post by: Gig on June 08, 2016, 08:16:15 AM
I'm happy to tell you that none of your examples would work  ;D

Because of the lack of the $0 parameter? It seems useless, cannot you add it automatically? Which examples would work then?


Title: Re: Android port
Post by: pelya on June 08, 2016, 08:21:36 AM
No, because all your examples except one contain '+set cvar1' on a single line. Try running this in your PC:

openarena '+set cvar1' text1

Everything on one line gets enclosed in quotes. What you want to do is openarena +set 'cvar1 text1', so you put 'cvar1 text1' on one line, and all other parameters on separate lines


Title: Re: Android port
Post by: Gig on June 08, 2016, 08:24:39 AM
A message like "Use new lines instead of spaces. Use spaces only for multi-word values."?

Ehm... you mentioned "with spaces for the first line of input", so I did the examples that way.


Title: Re: Android port
Post by: pelya on June 08, 2016, 08:29:12 AM
And your single-line example would work for some different command, like

openarena +map wrackdm17

But you put "+set cvar text" there, and 'cvar text' must be a single argument with spaces, so it must be on a separate line.


Title: Re: Android port
Post by: Gig on June 08, 2016, 08:30:34 AM
What you want to do is openarena +set 'cvar1 text1'
I should test on pc. At memory, I would say +set cvar1 "text1" instead.


Title: Re: Android port
Post by: sago007 on June 08, 2016, 08:30:53 AM
@pelya
You should remove argument 0 as Gig suggested. It should not be possible for the user to set it directly.

A short description test could be: "One argument per line". Much shorter than "Use new lines instead of spaces. Use spaces only for multi-word values.". For people understand argument parsing it is not that hard to understand.

Give one short example like:

Code:
+set
nick
This is my name
+map
dm4ish


Title: Re: Android port
Post by: pelya on June 08, 2016, 08:41:01 AM
Okay okay, I'll remove argument $0.

Yes Sago, you are correct, I've just checked on PC, and +set command accepts two separate arguments, and that one-line Gig's example will work okay.

I enjoyed this discussion. Please post here more commands, and I'll reply with explanations why they will not work :D


Title: Re: Android port
Post by: Gig on June 08, 2016, 09:48:33 AM
@pelya
You should remove argument 0 as Gig suggested. It should not be possible for the user to set it directly.

A short description test could be: "One argument per line". Much shorter than "Use new lines instead of spaces. Use spaces only for multi-word values.". For people understand argument parsing it is not that hard to understand.

Give one short example like:

Code:
+set
nick
This is my name
+map
dm4ish

"nick"? I guess you mean "name", right?

Not sure about "argument" concept being so clear by its own, however the example explains it well.

PS: Also "do not specify quotes" or similar should be part of the instructions, maybe?


Title: Re: Android port
Post by: sago007 on June 08, 2016, 10:19:41 AM
"nick? I guess you mean "name", right?
Yes, it should be name.

Argument to commands are a bit surprising at times. Rather do something simple like the list of arguments than trying to implement a command line parser. A command line parser would most likely lead to surprises for someone.

If there was an UI widget that emphasized that it is a list and not a free text field it would be great but that is wishful thinking.


Title: Re: Android port
Post by: Gig on June 08, 2016, 12:27:39 PM
I don't know what's the reason Pelya cannot simply pass the command line parameters string "as is", including quotes and everything, as a single line, to write it exactly like on pc. I suppose there is some reason.

Having a GUI to enter any possible thing (latest Sago's post), instead... would be extremely complicated.


Title: Re: Android port
Post by: pelya on June 08, 2016, 12:33:04 PM
The reason is that I am not launching OpenArena executable through the shell. The app itself is the executable.
So I've got the string with your quotes and everything, and I must pass it to OpenArena main() functions as
int argc, char *argv[]
How do you fill that argv array? Well, parse it.
Now that you've told me, I could do something atrocious, like invoking an actual shell, with a shell script that will simply write out all arguments, one per line.


Title: Re: Android port
Post by: Gig on June 09, 2016, 06:33:26 AM
Talking about something different:

1) It happened that accessing "multiplayer" screen made the game froze. Forcedly cosing it and opening again made it froze again when going to multiplayer. Then I cleared the app "cache" and it started working again. I don't know what happened.

2) While using 3G, it looks like the PING times shown by server browser are much more variable and higher than what's shown while actually playing in the server. I cannot tell if that was something it always did or is something new.

3) Server browser says "7 of 7 Arena servers" on "Internet" (while "3 of 3 Arena servers" on "Internet (2)"). I have "Game type: All", "Show full: on", "Show empty: off", "Only humans: off" and "Hide private: off". But it actually shows only three servers (the usual ones)... where are the others? Sometimes it says "5 of 5" and shows 2 servers. Any idea? Maybe there are some servers which are published to master server but are not actually reachable?

4) I tried starting a (non-dedicated) server from the phone. The only "server type" it allows me to choose is "LAN only" (which is shown red), in both cases of Wifi and 3G connection.

5) I still don't have cardborard or gamepad, but just to try, I enabled your VR mode again. I noticed that map loading screen writes the first two lines of text big and centered, instead of doubled in both "screens". Also, framerate indicator appears in right "screen" only.


Title: Re: Android port
Post by: pelya on June 09, 2016, 08:06:51 AM
No idea about freezing, I will need to catch this bug on my side.

3G network will give you very high ping when pinging new IP address, then if you continue to send packets, the ping will become lower. This is lamentable but expected.

The game now uses masterserver for it's own shady stuff, namely to determine the NAT type you have, so there will be some 'ghost' servers you cannot ping. I would use my own masterserver for this, but I have only one public IP address, and you need two for that thing.

And it looks like you have 'bad' kind of NAT, if the game won't allow you change server type. 'Bad' NAT is called symmetric NAT, it's usually found on corporate networks or on very crowded internet providers. All other types of NAT are 'good', meaning that you can connect two hosts behind 'good' NATs, but you cannot connect 'good' and 'bad' NAT, or two 'bad' NATs - you can only connect 'bad' NATs to servers with public IP, such as those three dedicated servers we have. 'Good' NATs are the restricted cone NAT, the port restricted cone NAT, and the full-cone NAT - the best one, it's essentially like having a public IP.

You can also start public server if you have IPv6 address. IPv6 addresses are always public, which means there are no NATs and you can host whatever server you want on any IP. Some people set up NAT anyway on IPv6, but it's more for security reasons. You cannot connect IPv6 with IPv4 directly.

On my 3G connection, my network operator allocates a public IPv4 address with no NAT at all, but no IPv6 address. I know that Verizon in US gives you IPv6 address by default, I don't know about AT&T.

You can install an app called STUN client, it will tell you which NAT type do you have. this one works okay (https://play.google.com/store/apps/details?id=com.kodholken.stunclient&hl=en). Don't select stunserver.org server inside the app, it does not work anymore. stun.ekiga.net works for me. Try it on both 3G and WiFi connections (and also in local mcDonalds if possible, they have free WiFi).
If you will find any connection which is not symmetric NAT, OpenArena should allow you to start an online server.

If you are going to test it extensively, please tell me when, so I can join.


Title: Re: Android port
Post by: Gig on June 09, 2016, 08:58:08 AM
You can install an app called STUN client, it will tell you which NAT type do you have. this one works okay (https://play.google.com/store/apps/details?id=com.kodholken.stunclient&hl=en). Don't select stunserver.org server inside the app, it does not work anymore. stun.ekiga.net works for me. Try it on both 3G and WiFi connections (and also in local mcDonalds if possible, they have free WiFi).
If you will find any connection which is not symmetric NAT, OpenArena should allow you to start an online server.
With my work Wifi it says "Symmetric Cone NAT". I will test with my home Wifi in the next days (I haven't tried acting as Android OA Multiplayer Host there yet).
With my 3G connection it says "Symmetric Cone NAT", too.


Title: Re: Android port
Post by: pelya on June 09, 2016, 09:06:07 AM
Yup, that's the type of NAT you install to prevent your employees playing videogames and downloading torrents.
I don't know why your 3G operator is that restrictive. Probably they got an expensive unlimited plan, which also gives you a new shiny public IP.


Title: Re: Android port
Post by: Gig on June 10, 2016, 08:24:08 AM
Also at home I have Symmetric cone NAT. I suppose it's how NATs are most commonly set up, isn't it? In theory, I could setup static port forwarding on my router as I would do to host a classic Internet OA server on PC...

Just for curiosity: what's your opinion about UPnP?

However, I finally found another human player on one of your Android servers and did a couple of matches. :)
Playing, I noticed a few times that something strange happened to the view: I was no able to look more down than a certain point... I had to tilt forward and look completely down with the virtual stick to be able to see at human height, otherwise it looked about 45 degrees higher than normal and I was not able to look at the ground. After some time, it apparently fixed by itself... then happened again, and "fixed by itself" after a minute. I was playing in firstperson mode, with gyroscope aiming enabled.


Title: Re: Android port
Post by: pelya on June 10, 2016, 08:48:11 AM
My router does not support UPnP, so I have no opinion on it. If your router supports UPnP, I can add the support to OpenArena. There's another Android app you can use to scan your netwirk for UPnP hists.
I don't know how NAT are commonly set up, in my office we have a port restricted NAT, and I could not find any statistics on it.

I will look into that new aiming bug.

Edit: I already reproduced it, it happens after the first respawn, and disappears if you look up. Oh well.


Title: Re: Android port
Post by: Gig on June 10, 2016, 09:25:46 AM
It looks like my router supports upnp. It has general options to enable it and to set its port, plus "answer to client request" and "interface is upnp controlled" checkboxes for every interface. I think I never tried it.

Now that I think about that, maybe I never asked Sago to add UPnP support to PC OA due to I thought that making internet servers is something that should be done only by who knows what he's doing, because of in OA a badly configured server (just a pk3 file in the wrong folder) can mess up local installations of any player connecting to it with autodownload active....


Title: Re: Android port
Post by: pelya on June 10, 2016, 09:45:45 AM
Actually no, it will not mess up your installation. If you connect to my dedicated servers without updating OA, they will push their own pak7-android.pk3, so it may crash the game, but it will be reverted to your original one if you close and restart the game.

I guess that's a feature of an updated ioq3 engine I'm using in Android port.


Title: Re: Android port
Post by: Gig on June 10, 2016, 10:18:05 AM
Pk3 overwritten and then automatically reverted to original at next start? That sounds new to me. Maybe Sago or Fromhell do know something about that stuff?

I don't know really how do PC quake3/openarena manage the case of autodownloading modified files with the same name of existing files (maybe I saw the game adding some suffix to filename? I don't remember)...

However the typical case of "messing" servers are pk3 with different names than standard ones (e.g. pak9.pk3, zztest.pk3) in baseoa folder which are loaded after the standard ones and do include weird stuff such as a qvm thought for a mod. Such messy pk3 files, after have been autodownloaded by the client, are permanently stored in homepath... while not showing problems playing on other servers due to being ignored by "sv_pure", they do cause strange behaviours when playing locally.


Title: Re: Android port
Post by: pelya on June 10, 2016, 10:58:42 AM
It saves the file with prefix consisting of it's MD5 sum, I think. It does not save it to baseoa directly, but into your $HOME/.openarena/ directory.

I'm not sure about pak9.pk3, I should test it.

Edit2: I've fixed that aiming bug and published another update

Edit3: I've checked by creating baseoa/pak9.pk3 on a local server, and this file does stay inside $HOME/.openarena/baseoa and is loaded when you close and relaunch the game, so the problem is there.

Edit4: The behavior when OA reverts to it's original pak7-andorid.pk3 is my own code  :-[  it's literally this during the start: remove(".openarena/baseoa/pak7-android.pk3");
So I can simply remove every .pk3 file from .openarena/baseoa when the game starts. And you can put your maps directly to baseoa, they will be disabled when connecting to a pure server anyway.
I've fixed that bug already, it will be in the next update.


Title: Re: Android port
Post by: Gig on June 13, 2016, 08:16:32 AM
The new version of command-line parameters seems to work, however it looks like it adds an extra blank line at the beginning each time you enter the option.

Do you mean that in the next update you will clear pk3s from homepath at every app launch, while will remain untouched in basepath, right?

About basepath and which is homepath in Android version.... If I query "fs_homepath" cvar, it reports /storage/extSdCard/Android/data/ws.openarena.sdl/files/.openarena... but if I query "fs_basepath" cvar, it reports "."... Uhm... I guess it is my "/storage/extSdCard/Android/data/ws.openarena.sdl/files/" (due to stock .pk3 files being in "/storage/extSdCard/Android/data/ws.openarena.sdl/files/baseoa"  xD), but why does the cvar do not report such path?

PS: Just in case (however I see you already did the pak9 test).... Some readings about basepath/homepath in PC version of OpenArena and troubleshooting problems related to autodownloaded files...
* (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/FAQ#Configuration_files_and_automatic_downloaded_files_path
** (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/FAQ#Where_are_the_configuration_files_saved.3F
** (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/FAQ#Where_are_autodownloaded_files_saved.3F
** (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/FAQ#Can_I_change_the_directory_to_where_configuration_and_autodownloaded_files_are_saved.3F
* (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/FAQ#Yesterday_everything_worked_correctly.2C_but_today_I_experience_strange_problems
* (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Manual/Automatic_downloading

PPS: Also, I don't remember... if I pull down the console with "/~", is there a way to confirm commands typed there?

PPPS: The drawback of clearing automatic downloads would be having to re-download extra stuff each time one would connect to the server using it. Or manually moving such stuff from one's homepath to basepath, something which probably not many Android OA users would think about. I don't know which would be the best solution, if allowing people to mess up their install, or delete autodownload files automatically. Maybe adding an option in external SDL menu, to delete extra pk3s only at user's request, to be used just in case something got wrong with autodownloads?


Title: Re: Android port
Post by: pelya on June 13, 2016, 09:04:50 AM
Yes, I'll clear eberything from homepath baseoa directory. So if you want to host your own map, creade a 'mod' directory for it, 'Gig-map-collection' will work fine, and will not be deleted from homepath on each launch after downloading.

baseoa will be erased on each start, so users won't have to open file manager or search for some obscure SDL option to fix their OA installation. Always assume that the user is capricious idiotdoes not care about technicall details, and wants the game to just work.

The directory '.' is indeed .../Android/data/ws.openarena.sdl/files, it's the current directory when OA launches. Homepath directory is <basepath>/.openarena

I'll be adding primitive UPnP support to the next version, I discovered how to enable UPnP on my router, so I can test it, and there are chances it might work on your setup.

To execute commands in console, you just press Enter on your keyboard, or press Next button in the text input field.
When inside the game, you have to prepend / to the command, but you don't have to do that in main menu.


Title: Re: Android port
Post by: Gig on June 13, 2016, 10:05:37 AM
If you add UPnP support, I may do some test with my router and let you know.

About console, it works from your input tex field, but it shows the last few lines only... /~ brings down the whole console, but it seems to act a bit weird...

PS: as Android OA features continue to go different than main game, you may wish to make a page in our wiki with more infos for users. :-)


Title: Re: Android port
Post by: pelya on June 13, 2016, 01:50:36 PM
The hardware keyboard text input for console worked some time ago, but it's possibly broken, as I did not test it for a very long time. I'm primarily testing only with touchscreen. I'll check it in the next version, if I'll have time.


Title: Re: Android port
Post by: Gig on June 13, 2016, 03:18:51 PM
I'm not talking about hardware keyboard. I changed phone more than a year ago, and no physical qwerty phones were around anymore. And I haven't bought a Bluetooth keyboard. Activity on this forum is less than a few years ago, so I don't type on phone as much as in the past (although I'm doing that in these days to talk with you).

Another thing: what do you think about the brightness slider thing I mentioned here http://openarena.ws/board/index.php?topic=4577.msg53724#msg53724 ?


Title: Re: Android port
Post by: pelya on June 14, 2016, 06:21:19 AM
For me, that 'Apply' button is evil - no other dialog has it, and Android apps generally do not have such thing, all settings are applied instantly. So I guess I'll simply do vid_restart when you change brightness and close this dialog, and then I'll also do the same for video settings dialog.

I don't quite understand about console. How are you invoking it, and what exactly does not work? Could you please describe step-by-step?


Title: Re: Android port
Post by: Gig on June 14, 2016, 06:48:11 AM
For me, that 'Apply' button is evil - no other dialog has it, and Android apps generally do not have such thing, all settings are applied instantly. So I guess I'll simply do vid_restart when you change brightness and close this dialog, and then I'll also do the same for video settings dialog.
Okay.

However, talking in general[1], the inability of "undoing" settings changes if you immediately find out you made some mistake (due to removal of "apply/ok" and "cancel" buttons) is one of the things I don't like of "modern" user interfaces of programs. Also Firefox, which in the last years "follows" Chrome too much IMHO, has went on that side. It's something I really don't understand... maybe they have cell phone interface in mind even on PCs... But I would prefer to have a way to do not "commit" a mistake at the cost of just one more click each time. Sorry for the rant.

Quote
I don't quite understand about console. How are you invoking it, and what exactly does not work? Could you please describe step-by-step?
I'll try with some screenshots. Yesterday I tried, but I was in the car parked under the sun, and that would have taken too much...  :RIP: Also, I have to resize screenshots... they are 2 MB each..

[1]Not focusing on the current case of Q3 UI, although that's a bit strange maybe for a 1999 game. Q3 UI thas thing strange thing of "apply" in graphics settings change, but not in the other pages. I can guess it's due to that screen being the one which needs a vid_restart when you change something. However, from an user's PoV, that's strange that one menu works differently than the other similar ones.


Title: Re: Android port
Post by: pelya on June 14, 2016, 07:22:53 AM
In 1999 changing video mode or enabling some OpenGL feature could turn off your CRT monitor or crash your Windows 95, that's why you have this 'accept' button. And switching from window mode to fullscreen is also a big hassle even today, when the game jumps at you and takes away your system taskbar, so it also looks better with confirmation.  Today it's much less important, especially on a phone.


Title: Re: Android port
Post by: Gig on June 14, 2016, 07:48:46 AM
Not focusing on the current case of Q3 UI, although that's a bit strange maybe for a 1999 game.
I meant that Windows programs, back then, usually had "apply/ok" and "cancel" in any settings window. Of course, that may not necessarily apply to games, too.  ;)

However, let's see the console thing. As told, the main goal was just to "see" some more lines of console output (and that's possible), however, once one's there, one may wish to type commands there (although not a major issue).

I'm playing in a map...
(Screenshot 1)
... then I use upper-left yellow sdl button to enter commands... and I type "/~", confirm ("Successivo" is "Next" in Italian).
(Screenshot 2)
So, the game shows the console. All SDL yellow buttons become hidden.
(Screenshot 3)
Although it is hidden at this time, the upper left sdl button still works, to I touch it and can start typing again.
(Screenshot 4)

... continues in next post (max 4 attachments per post here).



Title: Re: Android port
Post by: Gig on June 14, 2016, 07:52:29 AM
Continues from previous post.

So, I type a command and press "Successivo" (Next) again.
The text I typed is passed to the console, but it's not "confirmed" by a "return". So it stays there, useless.
(Screenshot 5 and close-up)

Note1: Theoretically, I may change my cl_consoleHeight cvar to see even more text. But for some reason it doesn't seem to have effect here.
Note2: If I type "/~" from main menu, the console is opened and closed immediately.


Title: Re: Android port
Post by: Gig on June 16, 2016, 01:25:47 AM
I finally found out how to see Google Play comments in other languages: by adding "hl=contrycode" parameter at the end of the URL in the browser.
A few examples:
Google Play in Italian: https://play.google.com/store?hl=it
Google Play in Spanish: https://play.google.com/store?hl=es
Google Play OpenArena page in English: https://play.google.com/store/apps/details?id=ws.openarena.sdl&hl=en
Google Play OpenArena page in French: https://play.google.com/store/apps/details?id=ws.openarena.sdl&hl=fr

So, I read that someone is complaining about the lack of the ability of swapping axis on touchscreen. Going to the aim settings menu, it looks like there is some axis swapping option for gamepad and for gyroscope, but not for touchscreen control. I do not need it, but it looks like someone is used to inverted Y axis and asks for it.

[UPDATE] Also, I see someone would like a way to disable the jumping by double tapping the joystick feature.

[OT]
Reading Italian comments, I see a guy asked you to port Freedoom (https://freedoom.github.io/), too (it looks like there is no Android port for it yet). In case one day you wish to try a such thing, I may provide some feedback by using one of the "other projects/not openarena" sections of these forums (e.g. http://openarena.ws/board/index.php?board=55.0[1] http://openarena.ws/board/index.php?board=74.0 or http://openarena.ws/board/index.php?board=38.0), if Fromhell does not have anything against that.

[1] That section was used for other free FPS games Fromhell was somehow involved I think, until she changed its name to "Pointless" due to being upset by someone of those other projects she was following. I don't know which games were part of those projects... maybe FreeDoom, too?




Title: Re: Android port
Post by: pelya on June 16, 2016, 09:55:43 AM
I've added an option for inverted vertical axis controls (just renamed the same gamepad option, and made it work for touchscreen).

I'll add more options for joystick taps, including the possibility for disabling it. I'll also remove 'tap to aim' modes, they are poorly implemented, and instead add 'tap to aim' option to the normal aiming mode.

I will not start other project, I have enough trouble with my existing ports. Maybe I'll port SDL-Ball, because it will take just one day to port.

Gig, do you have a Google account?


Title: Re: Android port
Post by: Gig on June 16, 2016, 10:44:25 AM
I've added an option for inverted vertical axis controls (just renamed the same gamepad option, and made it work for touchscreen).
Man, you work extremely fast!

Quote
I'll also remove 'tap to aim' modes, they are poorly implemented, and instead add 'tap to aim' option to the normal aiming mode.
Not sure what you mean, we will see the result. :-) I usually use "tap to shoot" mode. I have just made a quick test (no bots) with "aim under finger", and while it seems working enough when you have to use it to quickly aim at something at your right, maybe it is not optimal when you have to use it to aim at something at your left, because you cover a lot of the screen with your right hand.

Quote
I will not start other project, I have enough trouble with my existing ports.
Oh. Okay, I understand. Let me know in case if you change your mind in future.
Quote
Maybe I'll port SDL-Ball, because it will take just one day to port.
I didn't know it... just found some screenshots, it looks like it's Breakout/Arkanoid! Nice!

Quote
Gig, do you have a Google account?
Associated with my "Gig" nickname, not... Why?


Title: Re: Android port
Post by: pelya on June 16, 2016, 11:01:34 AM
Actually, I've made this change yesterday, after reading user reviews.

I wanted to give you access to Play Store dev account, where you can read reviews in all languages, and check install statistics.

The decision to stop porting random crap to Play Store was not an easy one for me. But it's better to have a few games that work fine, than a heap of games with terrible controls and bad ratings. Plus, not every game is actually worth porting, there are heaps of Breakout clones on Play Store, SDL-Ball won't be anything unique, and being open-source does not matter for a regular user.


Title: Re: Android port
Post by: Gig on June 16, 2016, 03:07:51 PM
Oh, thank you... however I'm not planning to open another user account at the moment. Maybe in future.
However for me taking a look to italian and english comments by now and then is enough at the moment. Also, you may find it annoying, having me repeating things said by others (and which you read by yourself) if I do it too often.

About other games, maybe you are right saying that there are already many Arkanoid clones on Play Store. Having to choose only few projects, one may select something "new" to the Store.
Although a port of a nice game being done in one day may sound appealing... if the game is nice and pops out often in searches, it may contribute making more people know about you and your other ports, at the expense of a single day of work...


Title: Re: Android port
Post by: Gig on June 17, 2016, 02:26:13 AM
Speaking of something else...

I don't know if I will continue to use gyroscope aiming on... it's cool, but if I change my own position (e.g. I was seated and then stand up), the game ends up with an inclined (rolled) view which is then not easy to return to normal. I usually play in firstperson mode.

I noticed that the portal effect in oa_dm3 does not work well.


Title: Re: Android port
Post by: pelya on June 17, 2016, 04:28:17 AM
What can you propose for gyroscope aiming? A centerview button? Or maybe shake the phone a bit, to center your aim?

There are random graphical bugs, in some levels the sky can disappear, but I thought it's just my phone acting up. Could you please do a screenshot?


Title: Re: Android port
Post by: Gig on June 17, 2016, 05:36:05 AM
About how to re-center view after you moved too much with gyroscope... Not sure... you already use shaking phone for starting voice talk, isn't it? A button may be okay, but you would need to show it only if you have gyroscope aiming active, otherwise people would wonder what's that button for... although if one is decides to add one more button, it may be more useful for walking (to avoid falling down from platforms) than for resetting gyroscope roll? Maybe the same action may do both things? Or maybe gyroscope roll may return normal just after a few seconds you don't use it to roll your view? I really don't know....

About glitch, you can see screenshots from oa_dm3 (screen 1 shows you have to enter that small opening, screenshot 2 shows the actual portal and the glitch). I also see the glitch happens in oa_dm5, too... where it is more easy to find the portal.

Screen 3 instead is from oacmpdm10, where I noticed a sharp effect where the external wall (a curve) touches that solid brush structure, although I have geometric detail "high". Is it due to some tweaking which you did to make curves render faster on phones, maybe? There are some cases where performance may be better than perfection, that's just to know.

Another thing: while playing locally, I tried to change map by calling a vote for it. It allowed me to select the map, but after I confirmed, it replied "Map is not available". It looks like it works if I "/callvote map" from console, instead. Any clue?
Update: it does the same playing on your servers.

A question: do you think having OpenArena in foreground should prevent the phone from going in standby mode/turning off screen, maybe?

UPDATE: I added a fourth screenshot showing that marks on walls do not blend perfectly.


Title: Re: Android port
Post by: Gig on June 18, 2016, 03:27:50 AM
Another thing: while playing locally, I tried to change map by calling a vote for it. It allowed me to select the map, but after I confirmed, it replied "Map is not available". It looks like it works if I "/callvote map" from console, instead. Any clue?
Update: it does the same playing on your servers.

It looks like it affects also other kinds of voting...

Nextmap -> Invalid vote string
Restart match -> Invalid vote string
Shuffle teams -> Invalid vote string
Map -> Map is not available
Gametype -> Gametype is not available
Kick -> Working
Disable/enable warmup -> Working
Fraglimit -> Working
Timelimit -> Working
Cutom vote: Not tested

Vote yes/vote no: working.

Side note: the line which informs players whether to vote yes or no gets the console output over, making it hard to read until console text times out.

A question: do you think having OpenArena in foreground should prevent the phone from going in standby mode/turning off screen, maybe?
Maybe in case one is acting as a multiplayer server, the game should prevent the phone from going in standby and should continue running the game even if it is in background?
Currently, if the player which hosts the game switches to home screen, or does not touch anything for a while and his phone goes black, connected clients immediately get "connection interrupted". This is something which may be very frustrating, especially on Internet published servers. Id software allowed only "dedicated servers" to be reported to the master server (as to say, to be internet servers), I can guess partially due to the possible problems caused by bad pk3s, but also due to the fact that players acting as servers may close the game at any time. So, I suppose you may add some kind of warning in case one is connecting to (or browsing) an Android "non dedicated" internet server.


Title: Re: Android port
Post by: Gig on June 24, 2016, 03:25:28 AM
Hi Pelya. Just to say to take your time for thinking about the things mentioned in the previous posts: I'll be going to have some holidays and so will be online quite little in the next week or two. Also, probably I will not have wifi access, so I couldn't download an OA update anyway.


Title: Re: Android port
Post by: pelya on June 24, 2016, 03:55:00 AM
I confirm that the voting is broken.

I have quite a lot to fix for the next release. I'll probably limit it to UPnP and voting menu fixes.

The proper way to run a server would be when the phone is unused, with screen turned off, charging and on WiFi. That's how Skype works.
Starting dedicated server from Android app is not complicated, what's xomplicated is how to inform the user about this. The server config might be just your last server map and gametype.


Title: Re: Android port
Post by: Gig on June 24, 2016, 07:03:03 AM
Starting dedicated server from Android app is not complicated, what's xomplicated is how to inform the user about this.
Excuse me, what do you mean exactly? Inform who about what?

In quake3 (which IIRC did not have a dedicated server binary like PC OA has), one started a dedicated server by using +set dedicated (1 or 2) by command line or by typing /dedicated (1 or 2) and then loading a map. The GUI goes out and you see only the console, until you set dedicated 0. IIRC... I can't test now. Maybe android could so something similar, but with a button to turn it off and on more easily? Or may provide a separate program (invoked by initial sdl menu or as separate download from play store, with its own app drawer icon) which would be a port of "oa_ded". Just brainstorming.


Title: Re: Android port
Post by: fromhell on June 24, 2016, 07:40:08 AM
The Q3 behavior on Windows is that launching a dedicated server would bring up the same early startup console for the console output.  It would be launchable through the game's q3_UI system as well.

IIRC OA's behavior currently is to reuse the same console in GL but at a sanely  low framerate if started through the ingame UI.  OA3 does not utilize the early console window for dedicated servers (and probably doesn't need to especialyl with regards to android)


Title: Re: Android port
Post by: pelya on June 24, 2016, 08:33:50 AM
What I mean by 'dedicated server' is the server that is running without local player and without user interface.
Like, you plug your phone into a charger and leave it, OpenArena detects that the screen is powered off for 30 minutes, charging and on WiFi, and starts the server without asking you.
You pick up your phone, and see a notification 'OpenArena server is running, tap to stop'. Or it will stop in 30 seconds after turning on the screen.
No commandline or console is involved. And I hope that with UDP hole punching, there will be a least few people able to host without configuring their routers.

The problem is how to ask for user permission to start the server in that way. Like a big red popup: 'Click this checkbox, save OpenArena Android community. Your phone might charge 2x slower'.

Speaking about community, there are currently 4811 active app installs, only 1665 have the latest version, around 1500 using version 0.8.8.29 and below, they'll probably be unable to join any of the dedicated servers, because of changes in QVM files.

I don't have any statistics about how many people are trying to play OpenArena online. I'm checking the game 1-2 times a day, only to find empty servers.
I imagine it like that: you open the game, go to Multiplayer menu, look at empty servers, with ping 500 if you're in US, maybe you try to host your own server for 5 minutes, then you get bored and close the game.
There are just not enough active players to keep it sustainable, and the user base does not grow at all after the initial spike.

There is also quite an onslaught of 3D shooters on Play Store, both first-person and third-person, OpenArena does not really bring anything new from the user point of view, which is a shame, because I've seen gyroscope support in just one game, I think it was Nova 3, and it has ads.

So I guess I'll do one final update with UPnP support and improvements to touchscreen controls I was talking about earlier, and be done with this game.

I've discovered recently that on Android 6.0 OpenArena cannot unpack data from SD card, that Play Store downloads for it into .obb file, because it does not ask the user for SD card access, as required by new Android security model. So it downloads the data from sourceforge.net server instead, and does not delete the .obb file.
What do you think is better - to show the dialog asking for SD card access when the game starts, or to download the data from the external server instead of Google Play, so the game itself will shrink back to 10 Mb, and will not require SD card permission?

Quote
A question: do you think having OpenArena in foreground should prevent the phone from going in standby mode/turning off screen, maybe?
No, if you leave OA open without touching the screen, it will eventually turn off the screen and that will pause the server. I will change this to not allow screen to turn off while OA is in foreground, this does not require any permission changes.

Quote
About how to re-center view after you moved too much with gyroscope... Not sure... you already use shaking phone for starting voice talk, isn't it?
Yes, but you shake it from side to side for voice, and for re-centering camera you would twist it in the hand :) I guess it's too complicated and not intuitive.

Quote
Is it due to some tweaking which you did to make curves render faster on phones, maybe?

No, it's because Android version uses a mix of the original ioquake3 renderer and OA renderer with disabled shaders, running in GLES1 mode. I've tried to build GLES2 renderer for shaders support, and it even launched, but all textures and half of level geometry were gone  >:( and I am not an OpenGL expert to rewrite Quake3 renderer for GLES2, I only know relatively well the GLES1 fixed pipeline.


Title: Re: Android port
Post by: Gig on June 24, 2016, 10:27:29 AM
Are you making some work on your servers right now? I just tried (days ago I noticed maybe also on wifi server browser shows much higher pings than when actually playing, but I wanted to do some more tests first) and it says "no server found".

About other things, I'm writing from phone and I don't have much time, so I'll try to be brief (which is not my best).

I don't like things acting too much automatically, such as programs running in background after you voluntarily closed them (some games do send notifications even after "do you want to quit? Yes"). So, also a server should start and stop when I tell to start and stop.

You may add a button when you start a server to decide if you want it dedicated or not (if you want to play or not). Maybe older OA versions had it...

Oops... I gotta go now. Real life calls. Sorry.


Title: Re: Android port
Post by: pelya on June 24, 2016, 10:33:37 AM
I did not do any maintenance work on my servers, however I've had a few power oitages at my home this week, so they were unavailable.

I can add a button to start dedicated server to the game UI, but how many people will click it?

Edit: my servers are down right now, they were running just 2 hours ago. Yet another internet outage I presume.


Title: Re: Android port
Post by: Gig on June 24, 2016, 01:48:20 PM
Not sure what to suggest about Android 6 issue.

About online gamers, maybe we lack some PR. Lack or PR is an issue also with standard PC version.
We lack active server admins writing in these forums, and players organizing here their matches. In these forums we talk about development, help and troubleshooting... but there isn't much regular activity.

We would need someone talking about the game in game communities and social networks.

About Android OA, other than allowing people to start temporary internet servers from their phone (which actual quality may vary due to connection and other aspects), we should also find someone running a stable US server. Someone already owning standard OA servers may fit. But I don't know exacly how to find such people. Maybe on some of the OpenArena-related IRC channels (see main page of the wiki)?
Also, maybe when you will post next update, you may add in description we NEED some servers in US, and providing some more infos about the android dedicated server download (once you said me the package includes Linux and Windows binaries, but Google Play page does not mention it).

About people in the servers, by now and then I try to connect and spend some minute there waiting for someone to join... but the fact the phone goes standby after a few time I let it on the table does not help.

Also, adding some more bots in your FFA server may make the waiting for human players a bit more enjoyable (1vs1 in large maps isn't the best).


Title: Re: Android port
Post by: pelya on June 26, 2016, 05:15:00 PM
I've increased the amount of bots on all my servers.

I think I'll end up buying some virtual host in US, because we need to grow the community first, and also because I'm too lazy to implement good-looking dedicated server UI in the game.

I've found that some hosting providers offer plans around $16/year for 256Mb RAM virtual host, which is absolutely not that expensive, considering how much time I've spent on this game: https://lowendbox.com/
My OpenArena servers running on ARM box consume 158 Mb of RAM each, so it should fit right in, and I'll also move my NAT hole punching masterserver there, so internet outages at my home won't have such a big impact. The downside is that CPU is shared between virtual hosts, so the server might freeze at random. I don't know if this will really impact the server, as I've never tried VPS. I also think they might change your IP address from time to time, but that can be solved by updating the app.

... Another weekend passed, and all I did was ordering pizza, playing games on my phone and sleeping. I blame hot summer weather ;) Maybe I'll publish a release next week ...

Edit: here's a bit of statistics from Play Store developer page.


Title: Re: Android port
Post by: Gig on June 27, 2016, 09:01:51 AM
Yes, looking at those stats, a server in US would be useful.


Title: Re: Android port
Post by: pelya on June 27, 2016, 03:13:37 PM
US server is up :) it's called 'Surplus Railguns', the ping from Ukraine is 150 and stable enough.

It's running on a VPS host in Los Angeles, it got 512 Mb RAM, 10 Gb of slow HDD (who cares), 1 Tb monthly data limit, 100 Mbit connection,  and two CPU cores of unspecified speed - in theory it's 2.4GHz Xeon, but it's shared between all users on that server.

The cost is $12.99 per year. I cannot say that I'm financially devastated :) That's a promo plan though, I don't know if it will be available next year, but it seems like it should be, as long as I keep renewing it.

Edit: I've pushed an update, with UPnP support and fixed voting. I didn't do any other changes. In the next version, I'll switch my NAT detection algorithm to use masterserver on that US-based server, so it won't spam the common serverlist with dummy registrations, I did not have enough time to do that today.


Title: Re: Android port
Post by: Gig on June 29, 2016, 04:27:17 AM
I'll have to wait until I get back to city to download the update (I don't want to download 400+ mb via 3g), so I cannot join the server now.
Does the "railguns" in the name mean you enabled instantgib option there?
What about specifying "us" in server name? Just a thought.


Title: Re: Android port
Post by: pelya on June 29, 2016, 04:39:34 AM
No, it's just a name.
What name would you propose?


Title: Re: Android port
Post by: Gig on June 29, 2016, 08:47:08 AM
Anything you wish, as long as it's not misleading.

A few examples:
Deathmatch rulez us
Free to frag us
Android DM (US)
US gamers welcome
US FFA OpenArena
Frag-em-All (us)
Surplus fraggers us
Baseoa ffa us
Frag in the u.s.a.
Etc
Etc
Etc

By the way, if instantgib works well enough on Android (not sure about that), maybe one may setup a custom vote to enable/disable it, mentioning that in MOTD? I haven't yet checked if that breaks classic map rotation scripts (as changing gametype does, I recently learned, since q3a) or not.


Title: Re: Android port
Post by: pelya on June 29, 2016, 02:37:37 PM
I've renamed it to 'Surplus frags US'. I wanted to put there something about Trump's toupee and McDonalds, but it did not fit into 20 chars limit.

I nevr tried instagib on a phone, but I cannot imagine it being good, because it's purely a twitch-aim skill, and aiming is,hard on touchscreen.

All rockets might work, because you don't need to aim as much as dodge.

Edit: I've set up qscore statistics for that server: http://69.12.73.163/
What good statistics app would you advise, which does not require database engine? Qscore is very basic, pyqscore did not work at all for me.


Title: Re: Android port
Post by: Gig on July 02, 2016, 08:48:11 AM
About pyqscore, what about asking help in its dedicated thread? http://openarena.ws/board/index.php?topic=4151.0

PS: I added qscore to the list here: (DO NOT LINK) h t t p s : / / openarena . wikia . com/wiki/Servers#Server_statistics

PPS: About Android 6 issue, do you mean that the sd card permission would be asked every time the user launches the game? Isn't it possible to grant it at installation time? It is was only once after every update (to extract downloaded files), it would still be acceptable... but I can guess the issue would also regard writing q3config.cfg etc, right?


Title: Re: Android port
Post by: pelya on July 02, 2016, 09:52:05 AM
The permission is asked only once. If you reject it, OA will happily go to sourceforge.net server to download the data package for the second time. The permission is not needed for writing in app directory in Android/data on SD card, so config file will be fine.


Title: Re: Android port
Post by: Gig on July 02, 2016, 01:46:20 PM
Okay, then... is it already this way or another update is needed? Important thing is that the user is correctly informed about what's gonna happen ("if you answer no, the game will download some game data files again")... more important thing is that problems which break the game usability (such having outdated pk3s) are fixed quickly, because they could bring to one-star valutations on play store.


Title: Re: Android port
Post by: pelya on July 02, 2016, 01:50:52 PM
Yes, it's in the latest update. No, user is not informed, because I was lazy.


Title: Re: Android port
Post by: Gig on July 05, 2016, 04:08:23 AM
Hi! I downloaded the update...

... Uhm... strange, it looks like sometimes (hugh, the dreaded "sometimes" happening problems), when I shoot, it fires only once instead of firing continuously. I do use "tap to shoot" mode in firstperson.

About UPnP, it looks like your implementation does not work correcty with my router. I tried to enable it for all interfaces, and while it looks like it works for eMule (PC), it does not work for OpenArena (Android... I still see a red "LAN Only" line). Is there some CVAR to enable it, maybe?
Unfortunately, my router itself does not seem to offer logging about uPnP... Its UPnP port is set to TCP 5678.

Using "Condump" I exported OA console output (manually retyping here below from pc)... it does just say:
my external IP:44437
5 servers parsed (total 9)
CL_DetermineNatType_f: Error masterserver dpmaster.deathmask.net did not return our address, checking UPnP
CL_DetermineNatType_f: Error masterserver dpmaster.deathmask.net did not return our address, NAT is symmetric.


Title: Re: Android port
Post by: pelya on July 05, 2016, 06:20:20 AM
I've changed tap-to-shoot mode a bit - now when you tap one time, you shoot like before, but when you tap for a second time on the same spot, you stop shooting. I did it because it was not convenient to stop shooting by touching the screen in a different spot, or waiting one second with your finger off the screen.
It feels more convenient to me, however the problem now is when you tap multiple times (yeah, happens), you don't have any visual indication if you're shooting or not, until you fire a rocket into the nearest wall and suicide. Maybe I can do something with the crosshair shape, like with the railgun crosshair.
What do you think? Should I make this behavior configurable via an option?

No, UPnP should be automatic. I've tested it on my home router, and it seemed to work, however in the new update it stopped working for no reason. Maybe I messed up something in the code, I'll check this.

Edit: my hole punching masterserver was down, I've restarted it. Could you please test UPnP again?


Title: Re: Android port
Post by: Gig on July 06, 2016, 08:08:54 AM
Uhm... is your server also required for uPnP? I don't know when I will have the chance to do another test, it may take a few days.

About "new" tap to shoot, I have just tried again, and I have some problems adapting myself to it... I miss the old behaviour. I did not feel the old way as a problem*, however if you like more current one, you may keep both and provide some kind of small visual feedback to determine if you are "shooting".

About those little OpenGL problems we mentioned earlier, what about asking Fromhell for some tips? I suppose she knows OpenGL very well.


* Trying to say in other words: I would find "tap the same place again to stop shooting" especially useful in case the shooting button was a double tap on a fixed "right joystick", but considering that touching a different part of the screen stops firing and just re-creates the invisible virtual joystick without messing up your aim, that's enough for me. Because I do tend to tap more times in the same place to start shooting... and having to care of it's one or two or three taps is a bit unconformtable to me.


Title: Re: Android port
Post by: pelya on July 06, 2016, 08:24:01 AM
Yes, my server is required for UDP hole punching algorithm to work. After UPnP is activated, your router could be 'upgraded' from symmetric NAT to port restricted NAT, or to public IP / no NAT at all on OpenArena network port, depending on your internet provider.
If you will have port restricted NAT, you still need UDP hole punching to host or connect to hosts like you. If you end up with public IP, other hosts will connect to you directly, without using my server.

For new tap-to-shoot,  I'll make it configurable in settings.

About OpenGL, well, this requires time and effort to caych and fix all those minor graphical bugs, I'm not sure I'll do that. Also Fromhell knows PC OpenGL, and mobile GLES lacks some features, that's the main reason why those bugs are happening. I would rather fix my GLES2 renderer, then I can have all those nice flares and bloom effects that Fromhell added to PA, and integrate Cardboard VR SDK and have a proper barrel roll distortion.


Title: Re: Android port
Post by: Gig on July 06, 2016, 08:35:22 AM
About the graphical bugs, I can guess the machinegun marks on walls blending could be worth of taking a look. Not that the effect is sooo bad after all, but machinegun marks on walls affect any map and could be one of the first things a new player would see when playing for the first time, giving him a bad impression about the game.


Title: Re: Android port
Post by: Gig on July 08, 2016, 02:25:55 AM
Made another try with UPnP, but it looks like it's not working. Are your services running? Could you add some more debug infos in console output, maybe?

Also, I found a bug: if I use the button to enter console commands from menus (it looks like the bug does not happen in-game) and then, instead of inserting a command, I just press "back" physical button... the game acts like I pressed "back" many times, returning to main menu and exiting the game completely.


Title: Re: Android port
Post by: pelya on July 08, 2016, 04:48:42 AM
My services are running, so it looks like UPnP will not help on your setup (or my code is not working)

I'll fix the bug with Back bitton


Title: Re: Android port
Post by: Gig on July 08, 2016, 09:45:30 AM
Is there something more I could do to help debugging?


Title: Re: Android port
Post by: pelya on July 08, 2016, 09:54:40 AM
Not much.

Maybe visit local mcDonalds, and check on their WiFi. Quit and relaunch the game before checking.

Anyway, to adapt my code to some particular network setup, I need to be there, remote debuggign is pain.


Title: Re: Android port
Post by: Gig on July 08, 2016, 10:24:42 AM
A public wifi with upnp nat traversal enabled? Sounds strange.

By the way, since UPnP nat traversal is considered a potential security issue, maybe foreseeing a way for users to disable the option could be good. Just to avoid someone thinking that an app silently opening ports on the router may be malware.

However, are you really sure it would be impractical to make a command to export upnp-related packets to a text file or similar? I suppose the router should reply with some kind of error (e.g. unhautorized/syntax error/whatever).


Title: Re: Android port
Post by: pelya on July 08, 2016, 10:34:16 AM
Well, Skype does that without asking.

Yes, it's possible to dump upnp client logs into a file, I'll do this.


Title: Re: Android port
Post by: Gig on July 08, 2016, 10:54:50 AM
Also, I see there are some packet loggers for android which do not require root (due to using vpn android api)... maybe those may be useful, too?


Title: Re: Android port
Post by: pelya on July 08, 2016, 11:13:31 AM
I've tried tPacketCapture, and could not connect to any server when it was running.

By the way, I just connected to some server called XDDDDD, which was marked as NAT in the game, so I assume my NAT traversal code works.


Title: Re: Android port
Post by: Gig on July 08, 2016, 12:39:57 PM
While using Packet capture by grey shirts I was able to connect to a server.
But I was connected using 3g, haven't tried it via wifi yet.


Title: Re: Android port
Post by: Gig on July 09, 2016, 07:42:49 AM
I went to a McDonalds, and tried accessing their wifi. Unfortunately, it has got a captive portal which requires registering, and I did not have time and will to register.


Title: Re: Android port
Post by: pelya on July 09, 2016, 08:39:28 AM
Haha, yeah, I should have guessed public WiFi will be restricted all the way down.

On WiFi at our subway, they show you an ad on their captive portal, but no registration necessary.


Title: Re: Android port
Post by: Gig on July 10, 2016, 08:03:13 AM
I just sent you a mail with was I have been able to capture with those tools.


PS: I added a second mail with some xml files from the router.


Title: Re: Android port
Post by: Gig on July 11, 2016, 02:18:19 AM
A very little bug found: when you go to graphic settings menu, it says you are in lightmap mode even if you are in vertex mode.


Title: Re: Android port
Post by: Gig on August 28, 2016, 05:40:02 AM
Hello, after vacation I have wifi access again. I'm not still 100% operative (e.g. I will read maps-related threads, that I don't read since a few weeks, at the end of this week), however I may do some uPnP test for the Android port, if you can publish the update the the UPnP client debugger.

Considering many people will have to download 400 mb again, it would be good to include at least one other fix in the same release. What was in hold?
- Ability to disable double tap to jump?
- Ability to set previous tap to shoot behavior, or making it clearer if have the fire button pressed or not?
- Some way (I don't know how) to "center view" in gyroscope mode (after you changed your real life standing position)?
- The very small interface bug mentioned in the post above this one?
- Other I don't recall now?


Title: Re: Android port
Post by: pelya on August 31, 2016, 06:45:28 AM
Hi Gig. I still did not start working on the update, but I plan to include all features you mentioned, especially fixing the tap to shoot, plus camera control via joystick, which hopefully will be intuitive enough (or you disable it in options).

Maybe I'll get onto it in a week or two.


Title: Re: Android port
Post by: Gig on September 01, 2016, 12:29:51 AM
Okay.  :)


Title: Re: Android port
Post by: mindbeat on November 14, 2017, 03:57:56 AM
Hello!
I really love the Open Arena port to Android, And me and my brothers have made it to a Christmas tradition to play it with each other :)
Long story short,

I Found out that there is a VR mode inside, I tried it out, but it seems that I cant remove the touchscreen buttons, I tried to disable HUD trough console command, But the touchscreen icons are still there.

Thanks for any hint,

Best regards,
Dennis


Title: Re: Android port
Post by: Gig on November 14, 2017, 04:03:30 AM
IIRC, accessing to the SDL configuration menu at startup, there are some options to tweak the Android interface. One allows to place the buttons where you wish (but I don't suggest to try it, because IIRC you can't restore just them to the default layout, but you would need to reset all the SDL settings). Another one allows to set the transparency of the onscreen buttons. But I'm not sure, it's some time I don't try messing with those settings...


Title: Re: Android port
Post by: pelya on November 14, 2017, 04:46:01 AM
Connect the gamepad and flick the analog joystick, this will hide touchscreen controls.


Title: Re: Android port
Post by: Gig on January 18, 2018, 05:27:31 PM
Pelya, what about that update which should have fixed the "continous fire stops working" bug, added the ability to log UPnP client (for debugging nat) and IIRC an option to disable the "tap virtual joystick to jump" feature?

I was playing online against anorher human player, but the "stops firing" bug was REALLY annoying... I'm using firstperson with "tap to shoot" mode.


Title: Re: Android port
Post by: pelya on January 24, 2018, 11:13:12 AM
Sorry, I keep postponing the update. Maybe I'll do it in two weeks or so.
To be honest, I kind of expected Android version to silently die.
There are currently 3,193 active installs, according to Google Play console, I remember when this number was around 4000 several years ago.


Title: Re: Android port
Post by: Gig on January 24, 2018, 03:33:13 PM
It's hard to have a game growing without updates (this is in general, as example it may also apply to OA as a whole)... about the android version I find that "stop firing" bug quite annoying, I think playing would be more pleasant without it.
Well, my phone is quite old and so it will never have an excellent framerate (the android sdl tech limit of not being able to stretch a lower resolution is still a problem for people like me with older hardware), however having the game always firing when I wish would make it more suitable for me. And by extension, more pleasant also for others.


Title: Re: Android port
Post by: ruthan on June 28, 2018, 12:42:47 PM
Hello,
i have tried Android port on multiple Android x86 machines and versions of Android x86 with Intel HD graphics, game always crashes in moment when select the Arena a start the game.. Android Quake3 port - QIII4A its running fine.


Title: Re: Android port
Post by: Gig on March 12, 2019, 03:45:41 AM
Hi Pelya! It's some months I wanted to tell you about some things.

I tested the game on a device which does not have the physical (touch) "back" and "menu" buttons (most phones nowadays don't have them).
What's the name of the Android feature which requires you to swipe from the edge in order to make the virtual buttons (back/home/recent apps) appear, semi-transparent? "Immersive mode" maybe? I don't find myself comfortable with those phones in general, but that's how most are nowadays...

About their usage with OpenArena, these phones do make it a bit annoying accessing the ESC menu (back) (but that's not a real problem), and most importantly they don't have a "menu" button, so you end up not having an "use item" button. So, how to use portable medkit/personal teleporter/kamikaze/invulnerability?
The "remap on-screen controls" (in the initial "change device configuration") doesn't seem to foresee a "Button 7 - Use item" a the moment. Could you add it? Or do you think that it may be possible to tell Android to add "menu" button to the "navigation buttons bar", so to at least have some way to "use item" (although in that case that may take a bit more time than what would be optimal for item usage)?

I see that in the startup "change device configuration" you can access "video settings" menu and uncheck the "hide system navigation buttons" option, which may seem handy as those buttons are always shown that way (so you have "back" (ESC menu) easy to reach), but then you risk to hit the "home" and "recent apps" buttons by error, especially because they hide (note: the bar isn't transparent in this case) the "zoom" and "jump" buttons, which are still clickable however.

PS: I'm still waiting for a version with "UPnP debug option", to find out the reason why UPnP doesn't work with my router.

PPS: In the "remap on-screen controls", I see there is "Button 4 - Quick rotate"... but I don't see a such button while in-game. Am I missing something?

PPPS: If I enter /~ to pull down the standard console in order to see some more of its history (and its colors), I can't use it to enter commands, as it looks like it doesn't recognize the "enter" at the end of the command. Fortunately, it recognizes another /~ and closes the console, so I can continue to use it from your simplified version of it...

PPPPS: This is not for Pelya, this is for anyone wanting to disable the "double tap joystick to jump" feature:
To disable joystick jump, open chat box during the game (top-left button), and enter this:
Code:
/set j_androidJoystickJumpTime 0
I'll add this to settings menu in the next update. If there ever will be an update, because I'm lazy.



Title: Re: Android port
Post by: pelya on March 29, 2019, 02:27:28 PM
Tap the medkit/teleporter/kamikaze icon on the top-right corner of the screen to use it.
Sorry about UPnP version, I forgot about it. I remember there was an app to configure your router uPNP function using your phone, I'll check if it works on my home router.
Quick rotate button is only enabled if you are using 'floating crosshair' aiming, it's a button above joystick that will rotate camera to the direction where you were running, so you don't need to touch screen border with your finger and wait until camera fully rotates. I am planning to enable this button for other aiming modes too, because it's more convenient than swiping the screen.
Yeah, the console and Android text input do not play very well together, I don't think I'll ever fix this.

I have also noticed that zoom button is hopelessly broken on my new 64-bit phone. I don't know when I'll gather enough willpower to sit and fix all these bugs.

BTW OpenArena got ported to Vulkan API, I don't know if it will be of any use for my Android version though: https://github.com/suijingfeng/vkOpenArena


Title: Re: Android port
Post by: Gig on March 30, 2019, 03:16:15 PM
Tap the medkit/teleporter/kamikaze icon on the top-right corner of the screen to use it.
Thank you! I didn't think about it, but totally makes sense. In case it isn't already mentioned there, mention it in app description (I haven't checked) when you will have the chance.


Title: Re: Android port
Post by: pelya on April 01, 2019, 06:07:16 AM
This UPnP app (https://play.google.com/store/apps/details?id=net.sbbi.upnp.droid) works on my phone and with my router (and has no ads), so if built-in OpenArena upnp mapper does not work, you can try to use this app to map port 27960, you'll also know if your router has upnp enabled.


Title: Re: Android port
Post by: Gig on May 09, 2019, 02:35:38 PM
Just for the record, today I hard reset-ed my phone... and while Play Store told that OpenArena was large so it would have only downloaded it under wifi (and I was under wifi), after downloading it looked like only 16 MB, and at first startup it looked like it downloaded stuff with its download engine...
... but I was busy doing other things, I didn't actually check downloading times of the two phases...


Title: Re: Android port
Post by: Gig on January 22, 2021, 02:54:07 PM
Pelya, are you still around?
Being short of space in an Huawei P8 Lite 2017 (Android 8), I realized that OpenArena data pk3 files were stored in the internal storage, despite the OpenArena "Change device configuration" menu saying the SD Card was selected.
I tried clearing the App's data from Android settings, and at startup, OpenArena says "No need to download" and immediately quits. I guess I'll uninstall and reinstall... anyway, any idea why the data were in internal memory despite your menu saying the opposite?

Note: that phone has got an "archive settings -> default location: internal storage" setting. Not completely sure about what changing it to "sd card" would actually imply: it asks for a confirmation saying "Phone is crypted. Be sure the new archive positision is safe (secure?) before switching positions"... IDK...