End of the year and end of BevNav

I haven’t blogged in the last two months and there’s a good reason. In that time I have got to where I wanted with BevNav and all I need to do was put the database on my portfolio website server and also put the PHP pages on there to pull the data down. When I did this however I found out the hard way that the Windows hosting I have doesn’t work with PHP, who knew? I sure didn’t and that caused me a lot of pain because my websites in ASP and there for need the Windows hosting.

with that in mind I have attempted to translate my website from ASP based to completely HTML. However this has not worked 100%. Unfortunately there are several animations which do not play anymore and a few sections that do not work. Therefore I have decided for now to leave it as is and just add a page on my portfolio about BevNav and upload some screenshots of it working. After and during the Christmas break I may take some more time to get it work and potentially change my hosting to a Linux based package.

Until then, here are some screenshots of BevNav working, enjoy:

Now that it’s finished I can reflect on how well the project has gone. and it’s been rather enjoyable. Working on Android is always a fun little challenge as I don’t use that code very often and with that can come a lot of stress, however it’s always great when you see the results of the labour. For such a small project, it is a bit annoying it took so long to do, but that is more down to my commitment to want to do side projects outside of my real work. I also found Google Map (something I had not touched before), wonderful to work with and if there was another time when I had to or wanted to work with it again, I definitely would do so.

So what’s next? Well potentially two things, one is a games project and the other is a software project. The games project is to be a dodgems (bumper cars) type game, which I want to make in Unity and it’ll be for PC.

Now the other project is just a software based one because I work as a software developer in a games company and I want to excel. There’s a few things I want to get to know more, one being Model View – View Model (MVVM) and the other is to just to keep upgrading my skills. As this is something I am going to be doing to aid my work real life job, I am intending on working on it more often than I have with BevNav.

Therefore the majority of my time is going to spent on that, more than the dodgems games, but I would like to get that started also.

As well as the programming I will try to blog a bit more…TRY HAHA.

Happy Christmas and New Year everybody!

New Popups to Show Details

So in the last few weeks I have been finishing up the cleaning of my code because, as  I mentioned in the previous blog, after returning to the app I noticed I had fallen in to some terrible habits and therefore felt before doing anything I needed to do a ‘clean up’ asap so I was happy with it. Now I am happy with it and feel it’s a lot more readable and efficient. However I am sure there will come a time when I look at a part of the code I haven’t looked at in some time and I’ll think ‘Damn! This is terrible!’

After that I moved on to working on the pubs details page. This would open up when the user clicks on the pubs icon on the map and it will show a much more detailed view of the pubs offers (the main featured one and then a list of any other offer they might want to show). It will also show their address and an image of the pub. This started life off as a new activity that would take the user away from the google map activity. However when I had finished it and had pulled all of the data about the pub to the details page, I realized how empty it looked and by gawd it looked really empty.

With this in mind I made a choice to have the details open up in a ‘popup’ within the google maps activity. This looks a lot cleaner in my opinion and it also means there isn’t a lot off empty space all over the page. Another major advantage to this is that a new feature to the google maps activity is that when you click on a marker two little buttons appear that either send you to the location in google maps itself, or the other button sends you to google maps but to the directions page. The latter of these features especially is awesome and I’m glad google implemented this and also saved me from a bigger issue which if I had stayed with the separate activity, I wanted to add the ability to go to google maps and let the user get directions. So having the pop up means I can keep it compact and cleaner but also I get to utilize the buttons that google have already added in.

Lastly I also have changed the ‘search town’ list’s design, which was very empty before hand. Now the text has a lot more padding around it and therefore the text does not feel all quashed together. I have also added line separators between each town name and I have also added a background to the list. Yes it’s white but before it was transparent and you could see through to the map and to me looked bad because the text appeared to just hover and I didn’t like it. At least now with a white background, the list looks separate from the rest of the activity and looks more professional, well at least in my mind it does haha.

So what’s on the agenda next, well first its pull through the correct image each pub, because at the moment it’s just an image place holder. Then after that it’s to make a default icon so that if there was a pub added but didn’t have any ‘featured’ offers on at the moment then at least it would still show the pub, but it wouldn’t make out that they have an offer on. Then the next major one is to add a ‘remove’ filter feature, so that if the user searches for a certain city/town (which will filter the map to only show pubs from that town), then at least they can remove it and show all because at the moment they can’t, they have to close the app entirely. I know that’s terrible Nick what are you doing!! haha.

Also for this blog I will add some images at some point so that there is some point of reference to what I am jabbering on about.

The return, the clean and the focus

It’s been a while blog world…..a long while. The last half a year has been rather busy for me out side of my side projects and have been rather lazy with them/not doing anything to them. One project I was doing with friends seemed to just disintegrate and another my friend gave up on the idea. The third which was just one I was doing by myself was good, but I just lost interest it in. At the time of doing all three I seemed to be more focused on one of the others than I was on the one I was currently working on, so as you can see it didn’t work out.

Anyway, so what is it I am doing now? Well this is me coming back and I am going to be carrying on with Bevnav. It’s the more interesting one at of the three and one I can complete by myself (even though yes I did start this with a friend). I have taken the other projects off this blog until further notice.

