Warning: mysql_real_escape_string() expects parameter 1 to be string, array given in /mounted-storage/home46b/sub003/sc12436-RBYT/archigos/wp-includes/wp-db.php on line 1173
Archigos' Life – Page 2 – A small look in the mind of an insane genius.

What the hell……..??

§ Recent Changes §
I’ve written at least 3 or 4 posts since the Destiny one that I thought I had set to auto post on certain dates, as well as a handful of drafts with ideas, etc. that I wasn’t ready to post and it appears that none of that worked. They obviously didn’t post and the drafts have all disappeared. I know it wasn’t a hacker or someone trolling me… which means I either did something stupid, I don’t remember like deleting the posts or my memory is getting worse. My guess is that latter…

On any note, here’s only a little of what I had written since I can’t for the life of me remember 99% of it. First we’ll start with some of the medical cause it’s always on my mind.

§ Medical §
With the stigma of mental illness, we’ll start by ‘rehashing’ some old posts with new information. I’m too lazy to check the date, but I’ve occasionally talked about another person over the last year or so and have mentioned that they were diagnosed with schizophrenia… I still haven’t asked for permission to talk about ‘them’ specifically, but anyone that knows me personally may be able to venture a guess at who I’m talking about… (please don’t guess publicly). If you haven’t figured it out already, knowing that I’m not only related to him, but we’re close enough for me to be concerned as well since it can be hereditary. Well, the good news so far is that although it took a few months, his doctor’s managed to find the right mixture of medications and doses that not only does he not show many signs of the illness, but he’s actually changed and became more sociable then he had been prior in his life. It’s a struggle every day, not just for him, but for all of us involved, and it’s gotten to the point that most of my medical issues are ‘put on the back burner’ as they say. I don’t mean this is a “Hey, I’m sick too, pay attention to me…” or anything along those lines since I’m sure I could come up with better reasons for people to pay attention to me and trust me, I hate being sick and dealing with all the issues I have.

Keeping that in mind, this is my blog after all, so might as well update you on a bunch of my fucked up problems too… It’s been about 4 or 5 months since I started seeing a psychiatrist (again) and it seems to be helping although we haven’t really talked about anything specific really. For example after I originally got sick my doctor (oncologist) advised to me to go because of the inherent depression and/or denial most Cancer patients initially feel and that doctor (psychiatrist) said in our very first meeting something along the lines with: “Let me start by saying, I don’t have cancer so I can’t pretend to know what you’re going through and if it’s something you want to talk about, we can, however I suggest, at least for now, we focus on non-cancer related issues because it ‘may’ help in the long run.” And for some reason, that statement just clicked and although we didn’t ignore the cancer, instead we started out talking about my experiences in the Military and moved on to some other general topics, giving me a feeling of ‘normalcy’ instead of the typical ‘Why me?’ that a lot of people go through. Fast forward to the current doctor and none of the medical stuff has really come up… (yet). We did the typical start where they ask the basic questions about your past and shit (for paperwork, not really for ‘where do we start?’ kind of thing) so we talked about the military for like 20 minutes total, some other ‘big’ events in my life, yadda yadda yadda… and the main focus most of the time is about a 50/50 split between a girl or about the fact that over the years, I’ve pretty much stopped going out and socializing, never have any friends over… barely have any contact other than the occasional conversation online or going to/from different doctors. There’s been times where I was just like “Fuck it, I’ll just go to a bar and see who’s around” but either something comes up (no money, too much pain) or I get there and the fucking place is empty so there’s no one to talk to anyway and I’m not going to spend $2.50 – $4.00 per beer when I could buy some and drink alone at home drowning my sorrows… which defeats the purpose.

Not that anyone would care, the girl mentioned isn’t a potential girlfriend or anything remotely interesting… and I’m only clarifying that because I slipped up and just mentioned my blog to her so there’s a chance she may read this.

