Monday, March 8, 2010

PBBG Domain of Heroes

I don't know how many of you have actually looked into PBBGs. It stands for Persistent Browser Based Game. They require only a browser, and store information about you. Now, I've never tried any but the RPG's, however, I've found them fairly nostalgic. If you ever played any old school text based video games, these may fit the bill.
For me, it is like one of the old choose your destiny books. Where you can take actions, and influence the quest. I've been amazed at the amount of creativity and time that have been put ino them. The current one I've been toying with, is Domain of Heroes. It is a much more "hands off" version than I've seen before, with a very interesting business model. I say hand's off, because you queue to fight monsters, and it will continue your last action, and continue brining in monsters, until you time out. Every action resets the time out, or you can walk away. I'm enjoying it, because it can be played while playing other games.
The business model is very comprehensive. They have a "wish" system. You can do account upgrades or character upgrades for wishes. Wishes can be either bought or earned. (For example, if you refer others to the game, you get a percentage of wish for every wish they buy.) The purchases can be astetic, such as changing your chat color or getting an icon next to your name, or functional, such as increasing inventory and collection capacities. In additon, there are "ease of use" upgrades that are intersting, such as allowing you to type in longer messages in chat (you are initially limited to 50 characters) or making it so you can join a guild. Anyhow, this specific one has held my insterest for longer than others, so I figured I'd share. If you're interested, you can check it out (and hook me up) by using this link http://www.DomainOfHeroes.com/?rpid=60267 . If you do choose to try it, I suggest reading the quick start guide before you dig in, it is fairly short, and you'll be better off for it.

Friday, March 5, 2010

Enitity Framework CAN Support Stored Procedures That Do Not Have A Return Value

I didn't realize this, but apparently there articles that state that EF does not support procedures that return no result. This surprised me because I've been doing that in my application.

To Do So:
When you import your objects, make sure the stored proecure is imported. Next go to your Model Browser, and go the the EntityContainer in your Model. Right click Function Imports and add the name of your stored procedure.


Once you have done that, you can call the procedure through EF in the following manner:

//Create the Context then set up a DbCommand.
YourEntityModel.sprocContext = new YourEntityModel.();
DbCommand command = sprocContext.Connection.CreateCommand();
command.CommandText = "YourEntityModel.yourStoredProcedure";
command.CommandType = CommandType.StoredProcedure;
//If parameters are needed
DbParameter parameter = command.CreateParameter();
parameter.DbType = DbType.Int32;
parameter.ParameterName = parameterName;
parameter.Value = value;
command.Parameters.Add(parameter);
//Excecute the command
DbCommand nonQuery = (DbCommand)nonQueryObject;
nonQuery.Connection.Open();
nonQuery.ExecuteNonQuery();

It is as simple as that.

Wednesday, March 3, 2010

Fisher Price Cradel Swing Uses the Same Motor as Air Wick Fresh Matic

   I had to post this, for the simple fact that it astounds me. Yesterday, our baby swing, a Fisher Price Cradel Swing crapped out on us. The music and mobile continuted to work, but the swing, did not, in fact, swing. So loooking around, we found that the cheapest model in stores is around $70, which was a bit pricey for me at the moment. So instead, I appealed to the internets to resolve my solution, and I stumbled on the following site:  http://www.fixya.com/support/t1101519-fisher_price_natures_touch_cradle_swing An lo and behold, it says that with an hour, and an Air Wick Fresh Matic you can replace the motor in the swing and it would fix it.
   At $11 for the air wick, I figure, what the hey, I'll give it a shot. Long story short, one dismembered air wick (it uses triangle bit screws, I don't have that, but I do have two pairs of pliers tougher than the plastic), a cut thumb, and a bit of sweat later, the swing swings again. So, crazy, ya? Anyhow, thanks to the internets for saving me $60.
  For anyone who actually tries this, it is possible for someone who isn't incredibly mechanically minded, however, you'll probably disagree with me half way through.