Learning C# for XNA
I have decided to teach myself C# so I can create games using XNA. WOOT!
I have a good start and will hope I can develop a game for the XNA constest where I can hopefully win (with a lot of luck) and get a small game published.
|
April 22, 2009Learning C# for XNAI have decided to teach myself C# so I can create games using XNA. WOOT! I have a good start and will hope I can develop a game for the XNA constest where I can hopefully win (with a lot of luck) and get a small game published. February 9, 2009Format Phone Number Fields with PHPBelow is a function I wrote to take a phone number entered by a user and convert it into a desired format. The one shown below is 555-555-5555. View Code PHP
Therefore to see it in action: View Code PHP
November 28, 2008The Epiphany EngineAfter the creation (or rather the start) of Dragon Seed. I really like the coding that went into it. So I decided to build an online game engine that would let people create simple top down view games – just like the way I made the rough of Dragon Seed. I went to work on the Epiphany Engine. Some features:
August 5, 2008Javascript broke with multiple line variables from PHPI have several sites where I use a pop up table to display information if the user rolls over and image. Example, if the user wants to view notes on a certain client, they can roll over a little “note” image to view the notes about the client pulled from a SQL database. The code I use for a message may be: View Code JAVASCRIPT
That would work if $message was all one line. But as with all notes fields, you can never determine when the person entering data hits “Enter”. If the person did hit enter, your javascript would be broke and it would look like this in the source code. View Code JAVASCRIPT
This broke the Javascript. To fix this you can just swap the hidden special characters with a html line break. Working code: View Code JAVASCRIPT
This would return: View Code JAVASCRIPT
July 18, 2008Page Forwarding using Meta TagThis code goes in the <Header> along with all other Meta info. View Code HTML
Creating a Pop Up Window with JavascriptHere is how to create a simple pop-up window using java script. This will create a pop-up window on page load: View Code JAVASCRIPT
Here is how to create a Pop Up Window from a link: View Code JAVASCRIPT
This part goes in the link tag: View Code HTML
July 1, 2008Creating a perminent redirect in the .htaccess fileA search engine friendly way to redirect an old page to a new one is to add the following line in your .htaccess file. “Redirect permanent /old-page.html http://www.newsite.com/new-page.html” Direct the ErrorDocument 404 to a webpageIf you would like the “404 Webpage Not Found” error to redirect to another page on your website – just simply create (or edit) your .htaccess file. This file should be at the root level of your site’s directory where your root webpages are stored. Add the following line: “ErrorDocument 404 /pagename.html” May 23, 2008PHP Dynamic VariablesLet’s say that you have a bunch of data in a recordset and you want to populate that data into a list of variables. In my example we will draw 20 items from a players inventory from a MySQL table which stores all the items for a player in rows we call “slot_1, slot_2, slot_3, … all the way to 20″. So when we pull all of the items from the MySQL table we want to assign them to variables respectively. For example, our variable of “slot_1″ that we are creating will equal “slot_1″ from the MySQL table. View Code PHP
If we were to update the MySQL table with a dynamic variable, it would look like this. View Code PHP
Merchant System and Guard AbilityI have added a Merchant System and Guard Ability to the game now. The player can now purchase and sell items. If they player tries to sell a weapon, shield, magic, or armor that is the only one left in their inventory – a warning message will appear letting them know if they sell it it will be unequipped and removed from inventory. This prevents the player from accidentally selling an item they have equipped. The player will also have the option of buying any common weapons, shields, armors, or magics in the game. If they do not have enough money or if all their inventory is full the player is notified. A guard option is now available in battle in case the players other commands are rendered useless. In example, if the player has no mana to cast a spell and their attackhas been rendered useless by a spell. The player can guard to boost their armor by 33% for that turn. |
||||||||||||
| © - Digital Epiphany Designs, Online Portfolio for Web Design, Custom Programming, Grapic Design and Game Design. | |||||||||||||