Sunday, 23 September 2018

Being simple

Finally solved the display map synchronization problem I had for a long time. The underlying problem was my inability to think the simplest possible solution. In programming almost always the simplest solution is also the best one, because it's going to reduce the number of places things can go wrong.

I solved this in Teemu where I was adding support for multiple items per tile. The solution was so simple it just came out from nowhere. It's sometimes difficult for a highly creative person like me to think in simple way, but it's something I'm trying to do when programming. I try to be a simple person and it's probably the most difficult thing to do for extremely intelligent people in my experience. Although even harder for me is how to get women. It seems to be impossible for me and sometimes it makes me sad.

I'm also going to import the "flight package" routine from Teemu. It adds flying items into a list and then throws them at the same time, rather than go through each creature and make them throw items one at a time. When items are flying at the same time they could even hit each other. For example you run into an archer who is about to shoot you, but you can throw a large item and intercept the flying arrow.

No comments:

Post a comment