Wednesday, 30 April 2014

Freeablo is that Diablo engine remake we've been wishing for, is currenly looking for contributors (and general ravings about Diablo. In fact, mostly that)

Freeablo engine in its early stages
Who doesn't love the original Diablo? When it was first released in 1996, this game set a notable landmark for making the RPG genre more accessible to a broader audience, while still keeping many gameplay aspects of classic Rogue-derived RPGs, that kept the game fresh and unique even after being completed several times. This bridge between classic and modern aspects combined with an incredible attention to detail, a uniquely crafted atmosphere that still gives me the creeps, and a gameplay pacing and length that is just the right balance between level progression and grinding, has helped making Diablo one of my all time favourite games. Well, that and Battlenet, of course, we can never forget how Diablo was one of the first to make it so easy to just go dungeon crawling with a couple of friends online.

There is, however, one thing that I don't like about Diablo. One thing that annoyed me all over these years of repeated runs and occasional multiplayer meetups. And that is how Blizzard itself decided to neglect its maintenance and compatibility completely and practically drop all active support for it, despite keeping the Battlenet servers online. Yes, you will have a tough time trying to buy a fresh copy of this game nowadays, because Blizzard cares so much about their legacy games they don't even sell 'em anymore in their official store. But even if there still are plenty of used copies available online for cheap, running the game on modern systems can be a whole a new quest, given that the last patch is dated from 2000, which means no performance maintenance, no improved graphics compatibility, in fact, not even additional screen resolutions, and certainly no stability updates whatsoever. 

The first Cathedral levels loaded and randomly generated in Freeablo
As a matter of fact, Blizzard has a whole tradition of being disrespectful to legacy fans. They refuse to let resellers touch their games (physical Diablo II and Starcraft copies still go by $25 nowadays, with no Steam or GOG versions in sight), they frequently discourage and hamper any type of mod support or mod attempts, other than whatever's produced under their little walled garden editor-type programs and, obviously, they never ever released the source code of any of their games, just to make sure us, the plebeian fans, would never touch their precious abandoned heritage with our filthy paws.

Luckily, this might just be about to change, with the coming of a bold, new engine remake project most aptly named Freeablo. This project aims to rebuild and expand upon the original Diablo engine, keeping it fully portable and compatible with modern systems, as well as making it adaptable and moddable for anyone willing to modify the game. All of this while still paying due respect to Blizzard and requiring the original game files in order to run the game. Now isn't this nice? 

As of the current 0.1 release, there is still much to be done, which is why the project is open to contributors of all sorts. Hopefully, with enough time and effort, we can all free Diablo one day from the clutches of proprietary software and greedy corporate execs who are still stuck in a 90s mentality on how to commercialize and support video games.

Code License: GPLv3

Assets License: Relies on original proprietary data files

Official Website
Source Code (Github)

Forex Bank Prediction resources

Whether you are a long term trader or a scalper you will always be curious about and would like to know what are the big players in the Forex market doing. What are their positions? Fortunately, certain websites do provide that kind of information. To be more precise I am talking about the positions that are held by the big banks and big hedge funds. 

The best websites with bank positions, or in my opinion, the most useful ones are:

1. eFXnews - it is Boston based financial media agency covering global FX markets. It provides the positions held my the biggest players in the market. Highly recommendable one.

2. PLTfx - it is FX trading advisory and Funds Management. Another great resource that provides bank Forex positions. It requires login.

3. Forex Quebec - it is global Forex trading portal that provides the bank positions under its bank forecasts section. It is a good resource though it is not providing the forecasts on daily basis.

4. Dukascopy TV - a Forex broker that is providing the information in video format on part-time basis.

5. Forex Street - another global Forex trading portal. It provides many positrons of a slightly less relevant players in the market. 

In short, it is always useful to know what are the biggest players in the market predicting before you enter your position. 

Saturday, 26 April 2014

Help visitors who arrive at your blog via a link to a deleted post

If you sometimes delete posts from your blog, then it's a good idea to provide some help to people who who arrive at your blog via links to those posts.

(Even if you don't have any links to those posts, it's likely that a search-engine somewhere will have some - and other people may have bookmarked or shared them, too.)

There are two options for doing this:



Post-specific redirects

Use these if you want to re-direct visitors who come to a particular previous post:

Go into Settings > Search Preferences, click Edit beside Custom Redirects.


Click New Redirect, to create instructions for what to do if a visitor tries to navigate to a specific post.