Enough of the ‘head shrink’ type of stuff and we’ll move on to the fact that I’m pretty sure my memory is getting even worse and I’ve started to notice other issues I hadn’t seen before. Thankfully I’m not hearing voices or anything along those lines, but I’ve noticed a few times while talking for example I would either slur my speech or outright screw up a word. I’m not talking about a simple Freudian slip, but saying something like I did on a recent phone call where I asked a friend “Can you come over and help me move a pen” when I meant a fucking couch. But the more common thing I’m noticing is my hand-eye coordination which doesn’t seem to be affected while I’m typing for example, but there’s a game on my iPad that I play a lot when I get bored but I’ve noticed that when I reach to touch a box I swear my eyes see my finger over the correct thing, but when I touch the screen I’ve either hit the box on the right or above the one I want… I’ve tested the sensors on the iPad and confirmed it’s not the device malfunctioning but it’s my sight. I can’t even play the game with my right hand anymore because my hand will shake too much that I can’t keep my finger steady (I’m left-handed) and it makes it so I can’t play while laying on my left side which most of the time is the more comfortable position for my back and leg. Thankfully at this stage it only appears to be an issue when I’ve been awake too long so it might just be as simple as that, but having insomnia for around 15 years now I’m unsure what is ‘sleep deprivation’ or potentially something scarier.

As I stated, thankfully I’m not at the point where I’m hearing voices, but I do hear some noises that I have no real proof if they’re real or not since most of the time when I ‘think’ I heard something, it’s usually something in the distance and never really gives me a ‘that could be someone talking’ type feel, it’s more like a tapping noise or other sound that can usually be explained away.

Enough depressing crap, let’s move on to something new that I’m doing to help keep my mind off the above…
§ Replacement to College §
I finished college years ago at this point, but while working on a new project last week I got stuck trying to deal with some database injection among other things. It turned out that the imports I had written worked fine but due to some PDO limitations I couldn’t do everything required via AJAX and had to rewrite parts of the database to accommodate the changes. While doing research on the problems I decided to check some of the tutorial sites I’ve used in the past like Udemy and although none of the free stuff they had would give me the required knowledge I had some coupon codes that allowed me to purchase over $2,000 worth of courses for a very sizable discount. Udemy isn’t just for programmers, the have all sorts of courses covering Photography, Learning languages, Health & Fitness, Music and more… some are even free. With full disclosure, Udemy has not sponsored or endorsed anything said here, but if you click this link, and sign up you can receive $5 in credit towards your first course.

§ Closing §
There’s a lot more that I had written and amazingly there’s still some that I remember, but it’s almost 5am so I’m going to post what I have so far and create some voice memos to remind me of the other topics and will hopefully remember to write again soon.

Category: Misc. | Tags: , ,

Destiny….

Posted on by

Like every year around E3, people go nuts about new games and this year is no different… There’s a few games that have really peaked my interest. I have to admit the latest from Bungie, original creators of “Halo”, the aptly named “Destiny” which is planned to have content for the next ten (10) years… giving you the potential feeling that your character will have a real destiny, was something that I had mixed feelings on. Don’t get me wrong, it looks fantastic, seems like it has an interesting story but the way my gaming habits have changed I wasn’t sure if I wanted to dive into something knowing it’s supposed to be this expansive, so I haven’t pre-ordered it and actually started to kind of ignore some of the videos and news about it. That is, until tonight when I got my Destiny Alpha code… at least now I’ll have a chance to check it out before doing the typical ‘plop down $65 and hope it’s good enough to keep my attention for more than a few days/weeks’. I was originally going to pre-order the game to get the Beta code and just cancel the order before release (if I decided not to get it).

Destiny

I don’t dare install it until tomorrow or Sunday since I know if I do I wont get any of my other work done and I really got to finish cleaning so I don’t have to listen to any more bitching. Funny thing was, if I didn’t get the Alpha invite, I was going to finish Watch Dogs before doing another run of South Park: The Stick of Truth.


Side note, I have a lot of other stuff on my mind that I was going to write about as well, but I’ve procrastinated enough on some of my ‘required’ work.

Category: Misc.

Random Stuff, plus some updates to the custom protocols…

Posted on by

*What I’m watching or Listening to Now*

Not much of anything since one of my 3TB drives died and took just over 2.5TB of video with it.

*Custom Protocols Update…*

First things first… (Using latest version of browser mentioned)
Firefox:
“Sublime Text” Protocol: Completely working
“Speak” Protocol: Does not encode/decode properly… (fine in Chrome) a.k.a. “This is only a test” whether urldecoded or not gets converted to “This%20is%20only%20a%20test” (since %20 equals a ‘space’) therefore NirCmd will actually say “This percent twenty is percent twenty only percent twenty….” etc.

