Author: Chris Hammond

  • Guide to solo driving through Kurdistan Region of Iraq

    Citadel in Erbil, Kurdistan Photo captured by Chris Hammond

    In the KRI, visiting anywhere outside of the city is easiest by car. While it is possible to travel by taxi or bus to other towns and cities, having your own vehicle will give you access to remote and beautiful areas that are not otherwise accessible. In this article, I will discuss my experience of renting and driving through the beautiful Kurdish countryside.

    Renting a car

    There are dozens of car rental agencies in Erbil, the catch is that most are offline and require booking over the telephone or visiting their office. If you’re looking for a deal, stay away from companies like Hertz or Avis; they’ll charge you 2x to 3x more than local rental companies, plus, you should support local small businesses. When I was in Erbil, I rented from Param. The rate they gave me was amazing, and the owner was extremely friendly.

    South side of Korek Mountain, Kurdistan

    I found Param after searching across the internet, reading Google reviews, and checking out several rental agencies on Instagram. On Erbil International‘s facebook group, Param was recommended. I called ahead of time and they advised to come in on the day I wanted to rent.

    The process was relatively easy; I filled out some papers, they scanned my passport ID page, and I paid in cash (rental fee + damage deposit). There was one small hiccup – the owner asked to hold onto my passport, which I refused. Driving around Kurdistan means you’ll be going through countless military checkpoints that frequently ask for identification. Without ID, it’s likely you’ll be detained, and possibly end up in jail. I was a little surprised the owner asked this given that he should know better, but after I refused, he agreed he didn’t need it, and there weren’t any other problems.

    When renting, also make sure you request a collision damage waiver. In the KRI, car insurance isn’t available for local drivers, however, the rental agencies usually provide some form of insurance. I’d highly recommend it given that the roads are filled with less-than-stellar drivers and you don’t want to be liable if the car is totalled.

    Finally, if you’re unsure about driving here – don’t do it, or at the very least, take your rental out in the morning when traffic is lighter and practice for an hour. Afternoon and evenings are when traffic is the heaviest in Erbil, and this is when the roads are the craziest. If you’re prone to panic, it’s going to be a rough ride for you. Vehicles on the road will swarm you, flying by as they dangerously race well above the speed limit. While driving around KRI, I witnessed the aftermath of two fatal head-on collisions that occurred moments before I arrived. Often careless drivers are racing to pass one another and not paying attention to oncoming traffic.

    Things to watch out for

    On highways, sometimes you’ll encounter vehicles driving in the wrong direction. It’s pretty normal in KRI.

    You’re going to want to pay attention at all times, not only to other vehicles but also to traffic cameras and the dreaded speed bumps. Even more, when driving through cities, pedestrians expect you to stop for them to cross – so watch out. This isn’t like other countries where cars are given priority, in KRI it is expected that you will slow down and stop for people crossing, and many times, they’re not going to be paying attention to you if it’s a crowded suburban road.

    Speed bumps can catch you off guard. While great for slowing traffic down, they also have a habit of destroying the underside of a car if you hit them when going too fast. Based on my experience, there’s a significant number of unmarked speed bumps on rural roads, many of which I hit while driving between Erbil and Dukan. In the day, they’re easy to spot – but driving around at night, they can be very hard to see until they’re right in front of you. Given most rural roads you’ll be driving 80 to 120km/h, you won’t have time to slow down if you approach one; so, just assume that anytime you’re about to drive through an area with a shop or house on the side of the road, you’re probably going to encounter a speed bump. Grill that into your head if you plan on driving the countryside for more than an hour.

    Also, traffic cameras are everywhere and most of the time, they’re marked with a sign. In November I noticed an increasing number of temporary speed cameras operating on the back deck of police pickup trucks. These are usually completely unmarked, and not easy to see ahead of time. If you pass a speed camera and notice a flash, you’re likely going to receive a traffic ticket a few weeks later.

    Choosing the correct fuel

    Gasoline in the KRI is not the same octane as Western fuel. It is much lower grade and does not include engine cleaning additives. I once asked if Iraqi fuel has cleaning detergents included and was laughed at. I can only imagine they thought I was talking about adding soap to the fuel. ? In the West, most fuel includes chemical additives called cleaning detergents that clean the engine, allowing for cleaner combustion and less emissions. Nonetheless, that is not the case in both KRI and federal Iraq.

    With that said, given the fuel is a lower grade and not nearly as clean, it’s best not to let fuel go below a quarter tank so the debris doesn’t build up as much along the bottom of your tank near the filter. Given you’re using a rental, it likely won’t be a problem for you – but at least you’re extending the life of the fuel filter for the rental agency.

    When arriving at a gas station, many times an employee will be there to fill it for you. Most of the time, they won’t know English so you’re going to want to learn how to say it in Sorani or Arabic. For me, I chose Sorani given it’s respectful to speak the Kurdish language in Kurdistan.

    To ask for normal fuel, you can simply say “kaka, benzine fulika adii” or “kaka, fulika normal”. This means “sir, please fill with normal/regular gasoline”. If they don’t understand, you can sometimes get away with “adi full” or “normal full” (pronounce full as fool) and maybe two out of three times, they’ll understand you. The worst case scenario is that you may have to use Google Translate text-to-speech in Arabic. And yes, I’ve done this and had full-on conversations through Google text-to-speech, going back and forth from English to Arabic with a taxi-driver.

    Military checkpoint etiquette

    US military convoy passing by.

    There are many military checkpoints around Iraq, and for Iraqis, they’re a part of daily life. Unfortunately, they are a necessity in a country that has dealt with numerous conflicts and crises, including ISIS and other violent regional actors. When approaching a checkpoint, have your passport ready. I’ve found that when driving to the south of the KRI, they check passports more often, however, driving up in the northern regions like Shaklawa, Barzan, Duhok, and Amedi, they don’t check as often.

    When you approach a checkpoint, remove your hat and sunglasses, turn your headlights off if it’s night, and open your window. The guards are usually very friendly. Several times I’ve joked around with them, and often times they were surprised to see a Canadian driving out in the middle of nowhere up in Barzan area.

    Other things to be mindful of:

    Erbil -> Duhok highway

    One October evening, late at night, I was driving home along a highway between Duhok and Erbil. I didn’t realize I was entering a section under construction as there were no visible signs indicating the highway was about to end. The night was dark and there was no traffic around me other than one vehicle driving on the wrong side of the highway in our lane. I should have taken that as a warning. A moment later, as I was driving along at 100km/h, I suddenly realized the road ahead disappeared – the road was incomplete. I slammed the brakes and just narrowly avoided driving off the highway into sand and rocks ahead. It turns out that the other vehicle we just passed had also had the same experience.

    With that in mind, it’s always best to drive with caution and I’d recommend taking someone who is experienced. The main concern with driving in the Kurdistan region of Iraq is not security, but rather, being mindful of other drivers and varying road conditions that require consistent vigilance. With that said, having a vehicle to drive around the countryside was a tremendous benefit and allowed me to access parts of the country that were not accessible by other means. Good luck and I hope you enjoy your journey.

  • Converting foreign currency into Great Britain Pounds (GBP) inside the UK is often accompanied by steep buyback rates that may cost you upwards of 20% of the amount you wish to convert. A friend of mine recently had this experience and we were pulling our hair out trying to find the best exchange rate inside the UK. She initially only carried United States Dollars (USD) in cash but then faced a dilemma when wanting to convert it to GBP and deposit it into her bank account. She could deposit it at a travel exchange, which have exorbitant conversion fees and bad rates, or she could be slightly less ripped off at the Post Office, John Lewis, or M&S where their GBP buyback rates are also high. Thankfully, we found another solution that was much more fair and very close to the actual exchange rate.

    The solution is quite simple, but requires you to register for an HSBC account in UK and open a free Current Account. You can do this online and it only takes a few moments to fill out the form and then a few days of waiting for the card to arrive in the mail. The wait is worth it if you are converting a non-insignificant amount of cash. I can confirm this works if you follow these steps, provided you qualify for an account. Here are the steps:

    1. Register for an HSBC UK Current Account online. You can do this without having to go to a branch. It may be instant, or worst case, you have to wait for the card in the mail.
    2. Once your account is open, install the HSBC UK mobile app and set up online banking through the app.
    3. Once logged on, open HSBC Global Money Account in the application. This is instant.
    4. Now, open an HSBC Currency Account in USD. This is also instant. To do this, log onto the HSBC website and register.
    5. That’s it. You can now go to the branch and deposit USD into your currency account. After, you can use HSBC currency converter or transfer it out to Wise or another online exchange of your choice, or use the HSBC rate which is much better than the aforementioned routes earlier.

    Final thoughts; Although HSBC wouldn’t be my primary choice for a bank, I’d recommend HSBC over Barclay’s. I originally tried to do this with Barclay’s but their customer service was absolutely terrible; sometimes, living in UK, it seems some customer service representatives look for excuses not to help rather than actually do their job. With Barclay’s, they claim to offer online services, but then registration is followed with an in-person visit to a branch where their staff, based on my experience, are rude and borderline racist. Their loss, they just missed out on a large account. Talking to three different Barclay’s staff, each one iterated over a list of excuses about why they didn’t want to take on a large account which would have profited their institution. It was very bizarre, I have never seen so many employees in customer service not want to do the bare minimum to open a basic account.

  • Dr. Gene Richardson introduced the idea of structural violence in this unit. He also speaks about how reliance on medical technology can undermine the introduction of social interventions that may be relevant for preventing or treating HIV/AIDS.

    Please describe the idea of structural violence.

    Next, describe one or two social (i.e. non-pharmaceutical) interventions that you think could be effective in preventing or treating diseases such as HIV/AIDS or other infectious diseases.

    Write 4-5 thoughtful paragraphs about possible interventions and the role they could play in improving public health. Be sure to save a copy of your writing on your computer so you can access it.

    As discussed by Dr. Richardson, structural violence comes from institutionalized racism, gender inequality, lack of access to clean water, and lack of access to housing. To expand on this, it is how socioeconomic and political systems may endanger the lives of a minority group, increasing the risk of morbidity and mortality (CHER). It perpetuates inequality in health and well-being through social forces that harm a minority group.

    In the context of women’s rights, often structural violence is woven into the fabric of society where institutions at all levels may treat women differently than men. We see this with lack of access to healthcare, education, and prioritizing the needs of male family members over women in many impoverished nations.

    Regarding HIV/AIDS, social intervention is an effective method for preventing and treating the disease. Data shows that when young girls are educated about the disease, taught about prevention, and provided with instruction on contraception, then rate of disease lowers. Likewise, when women are empowered through education that informs them of their rights, particularly regarding bodily autonomy, the rate of HIV/AIDS is reduced as women realize it is their right to decide and negotiate sexual encounters with others.

    Furthermore, raising the economic outlook for women, once again through education that empowers girls and women, is critical. Through appropriate education, girls are empowered with skills to enter the workforce that may provide opportunities for economic independence. In doing so, young women move away from relying on family and marriage, where men often become the sole source of income and forces women into dependency.

    When considering marriage is the primary risk factor for obtaining HIV/AIDS in many developing nations (Murray), economic independence becomes critical. Often young women marry older men out of necessity to eat and survive, however, commonly men will take part in unsafe sexual behaviour with others, in-turn, infecting their partner (Murray). Therefore, women who are economically empowered are more capable of providing for themselves, and better able to negotiate relationships and marriage, breaking out of the patriarchal cycle of economic dependency.  

    Bibliography:

    CHER – What is structural violence? Center For Health Equity Research Chicago. n.d. 11 February 2022. <https://www.cherchicago.org/about/structuralviolence/>.

    Murray, A. F. (2013). Adolescence: Change and Vulnerability. In From outrage to courage: The unjust and unhealthy situation of women in poorer countries and what they are doing about it (pp. 75–101). essay, Common Courage Press.

  • Visa on Arrival and renewal guide for tourists in Iraqi-Kurdistan

    Mt Korek, Kurdistan – Chris Hammond

    September 2023 Update: The KRG now hosts a new Visa E-Portal, therefore some elements of this post may no longer be relevant. I have not yet used the e-portal, but when I do, I’ll provide a write-up.
    —-
    This past autumn I spent three wonderful months in the Kurdistan Region of Iraq, and it changed my life forever. I met the friendliest of people, hiked some of the most incredible trails, and visited several of the oldest historical sites in the world, dating back over 6000 years.

    Now that I’ve returned home, I want to document my experiences and publish, what I think, will be a series of helpful guides for others who wish to visit Kurdistan.

    A quick note – I wrote this article in December, 2021. It should be accurate for now, however, things within the KRG change frequently – so keep that in mind.

    Obtaining Visa on Arrival in Erbil:

    Recently, the KRI simplified the visa process for most Western citizens by providing Visa on Arrival (VOA) (list of countries here). The VOA for tourists includes up to two tourist visa renewals for a total of 90 days (30 day visa-on-arrival , 2 x 30 day visa extensions). If your country is on the list, the VOA process is simple – upon arrival at Erbil International Airport, you will make your way to the visa and customs desk. There, you’ll present your passport and pay a $75 USD visa fee. They’ll take your photo, complete some paperwork, and then stamp your passport. Make sure you have money ready ahead of time because there won’t be an ATM available to you. Likewise, have extra cash for the airport taxi before you arrive. The KRI is not a western country, they operate primarily with cash – finding an ATM can be difficult if you don’t know where to look (I’ll be making a post about this soon).

    Tip: Some airlines have outdated documentation that isn’t wholly accurate on KRI. Both in Toronto and Dubai, I had to patiently explain to Emirates airline that the Kurdistan Regional Government provides a VOA for Canadians. I would recommend you print out this list here and highlight your country, so you can present it to the flight attendant if they question you. To be honest, the hardest part about my journey was convincing the Emirates attendant at the Toronto check-in desk that I’d be granted VOA in Erbil.

    Renewing your tourist visa:

    If you want to stay longer than thirty days on a tourist visa, you’ll require a visa extension from the KRG Residency office. Many people opt to pay a lawyer to handle this, which is likely easier; however, finding a real lawyer and not someone trying to scam you on Facebook can be difficult if you don’t have any local connections. If you want to avoid paying lawyer fees, you may renew your tourist visa on your own by following the guide I’ve prepared below. I should note that paying a lawyer likely won’t cost you too much, so it may be easier to go that route.

    In addition, if you don’t speak Sorani or Arabic, you’re going to want to follow these instructions closely otherwise you’ll end up lost and frustrated. It took me three attempts to finally have my visa renewed, partially because of misinformation provided by people trying to be helpful, but also because there are very few resources available explaining this process and I had to use the trial-and-error method to figure it out.

    How early may a tourist visa be extended?

    Based on my experience, the KRG officers would only extend my visa on the day it expired with the only exception being if the expiry date fell on a weekend or holiday. I tried twice to renew in advance, and both times they turned me away and told me to come back on the day of expiry. This leaves things very tight, and if you go beyond the date on your visa then you may be hit with a fine, or worse, they may not renew your visa and instead deport you. If the expiry date is on the weekend, they will renew it on the last day of the week. Weekends in KRI are Friday and Saturday, NOT Saturday and Sunday.

    Where are visas extended?

    The KRG Residency office is located here on Abdulkaleq Sarsam Street, near Life Towers . Right now, Google Maps will give you the incorrect address if you search it and you’ll end up at the wrong building. Make sure you arrive by 8:30am, and once they open, make your way into the security station (the second one past the gate). You’ll have to leave all electronics with security, including your phone. In exchange, they’ll give you a tag with a number and you’ll use this to collect your electronics when you leave.

    This satellite image is a little old, the parking lot is now paved – however, you get the jist of where to go. This is accurate as of December, 2021.

    Important note: If you arrive before they open but during a busy time of year, you may have to line up outside first, and they will separate you by gender. I highly recommend you arrive early, or you may be turned away. When I was there in September 2021, there were at least a hundred people waiting to get in. It was mostly Iranian and Turkish citizens renewing their visas (Salam salam!).

    Finding your way through the KRG Residency building:

    Continuing, after you make it past security, walk towards the main building. Upon entering, head up the stairs to the second floor and once at the second floor, turn right and walk down to the end of the hallway. You’re looking for room 12, located at the very end of the corridor. When you enter room 12, approach the first desk directly in front (sometimes it has a #2 on it) and show your passport visa page. You’ll be given a form to fill out with your name, address, and contact number of someone local. You can write your hotel telephone number.

    Tip: Before you arrive at the residency office, write down a local contact number and address on a piece of paper and keep it in your pocket. Also, bring a pen (you’ll need it). You won’t have your phone with you since it is held by security while in the residency building, so you can instead refer to your pocket note when filling out the visa renewal form.

    Payment for visa extension:

    After filling out the form, you’ll return it to the same desk, and the desk agent will fill out the bottom with the visa fee price. At the time of writing this, the price is 110,000 IQD ($75 USD). I’d recommend bringing dinars to pay, and bring extra in case the price has increased. You’ll then have to head down one floor to room 10. There, you’ll pay the fee, they’ll stamp your renewal form to indicate payment was completed, and then you may return to the second-floor, room 12.

    Important note if you visit during the tourist season: If it’s a busy time of year for visa renewals, they may have a desk within room 12 where you will pay the visa fee. If that’s the case, then you won’t have to go down to room 10. When I renewed in October 2021, they added a desk on the left by the entry to room 12. However, when I renewed again in November 2021, during off-season, this desk was removed and I had to pay on the first floor (not ground floor), room 10.

    Visa extension processing:

    After payment (and returning back to room 12 if you had to leave), drop off the form along with your passport at desk #4 (the one in the corner on the right). Within 10 to 20 minutes, the agent will likely have processed your passport and then you’ll bring it to the first office (on the left side of the room). Inside you’ll find a KRG officer who will stamp your passport and write a date on it.

    Once this is complete, bring your passport to the next room attached to room 12 on the right. In this second room are female KRG agents along with a higher ranking KRG officer sitting by the entrance. In there, they’ll give your documents a final lookover and press some buttons on a computer. After that, you’re ready to go, and they’ll say “Welcome to Kurdistan” – even if it’s your second visa extension. 🙂

  • Tilemap bitmasking

    As a game developer, bitmasks are useful when it comes to representing a set of data with single digit in both 3d and 2d games. An illustration of this in use in three dimensions can be found within the well known voxel game minecraft. The current status of a block may be represented with a bitmask value to indicate whether it is open or closed when considering blocks adjacent to it. For a given voxel if one (or however many) side(s) is open but surrounding sides closed, perhaps you wish to show a grass texture or only render one side – that voxel would have a bitmask value based on what surrounds it and we can use that to determine how it should render.  If the voxel is completely surrounded, it has a different bitmask value and perhaps you wish not to even render voxels with a bitmask value that indicates it should not be visible. In this usage scenario, what this bitmask value tells you is whether the voxels on each side are open or closed – and this is all saved with a single bit. In other words, through a single bit you are storing a set of data that would otherwise require more memory!

    In a 2d game this has all sorts of usage scenario’s too. For example, when it comes to tilemaps and placing tiles there is a huge benefit to storing data represented as a bitmask value. For example, a fence – having a single fence tile may have a stand alone sprite to display, however, placing two fence pieces beside each other may require two different tiles drawn to line up. This means that an algorithm will have to determine the surrounding sides to decide which fence piece should be rendered (i.e. an end piece, middle piece, L shape, etc). We can use a simple calculation to determine this for a 2d tilemap:

    https://gist.github.com/MrChrisHammond/fab4fd64473ac521679d91b53d2234e0

    With this simple equation, we will then know which tile to display. Below you can see it in action in my game Attack of the Dead – I’ve replaced the wall tiles with some dummy tiles to show the bitmask value for illustration. The variables left, down, right, and up are simple boolean values to indicate whether there is a tile at these positions surrounding the tile you are calculating for.

    The textures to display the tile may be named according to the bitmask value for easy organization, or alternatively, you may assign a tile to display based on the bitmask value of that tile and organize your atlas based on the bitmask value.

    If you need a quick 4 tile bitmask chart, I’ve thrown one together on JSFiddle below. You can easily modify this for using 8 tiles or whatever suits your needs.

  • I recently wanted to write a small app to become more familiar with .NET encryption/decryption libraries. As a result, I created a quick little account locker app which stores manually entered account data locally. Sure, there are great services available which do this already and automate the process, i.e. last pass, for saving passwords securely across multiple devices – however, SimpleAccountLocker is an extremely minimal app which provides the basis to store data locally if you do not wish to save off-site; likewise, it was a fun little way to play with some security libraries.

    You can view the app on my GitHub: https://github.com/MrChrisHammond/SimpleAccountLocker

    To begin, .NET offers many different encryption classes, however, for this app’s purpose, the main AES classes I tested out include:

    – RijndaelManaged
    – AesManaged
    – AesCryptoServiceProvider

    All three of these are based on AES – a specification for encryption created by the US National Institute of Standards and Technology (NIST) in 2001. This method of encryption is symmetric and allows data to be encrypted and later decrypted with a key and initialization vector. This is helpful when you have data you wish to store securely but have a later need to decrypt and read it – for example, an instant message. Nonetheless, within the aforementioned classes are a few differences. For instance, RijndaelManaged allows you to set a different block size whereas AesManaged maintains the same fixed blocksize of 128 so-as not to compromise security. However, AesManaged is actually based on RijndaelManaged.

    In terms of compliance, AesCryptoServiceProvider uses a library which is FIPS compliant1 whereas RijndaelManaged and AesManaged do not.  If you are not familiar with FIPS, you might be wondering – what is it? The Federal Information Processing Standard is a set of rules which sets the requirements on approving cryptographic modules. Although this is a US government standard, here in Canada the Communications Security Establishment (CSE) uses FIPS 140-1 and 2 as part of its certification2.

    In code, all three of these can be used to encrypt data with an ICryptoTransform transformation, CryptoStream decorator, and using a key and Initialization Vector (IV). Below is a  comparison of AesCryptoServiceProvider vs RijndaelManaged within SimpleAccountLocker.

    https://gist.github.com/MrChrisHammond/d78cf78c02b435824c1806e2850b193f

     

  • Boid’s model was created in 1986 by Craig Reynolds to simulate the behaviour of birds as they group together in a flock. The model has three key methods to mimic real life bird flock behaviour. These methods include:

    a) Maintaining a heading based on the averaged direction of surrounding boids.
    b) Maintaining a separation so boids do not overlap.
    c) The boids must maintain a cohesiveness with the flock by steering towards the centre position of surrounding flockmates.

    The behaviour also operates similar to schools of fish or other wildlife. As a game developer, this can be useful when implementing enemy mob behaviour and in my case, I used this approach to simulate flocks of zombies in 2d space as seen in the mp4 above.

    The concept isn’t too difficult, below I’ve posted two implementations. I’ve implemented it using rigidbody2d but I’ve also included the code for using it without rigidbody force.

    1. Boid Class for use with Rigidbody2D

    https://gist.github.com/MrChrisHammond/bb97ba2b25dbb95dad6cc980132bc31f

    1. Boid Class for use with kinematic

    https://gist.github.com/MrChrisHammond/91c12806aeea0a25d8a68e6e81776955

  • It is no longer required to download the Android VR SDK to build a mobile VR game or application for Unity. Instead, you can set your game up in the Unity build settings and make use of UnityEngine.VR.

    Creating a simple player controller may be a bit tricky and so I hope this post will save some developers a head ache when it comes to moving a player around with a gamepad in Android based VR projects.

    In this setup, I’m using the following:
    1 x Android 6.0 Phone
    1 x XBOX 360 Wired USB Controller (but you can use any Android VR controller)
    1 x Generic Android VR Headset

    To begin, it’s important to understand that you have to create a parent and child arrangement of GameObject’s to control a VR player. Whereas generally a simple FPS controller might be arranged with a Camera as a child to a Capsule, with Unity VR you’ll have to child the Camera to a Camera parent Transform and that Camera parent will be a child to your main player. Even more, the Body of the player will have to be a separate child Transform of the parenting Main Player GameObject if your player has a body. Why? This is done to control the movement of the Camera since moving the Camera Transform directly in VR seems to result in odd behaviour/non-functioning movement at the time of this post.

    Here is how your basic Main Player hierarchy should look:

    Step 2:
    Attach a camera to the Camera GameObject.

    Step 3:
    In your input settings, add two new axes. For the two different Android phones I tested, the Xbox 360 controller I had seemed to map to these axis:

    Step 4:

    Create a new script and call it SimpleVRController.cs Use the code below then assign the proper transforms in the inspector.

    https://gist.github.com/MrChrisHammond/f4f6025b665833771d5cea1ad0c3e375

  • Target scanners are essential for any game where you have an enemy mob that actively looks for prey. One way to scan for targets is to cast a circular physics ray based on the radius area you would like to scan.

    Below is a quick and helpful intro I’ve put together for anyone who needs a quick and easy target scanner to notify another script via event subscription. It searches for targets based on the tags set through the Unity Inspector.

    https://gist.github.com/MrChrisHammond/bc67005f5d54a9a473fa8c7c869a393a

    How to use from another script:

    https://gist.github.com/anonymous/29f7171737db1cb7f4e1034fa1e45ec1

     

    Final notes:

    This is a simple solution if you only require a few dozen scanners running at a time or less. If you have many more running concurrently then using tags may be slower and I would recommend scanning based on Unity Layers. You can set which layer to RayCast2D on or alternatively, you can set in Project Settings -> Physics 2D and set which physics layers interact with one another.