Put the address of the post that you want to make a re-direct for into the From field.

Put the address of the post that you want to visitors to be taken to into the To field.
For both addresses, the part you need to enter is the URL of the post from the first backslash on.  
Do not put in your blog-address
Do include the date-part of the URL and the backslash.
eg
for    http://blogger-hints-and-tips.blogspot.com/2013/01/changing-a-label-value-for-all-posts.html
use   /2013/01/changing-a-label-value-for-all-posts.html

Tick the Permanent check-box.

Click Save.

Click Save Changes.   (Yes, you need to do both Saves)


A generic page-not-found message

Use this if you do not want to set up post-specific re-directs, or if you cannot remember the URL of your deleted posts.

Go into Settings > Search Preferences, and edit the Custom Page Not Found option.

Put in some text welcoming the visitor, explaining that the page they were looking for is no longer available, and suggesting other places that they could try.

 This text can include links to other posts, so long as you hand-code them. (You might like to get code for this using the post editor).

Adding an RSS feed icon to your blog, using Feedburner

Feedburner's chicklets are used to add the standard "orange radar" button to your blog.  This lets readers to subscribe the RSS feed of your choice.   The information is targeted to Blogger users, but most of it applies to anyone who uses Feedburner.


What is a Chicklet, and why you need one:

Previously I've explained how to remove the (ugly and confusing) "Subscribe to Posts (atom)" link from your blog, and why RSS / Subscribe to Posts is important to your blog and how to create a Feedburner feed for it.

But an RSS feed is useless unless people subscribe to it.  So as well as making the feed, you also need to put something in your blog that lets your readers sign up for it.

A standard option for this is the orange square with "radar" markings on it, which many people call a "chicklet" (since it lets your viewer - the chicken? - have access to the feed you are providing).

Feedburner also has options for:
  • Using a custom icon from popular web aggregators
    I'm not sure that this is a great idea, because you don't know what feed-reader software your readers actually use, and the whole point of a feed is that you don't dictate how people see your blog.
  • Using an icon that promotes Feedburner.  This cute, but I've never seen anyone use it.

How to add a chicklet to your blog:


Log in to Feedburner, using the Google account that owns the feed.

Click on the name of the feed you want to provide a subscription tool for.

Choose the Publicize tab.

Choose the Chicklet Chooser option, from the left navigation bar.

Choose one of the options shown:  the default one is the standard-size RSS-radar-button.