Here’s the fix for ‘Speak’ in Firefox: (Will only work if you have PHP installed on your development system)

@ECHO OFF
TITLE Archigos NirSpeak
MODE CON COLS=50 LINES=3

ECHO.
ECHO                 Ignore this window

FOR /F "tokens=1,2,3* delims=/" %%a in ("%~1") DO (
  SET Protocol=%%a
  SET String=%%b
)
FOR /F "tokens=1* delims=" %%a in ('php -r "ECHO urldecode('%String%');";') DO SET Talk=%%a
nircmd speak text "%Talk%" && EXIT

Chrome:
I’m not sure when (too lazy to look it up), but with one of the updates to Google Chrome they essentially blocked the use of custom protocols (also called “Handlers”) to a certain extent. The new rules are something akin to your web application “must register the custom URI into Chrome and that it MUST be from the same domain”. This is mainly for security in Chrome Apps, but since we’re doing it for testing, I doubt any of you that are willing to write the C++/C# code required for URI Registration would bother with doing something like this… (however, if you’re interested, you can read about that here.)

Thankfully, getting around this limitation is rather easy for what we want to do, but be warned, make sure you fully trust whatever protocols you use with this method because it essentially turns off all of Chrome’s security for them. Both my Sublime Text and Speak Protocols are safe if you follow the directions, but you could essentially write one that could do harmful actions very easily.

Open up the command prompt and enter the correct location from below based on Operating System:
On Windows 7/8/8.1, the path is: %LOCALAPPDATA%\Google\Chrome\User Data
On Windows Vista: %USERPROFILE%\AppData\Local\Google\Chrome\User Data
On Windows XP: %USERPROFILE%\Local Settings\Application Data\Google\Chrome\User Data

Once the window opens, you have to make sure Chrome is CLOSED because it writes data to the “Local State” which you need to edit (preferably in Sublime Text). If you need to open the “Local State” file in a different editor, make sure that the application doesn’t append a file extension (ex. *.txt)

Inside the “Local State” file, which is in the JSON format, you’re looking for the section called “protocol_handler” which should already have a few entries in it and look similar to the following (line numbers are for demonstration here, the section should be kind of close to the bottom):

  "protocol_handler": {
    "excluded_schemes": {
      "afp": true,
      "data": true,
      "disk": true,
      "disks": true,
      "file": true,
      "hcp": true,
      "javascript": true,
     "mailto": false,
     "ms-help": true,
     "ms-windows-store": false,
     "news": false,
     "nntp": true,
     "shell": true,
     "snews": false,
     "vbscript": true,
     "view-source": true,
     "vnd": {
       "ms": {
         "radio": true
       }
     }
   }
 },

Once you find it, you’re going to want to add two lines to this file (I placed them so they stayed alphabetical like the rest)… setting the value to ‘false’ means that the protocol will be used, and ‘true’ means ignore it for security reasons.

  "protocol_handler": {
    "excluded_schemes": {
      "afp": true,
      "data": true,
      "disk": true,
      "disks": true,
      "file": true,
      "hcp": true,
      "javascript": true,
     "mailto": false,
     "ms-help": true,
     "ms-windows-store": false,
     "news": false,
     "nntp": true,
     "shell": true,
     "snews": false,
     "speak": false,
     "subl": false,
     "vbscript": true,
     "view-source": true,
     "vnd": {
       "ms": {
         "radio": true
       }
     }
   }
 },

As you can see on lines 17 and 18, I added both protocols that I created and made sure to match the names used. If you only created one of them, do NOT create an entry for the opposite one. Save the file, open Chrome, test your page with the protocol examples… if you don’t have one, create a new PHP file accessible from ‘localhost’ and paste the following code for a quick and dirty test:

<?php
  $filename = urlencode(__FILE__);
  $string   = "This is only a test...";
  echo "<a href='subl://$filename'>Sublime Test</a><br />";
  echo "<a href='speak://$string'>Speak Test</a>";
?>

*Testing Environment*

A few people have asked once or twice about possibly doing a full write-up of my main test environments (both Web Design and HTPC related) so if people post a response on Facebook if they are interested in either (or both) I’ll possibly create a new page on this site dedicated to it (because it’ll probably be multiple posts and pretty long).


