Share This!

Wednesday, April 25, 2007

Monday, April 23, 2007

This is NOT going to be easy

Ok, as I said I am a long-time Delphi Programmer. I have always loved it's easy user interface. So I downloaded Google Sketchup because my life as a Poser 7 artist has found me wanting for architecture.

Sketchup is a great tool to quickly imagine detailed outdoor urban settings. It has a few drawbacks though.

  1. It has no photorealistic rendering engine
  2. The free version can't export to a usable format
  3. The paid version is $500 (it's worth about $50)
  4. You can design rooms with an interior, but it's not easy.

So between that and the room designer for The Sims Online, I figured that I would try my hand at writing a C# program that would allow me to simply create and edit buildings and/or rooms. I must admit that I find C# really a difficult language to even approach this problem.

Questions:

What kind of object do I put in a form to draw on? A TPanel? a TPicture? It's not obvious.

What is the best way to create an in-memory XML Object that will store my object data in a hierarchy while I edit?

How do I draw and select from a canvas? like this? I love the way you can select boxes, arcs, and circles on any surface in Sketchup. I love the way to can match the extrusion of one surface to any other. But in C#, I can't even find a way to create a rectangle selection tool.

Another project dead on arrival :P

Monday, April 9, 2007

Sims Sitter 3

I like to play The Sims Online. Unlike the Sims 2 (which I have not played), the little cartoon characters do nothing unless you tell them to. They would literally starve to death standing next to a buffet table if you don't tell them to eat.

Doing anything fun in the Sims Online (TSO) requires you to build up your skills. Here's how fun it is building skills:

  1. select a skill
  2. find a skill house that does that skill
  3. go there
  4. choose the skill item and your sim will start using it (like weight benches for body skill)
  5. skill for about 20 hours to max the skill.
  6. Every hour or so, you need to green (eat, sleep, shower, pee)
  7. Every 15 minutes TSO will log you out for inactivity if you haven't clicked your mouse or typed a keystroke into the Sims window.
The fact that it takes so long and you must stay on the skill object makes skilling
  1. boring
  2. perfect for when you're away from the keyboard (afk)
The only gotcha there is that when you're afk, the inactivity warning comes up and logs you out every 15 minutes. So some guys made this thing called SimsSitter. Don't bother downloading it, Maxis has defeated it's effectiveness with a recent update. That's what prompted me (as a programmer) to write SimsSitter2 in Delphi. It's the same thing, but it works with the changes Maxis made to the program that make SimsSitter not work. Now I want to redo it as a learning experience in C Sharp. Here are the design specs...
  1. must wait for a delay of less than 15 minutes (5 should be optimal)...
  2. must get a list of all the windows from the OS that have the caption "The Sims Online"
  3. must bring each of these to the top and type some keys to keep the window active ("A" then Backspace should work nicely)
  4. must be able to stop and start it's timer with a button click (like the original)
Nice to haves:
  1. blink it's icon for 5 seconds before it takes control so the user can pause what he's doing.
  2. restore whatever window was on top when it's done.
  3. if it could recognize when your sim stops skilling and stop pressing keys for you that would be peachy (because you will die if you forget to green)
Ok. In Delphi the main thing I needed to accomplish this were the Timer Object, the EnumWindows API call and the SendKeys API call. So I opened a project in Visual Studio and called it SimsSitter3. I found the timer object and was able to set it to 5 minutes right away, and watch it trigger. Piece of cake so far. Now, where is the enumWindows procedure? I found a reference to it here. They seem to be interested in building a list of running windows, but I need to iterate through and put the system caret on that window if it's title matches my template.

Contact Us

Name

Email *

Message *