Here’s a quick way to switch between Windows desktop resolutions using a batch file and an executable file. I needed to do this in order to have a better overview in the game Age of Empires HD (on Steam). Let me visually show you what I mean. Have a look at the screenshots below, you can clearly see a more broader view as you up the resolution.
For some reason the viewing distance is different to the one in the original game.. A few years ago I tested to see if there is a difference in resolution compared to the old Age of Empires and there is so they have in fact made your viewing distance closer. As someone who’s played Age of Empires for a long time this was a problem for me. Now in the original you could change your resolution so simply enabling DSR Factor via your graphics control panel and changing the resolution in-game could resolve this issue for me, in this version the ability is not there (I assume poor development). Anyway, you will first need to enable DSR Factor, I currently prefer x1.75 as shown below.
Then you’ll need to download the file below. Tweak the resolution settings for what you prefer and run the game. If you have the option you can play around with the smoothing, essentially it’s anti-aliasing between the pixels so it doesn’t look pixelated due to the difference of your monitors resolution capability and what’s being scaled.
Now I was under the impression that a batch file can’t actually do this (on its own), I still think this is the case, but with simple help from a file you can still achieve it. The benefits of this way is you can change your preferred resolutions and simply run the batch file with as less clicking as possible, while an executable would require a bit of extra clicks.
At the time I could not find the source code for QRes (and I downloaded it from a separate site) so I did a virus scan on it – here’s the result. Secondly I used Sandboxie and launched the file in a sandboxed environment and looked at what – if any – files were executed along with it.. It left zero trace and the file size also indicates to me it’s pretty simple.
Now here comes the actual batch file.
QRes.exe /X 1920 /Y 1080
Yup, that’s it. So in the folder there is the ‘QRes.exe’ file, then there’s ‘RC 1920×1080.bat’ and ‘RC 2560×1440.bat’ files which I run to switch between the resolutions. All these files must be in the same folder for it to work and by the size of the QRes.exe file it looks to just simply run based on the resolution that’s provided in the batch.
I’ve not posted on here for a while now, I guess it’s been due to not having enough time and energy to do so, but I thought I’d write about my recent trip to Cape Verde and the experiences that I think might come in handy.
It begins as always with arranging your flight, your accommodation, then packing your bag and definitely a rucksack too if your luggage limits permits. Oh and I would recommend a Drawstring backpack or anything similar for the beach. Depending on the climate you’re travelling of course you’ll need the essentials, in my case sun-cream, sandals or flip-flops, sunglasses and a hat both depending on your style I guess and as usual I left all my packing to the last moments thus was in a bit of a rush.
I attempted to buy a hat that I liked, I don’t know where I put all my previous hats but I couldn’t find any hanging around. I ended up borrowing one that looked like something a crocodile hunter would wear, not really suitable for an island relaxation feel, but it would do, at least for keeping the sun out of my eyes when laying on a sunbed.
I would recommend having decent sunglasses that you’re happy with, I wouldn’t rush it so it’s worth spending a little extra and getting one that will last before your holiday is near. Something you’ll be happy with in all kind of sunny days. Being in a rush I opted for borrowing one as i couldn’t choose one I liked then I ended up forgetting to pack it into my rucksack! Anyway, I went with flip-flops and I would say it is something that is worth spending nor more than £10-£15 or £20 max.
I think sun-cream is an iceberg conversation in which you begin thinking any one would do then you think about what factor is good or enough rather and which one you should get as you may be thinking about a spray verses cream.. I think cream is supposed to be better however I’m no expert. Personally I found the brand Piz Buin to be the best I’ve yet to use. Obviously in the highest factor in my destination (30 for that specific product).
The next essentials is for your stay in a hotel or similar to that. Don’t be one of those who go around asking for power adapters, the hotel may have given them out or charges for them. Unless you’ve paid a lot for your stay and it’s expected they provide you one (five star hotels).. If not then your only option would be to pay at the nearest place that sells one.. This is because if you end up getting one at the holiday destination I bet they’ll charge you double, just because they can. Get one in advance from amazon or something on a decent price. If you have a long cable for your phone charger bring that just in case the socket is far from the bed.. If you have a powerbank or two things to charge then I would say bring another adapter so one for charging your phone and one for the powerbank or camera if you end up needing it. Although a two socket in one adapter may be better for saving space.
You’ll want to exchange currency before you arrive because they will give you poor exchange rates and there’s nothing you can do unless you find an ATM that your bank can offer if your bank even gives you a good rate. The airports will also be poor in this regard so you would be better off getting it done at the best place you can find near where you live in advance.
Two factors to consider when exchanging currency. One the exchange rate volatility and what direction it looks to be going. The demand for it is why there is rate differences.. Local currency is going to be in high demand in the local destination so they know you have no choice but to exchange with a poor rate. For example if you know the pound is high/strong currently then order some online to be delivered to you before you leave. The amount depends on your expenditure. If you plan to have dinner every night, get a rough idea how much dinner is going to cost and multiply that by your nights.
Check if your hotel provides towels for the beach to borrow, could save you luggage space. If you booked a four star or above then its expected that your hotel should provide shampoos and soaps, but if you prefer to use your own or have small backup then you could get one of the mini container of your choice, I saw some at the airport shops.. Same goes for the dental kit, it’s all whether you’re comfortable with using the ones provided if needing the luggage room.
Have a small bag handy to hold your towel and things for the beach or pool, or if your rucksack is suitable too, then perfect.
Bring your best camera! If you don’t have one then why not go with a GoPro or one of the alternatives that also provide waterproof containers. It’s either that or buying a professional camera like a Canon EOS 1300D. You’re either choosing to get stuck in with a GoPro or you’re looking for spectacular pictures, the usual digital camera is stuck between I think a blur of both. I’d say choose one of the above, at least you’ll get a perfect shot with your proffered style.
Nowadays airports do not allow liquids larger than 100ml in hand luggage, so don’t waste money buying expensive water or other liquids only to empty it before the security point. Drink or bring a small one for the airport journey and buy one after the security point although if you have a connecting flight be aware you’ll end up having to empty it again however if you bought something you intend to use or open once you arrive then the airport provides the specially sealed bags that can pass through security. Another option is putting it in your luggage that will be checked in.
One thing I did was to take a few of those plastic bags you’re given just before the security zone. The ones used to seal 100ml liquids you may have. Why not, I mean they take your plastic I think it’s fair! Later on I found them to be useful to holding money and other things like earphones in my drawstring backpack when at the pool or beach. Going into it with wet hands makes your paper money all soggy or potentially broken electronics. Up to you though if you think that’s too much as there’s always drying your hands with the towel! However there’s also other uses for them bags too. Like when it comes to packing again and making sure your liquid containers don’t spil within your bag.. All about being a step ahead and one of the reasons I thought this is worth sharing.
At one point I wanted to write about some useful suggestions and tips you can take and use on other journeys and on the other hand write about my trip, Sale Cape Verde hence the title.
I took a connecting flight to Lisbon, waited two hours then on to Sal, which I will do the same in reverse for my return to London, Heathrow.
I landed at Amílcar Cabral International Airport, the island – Sal – has a population of 35,000 (2010) and there’s three things I stored on my phone that required no internet connection to access. Converted the webpages to pdf I stored the flight confirmations the hotel confirmation and finally from the UK government website for Cape Verde, containing all info like phone numbers, and other useful info for a Brit to know when travelling. Worth reading in advance too as you may need some vaccinations before hand, like a week or so in advance. This deserves its own paragraph even as its worth going to your doctor to see if you need any shots! Specially going far out as Africa..
It’s worth reading about the local situations before you head out too, definitely from an objective prospective as you’re looking for a heads up not to be scared off or be made to be paranoid. Lucky I had an ex collogue working out there which helped me with some excursions to go to, speaking to the locals without asking direct questions but generally flowing into the conversations. It seems some locals don’t see the potential to get involved with the tourism, they are rather distracted with petty crime and drugs.. I personally think you could say that about any society..
One thing I found myself thinking about is whether it was worth me spending money on a tour around the island on a Segway or Hummer! I think renting a jeep or an off-road vehicle for a few days might have been more of an adventure. if you don’t have the guts or want to bother to do that then a Hummer really makes off road enjoyable and you get someone that knows what they’re doing.. For example our driver was caring enough to think about some baby turtles that were being stored by a local fisherman in a fridge that was not even working.. Not sure if the fisherman was being helpful or had some other plans.. It ended up with some great pictures of rescued baby turtles and an experience id probably never would have. Not even when you go out one night for a chance to see adult female turtles laying eggs for example.
Anytime you go near the big ocean’s it’s worth going out to sea, fishing in a small boat with the beautiful waters beneath you while the nourishing sun gleams.. It’s like food comes from nothing but water and it’s spectacular seeing endless ocean it puts a little perspective of the universe’s size in some sense.
My first time fishing experience was not going too well, I had not caught a single one while the crew members on board, a lady specifically with the highest had managed four or was it five.. I was beginning to get a little down about it as I had the imaginations that I would be somewhat decent at fishing, maybe it was not her first time but that was not my thoughts at the time nor was I willing to even turn around to see her methods as it felt time was against me. I was also on the other side of the boat and started to think it was the sun that was allowing the bait to be more visible and enticing for those on her side. I almost got desperate to begin nudging-ly to swap places!
It was not that they were not biting, the fish seemed to be taking all my bait however to sense the fish on the hook and then to know when to pull and how to correctly reel it in was taking a few losses. The guide I guess may have been giving me the sympathetic script of the fish not really biting today as they normally would do and that they were nibbling a lot as the small ones tend to do..
So I took a break, sat down, had a drink and a basic ham sandwich. Watched the others and noticed I could try and hold the rod differently while observing the others. Kind of believed what the guide said and stood up slightly determined as before, however no hope! Again it felt grim as I missed one and twice the hook came back up empty.. I held the rod and left the line as if it was dead to me, pretty much giving up, but then I felt something and sprang into action, eventually I caught one and it seemed like I executed all that was briefly explained to me correctly for it all to converse to one entity and there was no failures that I could admit which caused the last ones. Now I thought I was just getting started with morale back to full and an understanding to repeat what I just did and in some sense felt I could actually do this pretty much on my own, one day in my own boat out at sea alone even!
I went over to hook on new bait and go for my second but then there seemed to be some commotion on the small vessel, however I did not even care, it did not even seem to bother me as my focus was registering what had just happened to me until a green sparkling fish reflects from the sun within the water. The guide and driver begin to scramble looking for a capable hook and line to catch what was a dolphin fish.
I took some pictures and then realise I’d be repeating the shots so I begin to record. Again at the end the fisherman guide wants a copy! I felt like a professional at that point.
So I wrote a guide on Steam on syntax colouring for Random Map Scripting for Notepad++, the scripting language to write random maps on Age of Empires. Essentially Notepad++ supports language syntax support, allowing you to make syntax easier on the eye.
So you’re writing a random map script, using standard default Notepad (that comes with Windows), it would look like this:
With Notepad++ and syntax colouring (User Defined Language Files) enabled, it will look like this:
So you get the drift, basically giving you a clearer visual on your code and possibly preventing errors in them as well.
Batch files are a nice and simple way on Windows to create one click solutions for tasks that you do on a regular basis. In my case, I wanted to find a quick and simple way to create a file I create on a daily basis and add the current date on it when I create it at the same time, of course as quick as possible.
I have a master file I want to copy it from, so with that I do:
COPY “C:\Users\Savas\Desktop\Testfolder\masterfile.txt” /y
ren “masterfile.txt” “File1 – %date:/=.%.txt”
There’s obviously many ways to do this above so you can choose your way suited for you.. The result will basically be creating a file in the same folder as the .BAT file I created, it will name the file “File1 – date.txt” Because my computer date is set to 27/04/2015 standard (you can find this out by simply doing “echo %date%” and the result should tell you your date format. Simple!
Now what about yesterdays date, as far as I can find, there doesn’t seem to be a simple one line way to just do yesterday date.. So we have to set some variables and have the batch file get the date in DD format then minus off one day and then join the date back together.
The %dd% takes the date and then takes off all, but the DD format. So instead of having 27/04/2015, we end up with just 27. Then “@set /a c=%dd%–%b%” line simply takes the number 27 and minuses the number in the “@set b=1” variable, and in this case it’s “1” so we end up with the result in %c% declaration. Put the month and year and we have the date for yesterday!
Of course if you’re using these batch files on separate systems and these systems have different date formats, you’re going to reach some minor issues and that means you’ll need to be more specific with your date formatting. In my case, 6,4% takes a sub string, starting at position 8, and keeping 4, which is 6,4.
In my case, I don’t have this issue, I don’t need my batch file to be some complicated and long winded method to pull the date and when I create my file, I will see if the date is wrong immediately. I hope this helped.