*In regards to last post*
I left this to the end of the post so those looking for the technical stuff above could skip it.
The person I was talking about still wishes to stay anonymous for as long as possible, mainly due to the stigma I had previously mentioned, but stated that since I mentioned it already I could give a little update. Now, it’s not uncommon for people undergoing the initial changes from mental illness to think “No, I’m normal, if you don’t see/hear/etc. it the way I do, you’re the one that’s wrong” and I think the main problem with the first few sets of doctors were that they did NOT take this into account and observe the behaviors shown and it didn’t help, that he apparently withheld a lot of information for this same reason. I think it was around the third set of doctors we found that started to notice not everything was being said, or that some things being said weren’t necessarily the truth (not that he was intentionally lying, it was based on his ‘distorted’ point of view). This doctor narrowed things down to the point where they debated on if it was some form of extreme bi-polar disorder or (as I suspected) Schizophrenia, the latter ending up being the actual diagnosis.

I think when I was invited to see the doctor with him so the three of us could talk together and I could point out my observations or when details were misinterpreted helped him realize the extent of the paranoia and other symptoms were. The doctor gave him a different type of medication and although most of the symptoms seemed to lessen, you could tell he was still struggling with things. Thankfully, sticking with the current doctor, changing medications and/or dosages a few times, and other forms of support, he seems to have gotten most things under control and for the most part, none of what is going on is noticeable to those that weren’t told at least something prior.

Category: Misc. | Tags:

A lot… of random… well, life happens!

*What I’m Watching or Listening to Now*
Who cares?

*Random Question* OR *Random Quote*
No really, who cares? Actually, the real question is the age-old… “Why do bad things happen to good people?” Don’t get me wrong, the ‘good’ person in question is far from a Saint, but they never really did anything to anyone, in fact, for the most part, they just kept to themselves.

I know a common theme in a chunk of my posts is about wanting to write more often, but this is one of the rare cases where I didn’t ‘forget’ or ‘just didn’t get around to it’ and had a real reason to not write. The person mentioned above hasn’t given me permission to write about them so I’m not going to post many details and try my best not to identify them in any way (other than he’s obviously male). Mental illness is something that a lot of people in today’s society look down upon and sadly way to many people view people with pretty much any form of mental illness as inferior. There’s varying forms of illness and in almost every case the person suffering is in no way at fault for what they must endure. Yes, I’m rambling, and I don’t give a shit… there’s so much going through my head, especially what they are going through, how quickly it seems to be progressing, and the fact that there’s nothing I can do to help them.

I’ve dealt with my share of doctors the last few years since my issues started, some were wonderful, some were complete fucking idiots, but in my case, after the initial scans, the doctors all agreed, “it’s cancer” and after going to a specialist and another set of scans, they figured out what kind… Now the treatment for it was another story altogether, but my point here isn’t trying to lessen the seriousness of Cancer and I know there’s many patients that have it a lot worse than I did, but to say that’s there’s a big difference with doing a body scan, finding a tumor and saying, “here’s where we have to concentrate on” as opposed to admitting that as humans and all the advancements we’ve made, there’s still a shit load about the human brain that we just don’t understand. Case in point, the many doctors that he’s gone to see have all been utterly useless to this point, either saying things that a kid that barely passed high school biology would be like “Um, no, that’s not right.” or essentially just says “Here, take these pills and it’ll fix it” when those pills aren’t even related to anything remotely close. It’s like giving thyroid medication to a guy that accidentally cut off his finger and saying “This should make it grow back.”.

Even my extremely limited knowledge of mental illness, the different kinds, etc. lead me to believe that all the things I’ve witnessed him demonstrate over the (roughly) last two months point towards Schizophrenia and as I said above, certain aspects seem to be progressing. It’s difficult to talk openly about things like this considering the perceived stigmata attached and I’ve been meaning to do research (not just on the disease, but on forms of help, like hotlines, etc.). In fact, after I finish this post, I’m going to start said research and make a few phone calls.


