Friday, January 18, 2019

Zelda: Breath of the Wild - Easy Weapon Respawn Locations

One of the weapons people look for often is the Flameblade.  This weapon is useful because it starts fires and can be used for Dragon Horn farming.

Here is a map of the locations in Hyrule where the Flameblade is just sitting out in the open.



Here's a list of good weapons that are easy to get and that re-spawn.



LocationWeaponDescriptionImage
Woodland TowerRoyal ClaymoreClimb the tower
NW of Gerudo Tower Multiple (Gerudo spear, Golden Bow, Radiant shield, edge of duality, Moonlight scimitar)Fly across ravine. Find three boulders in the side of the rock. Use stasis to break the boulder. Weapons and chests inside.
Cuho mountain, north of Tabantha TowerGreat ThunderbladeFly from tower to Cuho mountain.  Run around the left side of the rock to find a canyon.  Sword is on the ground in the gap.
Tu Ka Loh shrine, in labyrinth North of Akkala Ancient Tech LabGreat FlamebladeFrom shrine entrance, head right down stairs. At bottom of stairs there is a ledge. Jump down. There will be a set of thorns to the right. Burn them with fire arrow. Climb the wall and follow the hall to the end.
Ancient Tree Stump,
West of Central Tower
Great FlamebladeHead west from the tower to a lake with a tall structure in the middle called the "Ancient Tree Stump". Fight or sneak past the monsters to cross the bridge to the structure and find the blade.
Eldin Great Skeleton, West of Gorae Torr ShrineGreat FlamebladeHead west from the shrine, crossing several mountainous areas until you find the Skeleton.  The sword is underneath the skeleton by a rock.
Docks,
Northwest of Hyrule Castle
Great Flamebladefrom north west of the castle, glide across the ravine and land on a path under the castle
Ne’ez Yohma ShrineSilver LongswordGo around to the back of the shrine.

Tuesday, April 24, 2018

Configure IIS To Host Python

Overview

To host python on an IIS web server, you must install python and configure IIS on the machine. 

In this case my organization doesn't allow internal servers any internet connectivity at all, so i had to figure out a way to get the dependent python packages via a manual download onto the server and install manually.  

For some reason I had a hard time configuring the proxy for python, so I run Telerik Fiddler to funnel my traffic through the proxy anytime i need to install packages via pip.   


The reason why I wanted to use Python for this project is it's really easy to prototype Object oriented libraries and expose a REST API via Flask.  I was able to turn around a proof of concept whole project from inception to functioning site in a week (while juggling my other responsibilities).

Steps

1.       Figure out which Packages you need
a.       This step assumes you have Python installed locally.  If not, download the Python installer and run it
b.      From your local workstation, run Fiddler.  This will funnel python web requests via the proxy
c.       Open a command line as administrator
d.      Use "pip" to install the packages you want. 
e.      Use the command "pip freeze > requirements.txt" to generate a list of installed packages.  IF you can't use pip, write down the dependencies so you can find and download them manually

f.      Use command `pip download -r requirements.txt -d offline_install` to download the packages you need.  IF you can't use pip: go to PyPi, search for and download all the dependencies and packages you need
                                      i.            Make sure you download the correct package for the version of python you have
                                    ii.            If there is a choice of a wheel file (.whl) or a source zip, choose the wheel file
g.       For a Flask application, you will likely need a minimum of
                                      i.            click
                                    ii.            Flask
                                  iii.            itsdangerous
                                   iv.            Jinja
                                     v.            MarkupSafe
                                   vi.            Werkzeug
                                 vii.            Wfastcgi
h.      Your flask website will likely have a routing file in it where you instantiate the Flask app. 
                                      i.            I will refer to the file name (without an extension) where the flask instance is created as <FILE>, e.g. for file "flask_app.py", <FILE> would be "flask_app".
                                    ii.            The name of your Flask instance variable will be referred to as <APP>, e.g. if in your script you say app = Flask() then <APP> would be "app"
                                  iii.            <FILE>.<APP> will be the name of your file (no extension) and app separated by a period.  e.g. flask_app.app
2.       Install Python and the necessary packages on the server
a.       Copy the Python installer to the server (I used version 3.6.5 for this example)
b.      Install python
                                      i.            When installing, choose a path without any spaces, e.g. C:\Python3.6
                                    ii.            I will refer back to this path as <MyPythonPath>
c.       Copy the package files  to the server
d.      Run "pip" to install each local package
                                      i.            You may need to use the full path of pip to install, unless you add the python directory to your PATH environment variable
3.       Configure IIS to use Python with FastCGI
a.       Open IIS and choose "Add role Services"
b.      Ensure CGI is selected
c.       Right click on "sites" and choose "Add Web Site"
d.      Add a site with whatever name you choose, e.g. ReportingSite. 
                                      i.            You will need to select the folder where your web site will be at this stage
                                    ii.            I will refer back to this folder as <MyProject>, e.g. D:\Reporting\ReportingSite
                                  iii.            You will also need to select a port that is not in use
