Jump to content

Mord's Blog

  • entries
    170
  • comments
    93
  • views
    98,663

Procrastination means I'm on the right path!

Sign in to follow this  
Mord

188 views

Or so I'm letting myself believe. I'll find out later if that's true though.

 

I've been thinking over the code needed for what I described in the last entry and I think I have a good idea what's needed. It just feels real ugly. :skull:

 

I hate ugly code. :ponder: This is why I'm thinking about it more than coding it. I want to make the code as simple as possible, yet as understandable as possible. (For me if nobody else. ;) )

 

As a result serious attempts at the code are being put off little by little as I think about it. I just know if I rush this it's going to blow up in my face spectacularly. Heck, initial stabs at the player/playfield only kernels blew up spectacularly at first due to stupid semantic errors. While I was hoping to have a version of it at least written by the weekend it looks like there's a chance I won't even start a serious stab at the code until then.

Sign in to follow this  


2 Comments


Recommended Comments

Sometimes ugly code is unavoidable. What you aim for is code that is as efficient (bytes & cycles) as possible.

 

It's also usefull to sometimes step back and take a look at the problem from a higher level and see if there are other ways of accomplishing the same thing.

 

For instance, with Leprechaun I originally copied the player sprites into a SC-RAM bitmap, but I discovered that was taking up far too many cycles. With some help a better BLIT routine reduced the time required. But the final solution was to copy the pointers instead and rework the kernel to use the pointers instead of a bitmap.

 

(I don't know how many times I've reworked the kernel for Leprechaun. More than I care to count.)

Share this comment


Link to comment

Aye, I'm more than aware that ugly code will have to be written at some point, and some point -soon-. ;)

 

Although I'm glad I randomly poke around the forums and stella in case I stumble upon things that'll help me in the days ahead. Which will bring me to my next blog entry. :D

Share this comment


Link to comment
Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...