There’s so much on my mind, about this, about my medical issues (which have been causing some more difficulties lately as well), projects I’m working on, etc. The list could go on for pages but I’m sure that’ll just drive away the few readers I have left. But on a two-part closing note, I wanted to thank a good friend of mine that I know reads this blog and I’ve talked with about all of the above stuff and even though he doesn’t even live in the same state anymore, he’s been there and is the only person I trust to talk with about this stuff (at this stage anyway). If and when things become a little more public I may revisit this topic in more detail, describing some of the things I’ve witnessed first hand, outlets for people to find help or anything else that I’ve learned and think may help others in similar situations. The second point is most of the readers that view this (if they’ve stayed around this long) probably came from a link via my Facebook page and if you know of any good resources (other than Wikipedia) about Schizophrenia including hot-lines or whatever (please no links to buy a book on Amazon or things of that nature) please comment on the Facebook post with the information. Lastly, please refrain from negative comments, guesses at the person’s identity, or general assholeishness as this is a sincere request for help and/or information.

Category: Misc.

Quickie Custom ‘Speak’ Protocol

I mentioned on Facebook I was thinking about adding the second protocol I did and also about changing this to a more tech related blog… Well, here’s the “Speak” protocol and I’m still debating on if/when I may do the blog changes.

If you came directly to this post, read the previous one to get an idea about Custom Web Protocols and an idea of what’s going on.

*Required Software*
For starters, this protocol uses some freeware called NirCmd (by NirSoft) which can be downloaded from the bottom of this page. Make sure to download the correct 32bit/64bit version and after you extract it, copy NirCmd.exe to your Windows\System32 directory either manually or by running NirCmd (it offers a button to copy it there automatically).


If you still have the *.reg file from the “Sublime Protocol” you can make a copy of that file and do some simple changes to create this, or if you’re starting from scratch open “Sublime Text” (or your favorite text editor… yes, even Notepad works) and copy/paste the following into your document. Don’t forget to save it with the *.reg extension.

Registry File
Warning:
Modifying the Windows Registry can be hazardous to your computer and cause data corruption, data loss, or just outright kill your system, therefore proceed at your own risk and I will not be held responsible for any damage you may/may not cause. This registry file has been tested and deemed safe on both Windows 7 and Windows 8 but has not been tested on XP or Vista.

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\speak]
"URL Protocol"=""
@="URL:SpeakText"

[HKEY_CLASSES_ROOT\speak\DefaultIcon]
@="C:\\Windows\\System32\\shell32.dll,282"

[HKEY_CLASSES_ROOT\speak\shell]

[HKEY_CLASSES_ROOT\speak\shell\open]

[HKEY_CLASSES_ROOT\speak\shell\open\command]
@="C:\\Windows\\System32\\cmd.exe /K nirSpeak.cmd \"%1\""

Notes:

  • If you change the trigger for the protocol (speak) it needs all five references changed.
  • The double \ in the file paths are required.

The last line needs to be altered if you change the name of the Command/Batch file or you get a security error for running the Command Prompt (see previous post for info on this and how to fix it).

Batch File
Taking the name from the registry file, in this case “nirSpeak.cmd”, we create a new empty document with that name and copy the below code into it.

@ECHO OFF
TITLE Archigos NirSpeak
for /F "tokens=1,2* delims=/" %%a in ("%~1") do set protocol=%%a&set str=%%b
nircmd speak text "%str%"
exit

*Using*
There’s one large difference between this and the previous protocol (other than the obvious usage) in which this does NOT encode/decode the information sent which changes a few things with the usage. With the Sublime Protocol for example, if a filename contained a space, that would be converted to %20 and back again where required, but the Speak Protocol would actually say “percent two zero” if you tried to manually encode it. The easiest way to create speech is to create a variable with the entire string you want and than just putting the variable into the URI (which also prevents certain errors due to spaces like speak://multiple words would. It wouldn’t cause a PHP error, but NirCmd would most likely error out or only say the first word).

A great example of how you may want to use this would be to greet your user after they log into your site.

$username = $_POST['username]';
$greeting = "Greetings ".$username;

And then you’d use a JavaScript function or similar to invoke it (in this case: speak://$greeting) on page load or whatever. You could also use buttons or inputs in a similar fashion, like the button I use on one of my sites that reads the stats to the user.

echo "<div class='speaker'><button onclick=\"location.href='speak://$greeting'\">Totals</button></div>";

*Final Thoughts*
Obviously both this and the Sublime Protocol could benefit from hiding the Command Window that is spawn but I wanted to write these using as little third party software as I could to make it easier on the reader. Oh and for those that want to play around with the speech function there’s a bunch of information on NirSoft’s website, but for the lazy, open a command prompt and type nircmd speak text "Hello World" and it will say whatever is between the quotation marks.