e.      Click on the web site you created and double click "Handler Mappings"
f.        Pick "Add Module Mapping" from the right
g.       At each prompt enter the following, replacing <MyPythonPath> with the directory where you installed python in step 2b.
                                      i.            Request Path: *
                                    ii.            Module: FastCgiModule
                                  iii.            Executable:  <MyPythonPath>\python.exe|<MyPthonPath>\lib\site-packages\wfastcgi.py
                                   iv.            Name: python-wfastcgi
h.      When you continue, you will be prompted to create a FastCGI application. Click "Yes"
i.        Not e that the wfastcgi package should have put the wfastcgi.py file in the folder you specified.  Check that it exist just to be sure.
j.        Click on your new website again and go to "Application settings" under ASP.Net and add:
                                      i.            PYTHONPATH as <MyProject>
                                    ii.            WSGI_HANDLER as  <FILE>.<APP>
4.       Create a rule in the firewall to allow requests to go through
a.       Open windows firewall
b.      Add an Incoming rule to allow requests on the port you specified in step 3d

Friday, July 7, 2017

Xbox One Wireless Controllers Don't work on Linux

I recently made the switch to Linux for gaming and it's been a wild ride so far.  I've learned quite a bit and have good experiences with the linux community offering helpful suggestions and walking me through my n00b issues.  So far it's been an enlightening experience getting free from MIcrosoft's stranglehold on home PC operating systems.  I still have a workstation that uses Windows for the missus, and for working from home myself, but the more i learn about Linux the more i understand it's nice having alternatives with a strong supportive community.

One area I haven't been able to escape the grip of Microsoft (aka M$) is their gaming controllers.  I really enjoy the ergonomics of their controllers, and there is considerable support for them in many PC games.  That said, they have managed to irk me by doing something incredibly inconsiderate for their customers.

About a year ago I bought an Xbox One wireless controller and adapter for PC gaming.  I liked the fact that i could use my existing Xbox One controllers I had from my console gaming days if i wanted to play multiplayer games on my PC too.  When I moved to Linux I thought it would be a seamless transition, so I bought another wireless dongle (big mistake!) for use with the new SteamOS PC.  It turns out M$, in their quest to maximize profit and inconvenience customers, have made the wireless controllers proprietary.  There is some non-standard chipset in the dongle that prevents drivers from being created on Linux that are compatible with the dongle.

It's incredible frustrating that I now have to redesign my home gaming layout.  It turns out there is a new bluetooth version of the Xbox One controller, which I don't have, but is compatible with Linux.  However, M$ made it so only a single bluetooth controller can be paired with Windows machines at a time.  Therefore, you still need to buy a wireless adapter if you want to connect multiple bluetooth Xbox One controllers to Windows.  So frustrating!  M$ can't just make things easy.

It turns out, Xbox 360 controllers are not limited in Linux or Windows so that the most versatile option.  You will need an adapter costing $10 to $20 but you can then reuse your old controllers, and/or find them used online.

TL;DR:
Use Xbox 360 controllers with a USB wireless adapter if you want to use on both Linux and Windows.
If you're using Xbox One controllers, you need to buy a wireless adapter to connect multiple controllers to Windows.  On Linux you need the Bluetooth enabled version of the Xbox One controllers.


Thursday, June 29, 2017

Switching from Windows to Linux (SteamOS)

I just built my first Small Form Factor PC to replace my old consoles.  I decided to install SteamOS on it to see what gaming on Linux is like, and for a more seamless console-like experience.  So far it has been rough going.

Most of my life I've used Windows PCs.  I have used Windows at work, school, and home since Windows version 3.1 (before Windows 95 they didn't use years in the version names).  One of the best things about Windows that I took for granted in recent years was that most computer peripherals connect seamlessly through "Plug-and-Play".  I never had to worry about whether or not something I bought was compatible with my operating system version, with the occasional exception between Windows upgrades.  Even then, making a device compatible simply meant running an installer from a CD rom disk or website to install the drivers which were always available.

Then I got a MacBook.  It was my first Mac since a PowerPC I had 1994 and now had to worry about compatibility again.  Since Macs are fairly prevalent now there is usually a Mac alternative to most Windows software or hardware drivers.

Now I have my first true Linux PC.  It's weird having to deal with incompatibility.  My Xbox controller dongle doesn't work with SteamOS.  Apparently there is some encryption in the dongle that prevents non-Windows PCs from using it.  It's crazy.  Now I need to replace my controllers with bluetooth equivalents.

I just hope Mac and Linux eventually puts Windows out of business.  This kind of stranglehold on the market and customer abuse (why would you ever need to encrypt a controller dongle?) is more reason why Microsoft needs to be put out of business.