Scroll to the bottom of the screen and either
  • Copy the HTML that is shown, and add it to your blog in the same way that you would add any other 3rd party HTML,

    OR  (note:  there have been some reports that the option below doesn't work any longer, as Blogger has changed but tools like Feedburner have not help up)
  • Choose Blogger from the drop down list beside "use as a widget in", and click Go

    This takes you to a Blogger screen where you can choose which blog you want to add the gadget to (if your current login has more than one), and what title to use for it. 

    When this is done, click Add Widget

    This takes you to the Design > Layout tab, where you can drag-and-drop the widget to wherever you want it.  
    (When I tried it just now, instead of the layout screen I got a "bad request" message.  However pressing Save and then View Blog brought up the blog with the gadget showing, and I was able to go back and edit the layout later on).


What your readers see:

Your readers will see an item, wherever you put it, that looks like this:

or something similar, depending on what option you chose from the Chicklet Chooser screen.

When someone clicks on one of these items, they are taken to either a screen where they choose which feed-reader software to add your site to (if you've used the first option), or to the specific feed-reader software.


Customising the widget code:

If you use the generic RSS button, then you may want to customise the widget code slightly:  It looks ugly not to have a space between the picture and the word "Subscribe" - and it's good to have the phrase "RSS" on the screen because that'ss what RSS-savvy people search for when they're looking at a website and want to find the subscribe option.  I also prefer if the subscribe action opens in a new tab/window, rather than taking the reader away from my blog.

This is quite easy to do, if you put a few line breaks in so you can see that
  • the code is actually two separate link statements
  • the first one has an image (the orange "radar bars" that it takes from Feedburner)
  • the second is a text link
  • both of them link to the RSS feed address

So it's quite easy to add a couple of extra spaces (shown as   ), change the text as I've done below, and add   target="_blank"   to both of the links
<a href="http://feeds.feedburner.com/Blogger-hints-and-tips" rel="alternate" type="application/rss+xml" target="_blank">
<img src="http://www.feedburner.com/fb/images/pub/feed-icon32x32.png" alt="" style="vertical-align:middle;border:0"/>
</a>

&nbsp; &nbsp; &nbsp;

<a href="http://feeds.feedburner.com/Blogger-hints-and-tips" rel="alternate" type="application/rss+xml" target="_blank">

Subscribe via RSS

</a>

I generally also put the option to subscribe to my blog by email and the Feedburner FeedCount item (which shows the number of subscribers) in the same area, to give people options, and to encourage them to subscribe.



Related Articles:

Using Feedburner to give your blog a Subscribe by Email option

Adding 3rd party HTML to your blog

Why RSS / Subscribe to Posts is important to your blog

How to create a Feedburner feed for your blog

Friday, 25 April 2014

Display Google Map using API V2 in android

Displaying Google Map in android using the API version 1 is deprecated now. Google introduce a lot of changes in displaying Google Map using API version 2. In this post i demonstrate how to display the Google Map using API Version 2.
Ads By Google



Step 1:
Install the Google Play Service SDK 
For displaying Map using API V2, you need the Google Play Services. So first step is to open your Android SDK manager and install the Google Play Services.

Step 2:
Add the Google Play Service as a library project into your android work-space. 
After the successful installation of Google Play Service SDK, you can find out the Google play service library project on the following location in your android SDK folder. 
                                           sdk-->Extras-->Google
Import the Google Play Services as a library project into the work-space. Don't forget to choose the options for copy the project into workspace. 
Step 3:
Add the Google play library project into your android project. 
Now you can add google play service-libraries into your project. Right click your project and choose its properties and choose the android option and click add button at the bottom of  the window. 
Step 4:
Generate the SHA-1 fingerprint Using the Java keytool. 
You need to generate the SHA-1 fingerprint using java keytool for obtaining the Map API key. Open your command prompt and type the following command. 
 keytool -list -v -keystore "%USERPROFILE%\.android\debug.keystore" -alias androiddebugkey -storepass android -keypass android  
After type the above command you got the certificates figerprints. Copy the SHA-1 fingerprints.

Step 5:
Obtain the Google Map API Key using the SHA-1 Fingerprint and your application package name from the Google console. 
Login into Google console  and at the left corner of the page choose the API's under API's & auth option. Now search for Google Maps Android API V2 and change its status from off to on
Now click Credentials at the left side of the page and click the CREATE NEW KEY button. Choose Android Key option from the dialog window. Now insert your SHA-1 fingerprint and your application package name into the text area of the newly generated dialog window and click create. Now you can see the newly created API KEY for android at the top of the web page. Copy that key. 

Step 6:
Specify the Google Play Service versions in the Manifest file.
Open your android Manifest file and add new Xml tag called meta-data between the Application tag. Specify your API Key as the value for the meta-data. 
 <meta-data  
android:name="com.google.android.maps.v2.API_KEY"
android:value="Enter your API Key Here">
</meta-data>

Step 7:
Add the required permissions in manifest file
We need to specify some permissions in manifest file  for displaying the Google Map. Following are the permissions and its usage. 

android.permission.INTERNET = "used to connect to the Google Map Servers for downloading the map tiles "
android.permission.ACCESS_NETWORK_STATE= "used by the API to check the status of the connection for downloading the data"
com.google.android.providers.gsf.permission.READ_GSERVICES = "Used by the API to access Google web based services".
android.permission.WRITE_EXTERNAL_STORAGE = "Used by the API to save the Map tile data into the external storage".
android.permission.ACCESS_COARSE_LOCATION = "Used by the API to access the WiFi or mobile data to find out the device current location".
android.permission.ACCESS_FINE_LOCATION = "Used by the API to access GPS for finding the current location ".
 <uses-permission android:name="android.permission.INTERNET"/>  
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES"/>
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>

Step 8:
Specify the OpenGL ES version in manifest. 
The google Map API V2 uses the OpenGL ES version 2 for rendering the Map on devices. 
  <uses-feature  
android:glEsVersion="0x00020000"
android:required="true"
/>

Step 9:
Add a fragment to the activity-main.xml file for display Map
 <?xml version="1.0" encoding="utf-8"?>  
<fragment xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:name="com.google.android.gms.maps.MapFragment"/>

Since Google Map uses the Google play services, it is not possible to test the Google map app in an android virtual device. For testing this app you need to install the .apk file in a real device.