Pages

Sunday, April 22, 2012

Today I learned the garbage collector and OpenGL do not cooperate

So I thought I'd be clever and write a finalizer for my Texture class so that it would call GL.DeleteTexture when the object was collected. Apparently I can't do that. CyberpunkRL has been a good source for learning new things about using unmanaged libraries in C#... except for the fact that I waste hours of my time trying to figure out these things.

In other news, I switched over to the new renderer with little trouble. All traces of SDL have been eliminated. Here it is in action, looking pretty much exactly the same as before.
Doors!
I also got an infinite world implemented, but I'll eventually limit it to a finite sized city, like in the original releases. Unlike in the original version of the game, you move seamlessly between sub-maps, so no more running from cops by moving off the edge of a map.

I also made a few weapon icons.

Edit:
 

5 comments:

  1. Hi! I can't download CyberpunkRL - the files seem to be missing from FileSmelt. Can you make the alpha version available again? Thanks!

    ReplyDelete
    Replies
    1. I uploaded a previously unreleased version of the old CPRL as 0.2a. It should now be available on that page. Be warned that it's very old and, honestly, kinda sucks.

      Delete
  2. This comment has been removed by the author.

    ReplyDelete
  3. You've removed all traces of SDL, but you are still using OpenGL. Does this mean that non-Windows platforms may still be supported through Mono?

    ReplyDelete