Monday, June 26, 2017

Steam Card Price History

I put together a rudimentary tool that calls the Steam API and produces a distribution of prices for a given steam item.  It currently only works for Steam specific items, like cards, emoticons, or packs of cards, but it would be fairly easy to make it work for any game's marketable items.

To use the tool:
1. Go to the item's community market page.  Example: March of the Fidos
2. Copy the part of the URL after the last slash.  Example: 250110-March%20of%20the%20Fidos
3. Go to the item check page and paste into the top text box labelled "Enter the steam item name"
4. Click Submit

The result will be a distribution of executed trades for different time-frames, e.g. 1 day, 3 days, 7 days, etc and the percentage of trades that executed at that price in that time-frame.  Judging from historical prices, you can predict how long it will be to sell or buy your item at a given price.


Thursday, May 18, 2017

Pop Culture Referenced By Developers

Our development team has an eclectic mix of ages and backgrounds, but we always seem to reference a number of cult movies from the 80s and 90s.  I'm putting together this list for the benefit of new joiners to refer to when they want to catch up.  I will update as we reference more things and I remember them.


Movies

The Matrix

Big Trouble in Little China
  • I'm a reasonable guy. But, I've just experienced some very unreasonable things.
Pulp Fiction

Predator

Commando

Austin Powers
James Bond (Goldfinger)
Usual Suspects
Added 5/19/17:
Anchorman

Rambo
40 Year old Virgin

TV Shows

Beavis and Butthead


Music

Dave Matthews

Rage Against the Machine

Tuesday, April 4, 2017

Deploying Python Executables on Windows

Overview


Today I experimented with deploying self-contained python applications using WinPython , py2exe and cx_freeze.

cx_freeze seems to be more up to date since it claims to support python 3.5 and 3.6, but that is not as clear as it seems.  py2exe supports up to python 3.4.

My goal was to deploy a python application to a server without installing any software on it.

Update 4/13/17: After trying to build and deploy a real application I ran into a number of difficulties with py2exe and third party python packages (e.g. requests).  This has made me realize that cx_freeze is far more reliable and easier to use despite some minor limitations.

WinPython


WinPython is great because it is a python instance that doesn't require installation and is separate from any other python instance.  This is similar to virtualenv, but does not require running a python installer beforehand.

The benefits may not be obvious.  What it means is I can deploy as many WinPython folders to my server as I want without needing administrator rights to install python on the server.  In addition, the dependencies of each python instance are separate, so I can have two instances of python with different versions of the same package installed.

That way applications can have different dependent libraries and we never break an application that runs on one python instance by upgrading dependencies in a separate python instance.  This makes it easier to maintain Python applications in an enterprise environment.

py2exe

Py2exe transforms a python script into an executable program.  It supports Windows only.  As of this article's date (4/4/17) it only supports up to python 3.4.  

The benefit of py2exe is it compiled my simple program with very little configuration necessary.  With a few extra steps I got it to compile (mostly) into a single executable file, something cx_freeze doesn't support.  Having fewer files to will make deployment much easier.  For example, if a dependency changes I don't need to clear out the previous files first -- I only need to clear out the single executable.

cx_freeze

Cx_freeze is similar to py2exe in that it builds an executable program from a python script.  The advantage is it is cross-platform.  It can build executable files for MacOS, Windows, or Linux based systems.  It supports up to Python 3.6 as of this writing.  

When it comes to Windows, however, it requires the machine running your application to have the MSVCR (Microsoft Visual C++ Redistributable) package installed for instances of Python 3.5 or 3.6. 

Since my goal is to deploy python without installing anything on the server, I had to use Python 3.4. Recall that my goal is to deploy a python application with these restrictions:
  1. I only want to deploy to Windows
  2. I don't want to install anything to the server 
I would have to use Python 3.4 in order to avoid any installation.  That brings cx_freeze on par with py2exe in most cases.  Cx_freeze seems to be more configurable, which could be either good or bad depending on if you want simplicity (bad) or you have a complex use case to accommodate (good).  

One disadvantage of cx_freeze is it cannot package the application into a single executable file.  This means any deployment involves copying hundreds of files to the target location.

Conclusion

In the end I prefer py2exe to achieve my goal.  I like that it works out of the box without too much configuration and that I can get a single executable as a result.  

cx_freeze would be better for cross-platform applications or services.  Since my goal for this application is targeted for a Windows ecosystem this was not an advantage in my view.  That said, it wouldn't be too difficult to change my py2exe build to a cx_freeze build.  

Files and configurations can be seen in Screenshots 

Update 4/13/17: after trying unsuccessfully to get py2exe to include some rather simple packages, cx_freeze was able to build an executable with no issues.  I would recommend anyone trying to package python into windows executables to use cx_freeze instead of py2exe.