But why Bevnav, I thought you wanted to make games?” I hear you cry, well yes that is what brought me to the dance and is my main focus. However I was a lot further in to this project than the others and have a lot more ideas and plans for it, therefore it would be a bigger loss and waste of my previous time, to not complete it. I also am now a SharePoint Developer at my company and for the time being, a software based project might help me a bit more in my job than a games based one. I am aiming to get this complete by December and think with all the focus I can give to it (and with how much longer is left in the year) I will get it done by then. As with Attack of the RGB, this isn’t a publish type of thing and get 100’s of people to use it. This is simply an app that I am creating to show what I can do.

After Bevnav It will be back to the drawing board and I will get back in to game development type side projects. I may use one of the previously started projects or I may start something completely new. All I know is, is that is a rather long way off from today and will think about that more when the time comes. Until then it’s full steam ahead Bevnav!!

So all this chat about focus, what have you actually done ?” Good question well when I first came back to it I had a good look through the code to see what I had done and where I should go next. In doing this I became a little disappointed in myself as I realised how bad the code was and how inefficient it was, it also looked like an ameteur had written it and that’s not what I want to be doing, especially considering this is meant to be a portfolio piece, I have no idea what I was thinking back then. One example is all the data I pulled through from the database I was just saving to a big long list with of a string for each of the tables columns (WOW nick that’s terrible), so to fix this I just made some simple classes and saved them to that. This also made it so much easier to use the data later, instead of having to write a big line of code access the string for the table column, then cutting to get the one I wanted.

After the initial clean up I then started to like the idea of adding a Navigation drawer to the app, so I spent a while learning about them and then I went onto adding one to the app. The problem is, even though I wanted one (and still do really), I didn’t know what I would be putting in the drawer and it became more of a feature creep. So I have taken it out now, but if I can think of some way of using it then I’ll put it straight back in.

Next on my plan was to create the ‘profile’ page of each bar, which would display the name, address and more importantly the ‘featured’ offer as well as any other offers they wish to show. I created a new activity for the profile and implemented a bundle to pass all the data through from the main activity to the profile page. Well that’s now all there, the next thing for me to do is make the page look ‘pretty’ as it is currently a blank activity with text all over it, therefore I am currently making some drawings for it.

Speaking of whats next I created a TODO list for this project of things that need doing before I will consider this project complete. Obviously there’s probably somethings I’ve over looked or will naturally creep in but this is the foundation:

  • Make classes for the bars/offers/locations – DONE
  • Clean up code – On going
  • Create pub profile page
    • Change the ‘Offer type and details’ to ‘Featured Offer’
    • Add a listview for the pubs ‘other’ offers
    • Create new design layout for the page
      • Create a design layout for the listview also
  • Add a ‘remove’ search filter option for when the user has searched for a ceratin location and then wist to remove that filter
  • Give the listview of the locations search list a better design
  • Move the server to my website, as it’s currently on my laptop
  • Add a ‘Favourites’ feature to either save favourite bars or favourite offers or both
  • OPTIONAL – Create a home screen widget
  • OPTIONAL – Navigation drawer

Update

It’s been a few weeks now and unfortunately I have neglected my projects due to a busy life. However I recently joined forces with some friends to work on another game project for our portfolios. Therefore I will be dropping the Project Anarchy project for the time being and concentrate on this one along with the BavNav project of mine.

This project is an Tower Defense with some RTS style elements thrown in and it will be created in Unity. We all decided Unity due to all having had experience with it and it being very good to use make great games.

I look forward to the fun this project brings, I will be one of two coders on this project and I will try to blog what I can with what I am doing. I will also make time to work on BevNav as that again is working with someone on that project

Choose location? More like choose your error part 2

Hahaha well thought it was over hey, well guess what the next step also caused more errors.

So this started with trying to get the ID from the database of the item that the user clicked on the list. Now i thought this would be simple, get the item clicked, its position and then get its ID. Well that was silly, the ID was the ID which represented where it was in the list. What a doughnut, ey? Well I soon learnt and grabbed it from actual array list that was holding its details and then by using the position on the list, I grab the ID that belongs to the selected item. Not that tricky but soon learnt.

Next issue was the filtering down of the bars shown on the map after the user had chosen a town, this I thought was easy, save the chosen location ID and compare it to all the LocationID’s that the bars belong to and then only show them. However this became a bit of an issue because without realizing it I was comparing it to the bars actual ID and not the LocationID in which it was associated to, simple mistake but one that was quickly fixed.

Next step was filtering down the list when a user types in the searchview so that its easier for them to find, which came with it’s own set off problems, main one being that ultimate question of of the hell do I do that? Well he’s a good (but long winded) answer. First my initial problem was that in other parts of the code I has made a “searchItem” variable of the MenuItem class which works well for the ‘setOnActionExpandListener’ which is needed for expanding and closing the search widget in the action bar. So with this in mid I searched through all the different features that the MenuItem class could do in hope to do some kind of filter. That didn’t work and then I searched gogle for it and amongst a few searches I realized that the issue was the MenuItem is generic and isn’t just for the search widget (yes I should have guessed from the start…but…well I didn’t and I soon did). Therefore to fix this I create a new variable called ‘searchView’ of (you guessed it) the SearchView kind and found the ‘setOnQueryTextListener’ and my day was saved. By then filtering the adapter to the text in the searchview I got it fully working.

The issue I have found now though is that when I refresh the map with the chosen location it still loads where the user is and they have to zoom out to find the city and bars aware abouts. Therefore my next plan is to do a check on whether this load is with no location chosen or with and if there isn’t one I’ll load it normally, however if there is, then I’ll load it in the area requested.

This can wait til next time however as I feel a nice little break is required 😛

Choose location? More like choose your error

So recently I have been attempting to create the option for the user to choose the location of where they wish to see deals from, one so that the app doesn’t show every single bar but also the user might be gooing on holiday or a day trip/night out to another town/city and want to pre plan. This will be done by typing in the action bar search view and then from the list, select the town they want. Sounds easy right, well……

So the initial part was easy, first of all I’ve got to grab all of the locations from the database and pull them down to the app, Okay that bit was easy as I’ve done it before. The hard bit was finding out how to create a searchview with a listview and theres not one tutorial online I could find that has the search being done with the actionbar. Why the hell is this not a thing? Therefore I’ve found a tutorial where they used a normal searchview on the apps page and I’m slowly manipulating this to work with the action bar.

First a lot of errors were due to not knowing if this code would do so or not, which as you could imagine lead to lots of messing around and changing/chopping up code. I formatted things to my way of coding which doesn’t always work as I hadn’t done this before so I soon had to learn a new way of doing some things. So after screaming at the code why it didn’t work, it did eventually and that’s when the next one appeared.

Another error was that when I was using the on click code from the listviewadapter t even just refresh the map it caused a Null error amongst others. This though was thank fully fixed by having learnt that a similar bit of code can be used on the main activity itself, it took longer than I would like to admit when it came to finally finding the fix, however it got fixed and I’m glad it was.

There were a few more to but luckily they got fixed and now to move onto the next part which is when an item is clicked it will refresh the map and filter it down to only the bars in that town

Minor Update

Today I’ve only done a small piece of work on BevNav and this small update is that now the application pulls more data from the database, this time the offer available and then searches through and see’s which one is connected to which bar. With this it allows for the correct icon to be shown on the map so that users will be able to tell which offer the bar is giving, meaning they can ignore the others if they wish.

This have given me an idea though, maybe I should add some functionality to allow the user to filter out which offer types they don’t want to see on the screen.

Next for me with this project is to pull through all the different cities throughout the country so that the user can search for which area they wish to view and this will then only show the ones they wish to see, plus it means that less data will be pulled through to the app.

New Projects New Blog

Hi There,

As you can tell by the title I am setting up a new blog as my previous project Attack Of The RGB  has come to and end/holt until I can publish it, you can view any blogs I had done here. With this comes the start of new projects and this time I have two, one I can talk about and another I will talk about but not in great detail.

The first project is going to be built in Project Anarchy and is going to be a kind of air hokey style game, with a few twists. I will be planning on building this for Android an iOS version might happen but while I don’t have an iPhone it most likely won’t. The second project is going to be an Android app (not a game this time) and built natively for it. Both projects I will look at publishing when complete and hopefully both will be great portfolio pieces or more 😉 There was a project idea I had from watching the Us and Game Industry documentary, but after researching the concept and similar ideas I’ve come to the conclusion it would need to either be a console game or a pc game that relied on controllers. Not just that it would be too big for now, so I’m passing on that at the moment and will do that in the vast future.

So to Project Anarchy, I set that up yesterday and have been playing with it today. I didn’t realize that Havok had made a tutorial and I’m glad they did. Zero to Hero is brilliant, I’ve learnt a fair amount in such a small time and have a great working game from that tutorial. As for the setup It was rather easy and even though I say that, I still managed to do mess up a a setting for the location of the Android NDK. So testing it on the phone was a bit of a hassle 😛 With the knowledge I learnt from that tutorial and get to setting up the level in design of how I think it should be, or to what it should be for the time being while I develop the game. Then it will be a task to manipulate the code of what I’ve learnt to make it work the way I want. There’s no name for this as of yet so I’m giving it a codename of Anarchy Bash….yeaaaaah I’m that creative ha. With Project Anarchy I will be using LUA script for the first time, this I am very excited about about and I am sure I’ll get on fine with it, one thing though I will need to find some more tutorials for it.

The second project is already up and started, I have worked a fair amount on it the past week. I updated Eclipse and the SDK but don’t think I’ll be using the Android L preview, I’ll wait until L is fully out before I do anything with that. I’m using Google Maps API with this project and have found it rather easy to set up, Google has a brilliant developer website with help. I now need to set up a database with some fake data so I can manipulate it and bring it into the app…this will sure be fun.

Busy times ahead, feels like uni all over again. This blog I plan to keep open about all my projects and thoughts hence keeping the name more generic, rather than the name not being a based around a project.