Friday, September 03, 2010 23:14

Church and Damnation

April 12th, 2010

Someone recently mentioned a description of church to me in part as “Oppressive Culture”. I haven’t yet had a chance to clarify that description with them, but it struck me as a very odd description, and I’m seeking to understand what was meant by it.

The only thing I can think of is the idea that’s common among the unchurched* of church being a place where we are told to behave, and if we don’t then hell awaits. I think this is a fundamental misunderstanding of the goals, actions and role of the Church. I can understand, however, where this idea comes from; we see it often in street preachers and tele-evangelists, we hear it when we think of Westboro Baptist Church* and, of course, we hear it from the unchurched. When we think of “Church History”, we also conjure images of crusades, witch hunts and inquisitions. so it’s not as if these ideas of “behave or suffer” are unfounded. It’s not indicative of the Church as a whole however – merely indicative of vocal minority groups (of which most Christians would not condone), or indicative of horribly mistakes made by the organised Church.

I’ve been an active church member for around 5.5 years now, and never have I been threatened to go to hell. Never have I been manipulated into doing anything that I didn’t want to, with the pain of excommunication or damnation. There has never been a “turn or burn” preached at my church, or any church I’ve attended. Indeed, I believe that kind of behavioural conditioning is completely unbiblical and anti-thetical to the Christian message.

I struggled with attempting to correct other people’s actions for a long time. I would say to coworkers “watch your language,” not because it was unprofessional, but because I don’t think it’s right. I would call people out on piracy and excessive drinking, because I somehow thought that “behaving better” was a goal congruent to Christ’s.

I’ve realised since that my ideas there were completely bass-ackwards (I think I’m far more tolerable/tolerant now!). Christ did not create His Church in order to make people good citizens, or helpful people. His goal was far more radical than that – to bring people unto Himself. You see, it’s rather unique as a religion – the idea that no matter how much we alter our behaviour, we cannot redeem ourselves. Everyone is in the same boat – whether they’re Mother Theresa or Stalin.

The problem with thinking altered behaviour is a goal is the receding horizon.

Let’s say an unchurched person wanders into a church that says don’t be bad, or you’ll be dining in hell. They start treating their kids with respect again instead of beating them. They stop holding up liquor stores, and get a job instead, because they know that stealing and beating will send them to hell. Is that enough? Are they good yet?

He returns to church, which says that even little bad things will send him to hell. This person stops gambling, stops lying to their coworkers and boss for gain because they know they’ll go to hell if they continue to do these things. Is that enough? Are they good yet?

The church now says that it’s not enough to simply be “not bad”, but they have to be good, or else hell awaits. They start giving to charity, they volunteer at homeless shelters. Is that enough? Are they good?

I’d say a church doing the above has probably done a good job at getting someone to behave correctly, but they’ve missed the point. The person is not obedient due to a moral sense, but because of fear of reprisal. Outwardly, it may look ok, but inwardly, it’s not.

That’s why the Church’s goal is not to condition behaviour. It doesn’t change a person’s heart, and it presents a legalistic view of morality. Jesus’ main beef against the church leaders of the time (Pharisees and Sadducees) was this legalism. No, Jesus said instead to believe in Him, and the rest will happen. Change the heart, and the body will follow. The reverse isn’t strictly true.

Which is precisely why you don’t see Churches today saying “Stop doing X or you’ll go to hell”. It’s futile. If X is gone, Y, Z, alpha, beta and epsilon will still remain, and the person won’t truly be changed. Plus, the commandments “Love the Lord your God” and “Love your neighbour” (which are the pillars of all the other commands) cannot be done out of fear, or even effort. We are ALL in the boat of not being “good enough”, and no behavioural conditioning will change that.

But in following Christ, asking forgiveness for our wrong doings (which is offered freely), and receiving His grace (again, offered freely), we can be free of the cycle of trying to be good enough. And with the love of Christ to guide and transform us, it will come naturally to “behave”. THAT is the goal of the Church. Turn to Christ. Then, being good will follow.

The simplest response to this is “Well, you’ve just moved the line from “Be good or burn” to “Follow Christ or burn”. How is that not oppressive? Well, the argument is then moved from morality to the truthfulness of Jesus as God, which is another story altogether.

I heard an atheist claim in a debate which was, in part, about the hope given in salvation. The claim was that atheists do not like the fact that the earth will be kaput in 5 billion years, but are under no illusions that it will remain forever, and it’s not a negative thing to be grounded in reality.

The same can be said for a Christian. We don’t like the idea that people don’t take the a gift of eternal life, freely offered, and thus have to face up to God’s other side – Justice and Holiness – and held to account for it all. But we’re under no illusions that this is the not case.

I made claims here that some will have scoffed at. Accept that under the Christian world view, these views are all internally consistent (with itself) and externally consistent (with reality). There’s no incongruency at all. At this point, the only beef you can have is with the truth of the claims of Jesus Christ. Saying “you will burn in hell if you don’t follow Jesus” is not immoral if it is true. Maybe it’s not sugar coated, tactful or politically correct – but it is the height of morality.

If anyone has any statements, questions or responses to this (or indeed, anything I’ve written), I would love to hear – either by comment, email, twitter, whatever. I’m putting my views and beliefs out there as a way for others to gain understanding of my point of view. I’m very interested in learning other’s point of view too, so please, let me know!

I think I’ll move away from these morality posts, and do a bit about evidence and rational reasons for believing. I believe following God is more rational than not, given the evidence (and lack of any real response to them – so often the response just comes back to morality).

Thanks for reading :)

1. I will use the term “unchurched” throughout this, as it’s the most neutral word I can think of to describe someone who has never been an active member of a Christian congregation.
2. Wow, I just noticed the wiki article for that ‘church’ says it’s a hate group. Not that I dispute that as such (I find their actions abhorrent), I would have thought that kind of description was against wiki’s NPOV pillar. Maybe not though, reading the wiki entry for “hate group”.

OT Laws – Good Then, Revised Now

March 22nd, 2010

I think I need to clarify on the Old Testament laws, and their application today. This is by no means a complete look at OT laws, it’s just a slice of some of them that helps us find perspective. It will mainly focus on laws that we look at today and think “That’s bad”. There are a lot of other ones we may say “That’d odd” or “That’s pointless” to today, but I won’t be covering them here.

Matthew 19:1-12 contains a conversation between Pharisees and Jesus. It basically goes like this:

Pharisees: “So, like, is divorce ok for any/every reason?”
Jesus: “No”
Pharisees: “Then why does the Law of Moses say it’s ok?” (see: Deut 24:1-4)
Jesus: “That Law was given because of your hard hearts, but it was not this way from the beginning.”

Yes, I missed a lot, but this is the part that pertains to my point. Read the passage, the rest doesn’t change the scope. God has a view of marriage – it is not in His design for separation to occur in any circumstance*. However, God knew that the people of the time would not accept that law, so He gave them a more relaxed law, that he knew they could obey. Namely, divorce only if something “indecent” is found about her, and no remarrying if she’s remarried and divorced/widowed.

It’s very clear that the laws given in Deut regarding this are less strict than that given by Jesus. “Indecent” changed to “Marital Unfaithfulness”. Has God’s standard for marriage changed? No, but He believes our hearts are softer regarding this – so He gives us a more strict moral standard, one which holds up to even today’s standards*. Indeed, this is much more moral than today’s standards, which state, “get a divorce whenever you want, really. It’s cool.” (If you disagree here about what is more moral, it’s probably because of different views of what love and marriage are and entail, so don’t jump on it straight away.)

This can’t be the only Law that was given that catered for the people of the time, certainly not. Take the slavery laws – Deut 21 vs Ephesians 9. For the times these laws were given, slavery was pretty much the global civic. It happened. The sermon on the mount (Matt 5) is almost exclusively dedicated to redefining the laws in a more moral sense – ones that stand up to even our greater global morals today.

So the most that can be said about the apparent harshness of the laws in the OT is that it was given in a context where people had hard hearts, and wouldn’t accept laws that were stricter than those.

Even with the Jews’ hard hearts, the laws given were better than what else was around then. You cannot equate laws of 5000 years ago with laws of today without taking cultural maturity into consideration. The laws were good, for their time. Now, well that’s another kettle of fish.

Furthermore, the 10 commandments are in play. The laws given aren’t the focus, the commandments are. The first 2 commandments alone are all that is necessary for all the other commandments, all the Old Testament and New Testament laws. Think of the 10 Commandments as the “What” and the Law as the “How”. Others see the 10 Commandments as “God’s” law, and Moses’ law as the “State” law. Church / State separation perhaps?

When it comes to today, the laws still have to be interpreted via the 10 commandments, and must pass the “filter” of New Testament teachings – I say filter, because nothing is taken away*, only narrowed down and simplified. Remember, God’s Law hasn’t changed, but our ability to respond to them has.

While I say nothing is taken away, a lot of stuff is rendered irrelevant. “Masters, love your slaves” obliterates the relevance of “If your slave loses an eye because of you, they can go free”. Of course, if you’re respecting them, then they won’t lose an eye in the first place. “Don’t Murder” is supplanted by “Don’t be angry with anyone”. And both of these are covered by “Love your neighbours as you love yourselves”, and more so, “Love your enemies”.

Stop focussing on OT law. It’s much clearer in the New Testament, from the same source (God), and is more catered to the state of our hearts. The very laws that govern our society come from these roots, and there’s very-near parity between them. Saying God’s laws are immoral, while touting our society’s laws is a lesson in contradiction.

If someone has objections about the morality of the standards put forth by God to us today as explained in Bible, I would seriously question their motives. The standards put to us (and lived out by Jesus to show as possible) are far better than any other set of moral laws ever invented.

Footnotes

1. Yes, it says except for marital unfaithfulness, so I’ll grant that exception. But then, I don’t think unfaithfulness is in God’s design for marriage either, so it’s a moot point.
2. Though, admittedly, there is controversy over this too – what about an abusive partner, for example? That’s another argument which won’t be covered here, as it’s a bit off-topic.
3. Not strictly true – the ritualistic cleanliness / worship ones are taken away, for example, because that context for worship is gone.

Slavery in Exodus 21: A response

March 11th, 2010

Background

Before I get into it, I think I’ll shed some light on why I’m responding to this in particular. The following twitter ‘conversation’ happened today, between me and a follower of a work colleague. I’m xwipeoutx, and I’ve changed the other guy’s name to “Other Guy”, in case he wants anonymity (though his twitter is public, so I’m pretty sure it doesn’t matter). Excuse my poor formatting… the style sheet on this blog only does so much.

Other guy: #Religous should not have these jobs.RT @BibleAlsoSays: Pharmacist refuses to issue pill because of her religion http://tinyurl.com/ykq5hbj
xwipeoutx: @[other guy] via [colleague]: Way to generalise. How about #thatperson shouldn’t have that job?
Other Guy: no! no religous person should have jobs like that if they don’t understand the basics about how the world works. #christianfools
xwipeoutx: no athiest person should have jobs like that if they don’t understand the basics about how the world works. #athiestfools
Other Guy: your stupid.B original @least loser bitch. How many children your religion has killed.Ill send u a news article that will tell u
xwipeoutx: Yeah, that’s not worth replying to. And they say we’re the intolerant ones.
Other Guy: you can’t. You need to have a base knowledge of reality. Something evolution has left out in you.

What followed was a long uhh ‘discussion’ between my work colleague and ‘other guy’ that didn’t end well, and then “Other Guy” followed saying something along the lines of “You will be hearing from me shortly.” I said I’d be happy to have a civilised conversation with him, and a few hours later, I got another tweet:

Other Guy: Its time so remind some atheist why we do this. Some are apologist. Like @[colleague]. #Atheist reads the bible http://bit.ly/a0akHj
xwipeoutx: Ooh, nice. Exodus. Read sermon on the mount? Jesus’ interpretation. Also, Eph 6:9.
Other Guy: how much do you enjoy cherry picking. Your doing it now.
xwipeoutx: I don’t actually have headphones, I’m at work, so I’m going from the descriptions of the video
xwipeoutx: But twitter is not long enough to explain this in detail, in any case. I’ll PM you my email if you’re truly interested
Other Guy: I see. Here’s another for when u have time http://bit.ly/9hcquU The Genealogy of Jesus
xwipeoutx: I’ll respond to them tonight, when I get home, probably via a blog post so it’s public.

I won’t have time to respond fully to the genealogy video tonight – and frankly, I couldn’t be bothered responding to it in depth at all, unless some more substance shows up. My quick response to that video is “…and?” Who’s idea was “Jesus’ sacred bloodline”? Who cares if Gentiles are in the mix? Did you see what happened AFTER David’s little midnight frolic? How does the usual response fail to take into account the exact thing the usual response is addressing? I don’t think Christians have anything to “apologise” for from the genealogy video…so on to the slavery one.

Response

First up, I now realise how off base my response about the Sermon on the Mount and Ephesians (well, that bit was slightly relevant). My excuse is I was going from the video summary, not the video itself, and even then, I only gleaned. I got out of it “slavery”, “eye for an eye” and “unborn children”, not realising 2 of these were describing omissions, content. Whoops! My apologies, I can see how my response seemed like cherry picking, I was responding to slavery and “eye for an eye” as quickly as I could.

My method of response will be simple. I’ll deal with the video in its time context, then deal with it in today’s context, and then I’ll deal with the over-arching topic of morality in the bible, and its applicability to proving/disproving God and God’s morality.

The video deals with these passages: Ex 21:1-6, 20-21, 26-27

Time Context

Ex 21:1-6. I don’t have a problem with any of these, I don’t really see why anyone would. As far as I know, Hebrews were the only one with a year of Jubilee – slaves can go free. Please correct me if I’m wrong on this. The parts regarding wives is solely to do with this, so if you think it unjust, keep that in mind – letting the slave’s wife leave as well is more graceful than anything else at the time.

The term for “Wife” used in this passage isn’t wife in the strict sense we know – we’d probably use something closer to “a woman” now. I’ll presume for this sake that the passage DOES mean wife as we know it, because that’s in the Other Guy’s favour, but keep it in mind

So, the wife leaving with him is graceful, no arguments there. But giving him a wife just to take it away? Well, that seems harsh. My take on it is that, in slavery, the master would only give the slave a ‘wife’ for the sole purpose of bearing sons (and, less so, daughters) – and since the ’slave’ is property (let’s face it, back then, that’s what they were considered), is this really surprising? There was a lot of things unjust about slavery in the day*, this potentially being one of them. You can’t chalk that up to religion though – slavery was rampant almost everywhere. I’ll reiterate here that it was far LESS harsh than slave rights anywhere else. Besides, it doesn’t prohibit the master from sending them both (or all, in the case of a kid) away, if he so desires.

Next, if the slave really can’t bear to leave the wife given to him*, the law gives him an opportunity to come back – albeit, for a price – slave for life, by choice. This is on equal footing with other slave purchases, with the added benefit of it being a choice. A tough choice, but a choice nonetheless. The animation depicted the Awl pretty gruesomely, and that’s something I reject. I’d say it was through the earlobe, like a modern day piercing (with more crude equipment!) – a mark to say you’re a slave for life. Again, equivalent to what was going on at the time – there was always some form of branding for slaves. Seeing a pattern here?

The “daughter” section was conveniently cut off before the part addressing the caring and rights of said daughter. Please, atheist evangelists – if you’re going to quote the bible, don’t cherry pick. We probably know it better than you, and besides, it’s easy to check when chunks are missing*. The bit that was included – how is it any different to an arranged marriage? Remember, polygamy was in and widely practised then. Oh, right, the emotionally loaded animations that muddy the interpretation. Of course.

Now on to verses 20 and 21. In 20, the master being punished if the slave is killed; again, better than anything else at the time. In 21 (master not punished if the slave survives), it even rationalises it there – because it is his property. Property – that’s what slaves were considered at the time. No other culture had any punishments for this at all, yet the Hebrews did.

Finally, if the slave loses an eye or tooth, they are set free. It heartily discourages beating – if you accidentally knock a tooth out (I’m sure a slave’s tooth in 3000BC wasn’t exactly strong), you’ve lost a lot of money. If nothing else, this would limit whipping to the torso area. Better than the surrounding, religion-free regions.

So in summary, most of the rules here are far better than the (lack of?) rules for slaves in other cultures. At this stage, the Jews would be very aware of slavery practices – they’d only just escaped as slaves from Egypt 7 chapters earlier. In any case, if you were going to be a slave, being a slave for the Hebrew was the way to go. It’s temporary, and masters are encouraged to look after you. Find me another culture of the time that’s the same, and I’ll salute you.

Modern interpretation

Today, slavery is almost completely outlawed. Yes, there are areas where slavery is still practised, but I’m not sure that’s relevant to us, because there’s certainly not any that I come in to contact with. Why is slavery gone now? A chief driving force for it was Christian Abolishinists, at least for Europe. I don’t know about other countries. Who knows, were it not for these Christians, we may not even find slavery that abominable – it could still be a fact of life. I said “could be” – it is, of course, unknowable if that is the case or not.

But despite that, what’s the take on those Exodus passages today? The New Testament writings neither condone nor condemn slavery – but rather, put frameworks in place to ensure there’s nothing inhumane going on there. Ephesians 6:5-9. This is not contrary to the Exodus teachings. If indeed that law is still applicable, the teachings in Ephesians only serve to strengthen them, making them by FAR the most humane slavery the world has seen. You do know what era this stuff was being written, right? It was pretty much the height of the Roman empire. Why not have a look at their treatment of slaves? No deity set their rules. Christian-owned slaves (again, the greek is closer to servants) are treated more like household servants; cared for – not threatened. There’s not even any favouritism allowed! Find me a more humane slave system.

In Christianity, any New Testament interpretation generally trumps “Traditional” interpretations of the old testament – sermon on the mount, and Jesus’ dealings with Pharisees are excellent examples of this. The new light cast on the old laws gives them strength that holds up to the world’s even more refined moral views today. When interpreting Old Testament laws, we must read them in light of Jesus, his teachings and his character. To do anything less is simply lacking context, and I’d go as far as saying irresponsible

On Biblical Morality

So often, I see Atheists say “God did/allowed this bad thing in the bible. Therefore, God is bad.” I can’t believe how often this comes up, and it’s just ridiculous – I honestly can’t make any sense of it.

First, let it be known the Bible is being used here – atheists are using the bible as a basis for argument against God. In order to do this, the atheist cannot say “but the bible isn’t true”, or that throws his own argument out the window. He can’t even say “God isn’t real” for this argument, because the bible says He is, and, well, the whole argument is built around the assumption that the bible is true. Saying “no, I’m just these verses as an example, the rest isn’t true” is surely a fallacy. So don’t go all “oh my gosh, he’s placing such faith in the bible, doesn’t he know it’s just a book, not true and not relevant?” because that doesn’t make sense here. The book being true is an axiom of the argument put forth by the atheist.

In the bible, it says who God is. Loving. Powerful. Holy. Those 3 sum is up beautifully. Oh, and the bit about how He’s the creator*.

The difference in being between God and us is so insanely crazy, that it’s unimaginable. Read Job 40 and 41 for some scope on God’s power and knowledge, as described in the bible. Can you even begin to comprehend His ways? And even if you can, and fully, what right do you have to question that anyway? He’s the creator of everything, and the judge over everything! It’s like me writing a program on a computer, and then it saying to me that perhaps I shouldn’t have implemented something the way I did. It’s ridiculous! Humans, and our pride and self-inflated image of ourselves thing we know better for ourselves than God does.

Look, if the bible is used for an argument, all of it must be – Christians get called out on “cherry picking” all the time, well, it’s a 2 way street. In it, God is far far beyond our comprehension. It is not for us to decide what is moral and what isn’t, because it’s not our world – it’s His. What is left for us is seeing HOW something there is moral – a task made a lot easier, since Jesus’ revelations. When read in this light, it’s amazing how often biblical teaching lines up with modern day morals.

Footnotes

1. One wonders how civilisation would have fared without slavery at all. We’ll never know, but it’s possible that it was necessary for the time. I’m not condoning it, just wondering.
2. One also wonders how many of the slaves even liked the wife they were assigned? How many would come back? Remember, the wife/children here is for the benefit of the master, not the slave.
3. The obvious omissions that atheists leave out when they’re arguing these things is … odd. Do you think we won’t notice? Do you want to present a slanted view? Do you care about finding the truth, or are you just being a fundamentalist? This particular one couldn’t have been accidental – the slavery passages were picked out from the chapter, and the rest were summarized. So it had been read numerous times.
4. Ahh, bible creation, another argument. It’s not relevant here – the bible doesn’t mention HOW, just THAT he did. If it makes you feel better, assume that God has a noodly appendage, and created it with that.

Goodbye, old Emails!

October 25th, 2009

So, I just removed all my old Sauce emails, I kept them around for a good 3 months just in case.

Here’s some exerpts from the wonderous occasion!

sauce_remove

On holding to account…

October 24th, 2009

The other day, Paula and I went to the youth bible study, which we’ve been helping to lead over the past couple of weeks. This week, our Pastor was there and the idea of the study was to hold some of the youth leaders to account – we basically went through 1 Tim 3, which defines some attributes that a leader must have, and talked about each point.

Now, it seems that some or more of the potential youth leaders haven’t particularly been living up to these ideals, but what I found most interesting was the Pastor’s struggle with telling the youth leaders that.

You see, he said that 2 verses had come to mind when doing this:

  • 1 Pet 4:17: It is time for judgement to begin in the house of God [...]
  • Matt 7:5: [...] First, take the plank from your own eye [...]

These aren’t particularly surprising – generally they’re at the forefront of most people’s mind when they feel moved to point out errors in people, especially the 2nd one. What was most surprising though was the conviction and emotion which the Pastor displayed when he was telling the kids. It was the most gracious, moving and heartfelt admonition I’ve ever seen, and probably ever will. He was quite distraught at the prospect of being a ‘judge’, because he knew that he wasn’t necessarily better.

It made me think, you know – whenever I’m pointing out sin in others (which isn’t very often, really), why do I it? Is it with pride or humility? Do I think I’m better than them? Do I even have a right at all to admonish anyone at all? When I’m being held to account, do I ever think “You’re no better yourself, you have no right to judge me”?

Rantings of a Microsoft Slave: Part 1 – Initial Reaction

July 30th, 2009

So, I’ve recently moved to a new job – a job where I’m now to be working in Microsoft products, seemingly only. I’m not kidding – from a complete OSS job in PHP, linux (RHEL and Ubuntu), MySQL using Eclipse, Joomla, vTiger and so on, to a complete .NET/Microsoft centric place: Vista, Outlook, OneNote, VS2008, C#.NET, MSSQL, TFS, IE8 – you name it, Microsoft is the answer

A few people have said they’d be interested in hearing about the transition from OSS to .NET, and how it stacks up, so I’m starting a web series which I’ll update whenever I feel like it. The series may only be 1 long, who knows? I am struggling to do my best to leave my prejudice at the door but…well, it’s not easy :P

My initial reactions are almost entirely negative. The first “what the?” that jumped out at me was the compilation and deployment process. I dealt wtih PHP, a scripting language. Upload it, and it’s there. A web app that required compilation and deployment was relatively new to me, but as I’d dealt in C++ and even C# in desktop apps before, it wasn’t a big deal. What WAS a big deal was the speed of the first page load – Easily 5x as long as the compilation process

Y’see, for some unsightly reason, on the first page load it has to go through and recompile it. The WHOLE application – I think it’s JIT compiling it this time around, to change it from the CLR to native code, for speed. It may be that the compilation process in VS just copies the script files, and the asp.net handler needs to compile it. I’m not totally sure, I just know it’s a pain in the butt to have to wait 5 mins between compile and test, especially when dealing with simple web services. Why can’t they give us an option for an interpretted mode, which just scripts it. Would certainly make my recompiles easier

I really, really miss the terminal. Whether it’s to grep inside files, check the processes running, hack up a quick test script or simply just navigate the file system, the linux terminal, with those excellent tools brought to us by GNU, is much MUCH nicer than anything windows has thrown at me. Or, heck, piping to the “less” command. I know, I know, I could use cygwin or gnuwin32, but for anyone who’s been even exposed for a brief amount of time to the windows command line (what? I can’t change the width?) knows it’s not a valid comparison.

So a general feel is that everything is somewhat clunkier. MSDN documentation is stupid to navigate around (doxygen output is quite clean), and usually lacking vital information (custom attributes that you won’t expose the keys for? Why?). SVN vs TFS (I really like the TFS job list support/integration, but damn it’s slow, and why doesn’t double click open up my merge editor? And don’t get me started on the in built editor…). Getting the latest .csproj file (if someone has added a file, for example) means I need to re-import the project. Fair enough. Why does that take forever? It’s really not that big.

Finally, the fact that it’s closed source. I has some problems with Joomla sessions and SSO previously. I was able to trace through the code to fully understand what it was doing and get it solved. I am currently having some trouble with a .NET library feature that’s not exposing internal calculations I need for the UI. Oh well, nothing I can do about it. Unless it reflects…

It’s just a lot of little things that makes me feel that the solutions offered are about 90% done. Ideas that work well, that just aren’t executed. What confuses me is how MS developers are ok with the sub-par developer support – don’t they use this stuff daily?

Oh, linux, how I miss thee. And you, LGPL, with your open code and navigatable (if sometimes lacking) documentation. And you, eclipse, with your perspectives and myriad of plugins

Almost ready to maze

April 22nd, 2009

So I’ve updated yet another uhh…update. This time around I’ve neatened things up, fixed some bugs, and added some polish. Here’s what’s changed:

  • Objects now snap-to-grid
  • Weapons, walls, zombies and player all properly collide / slide (sliding is a little jumpy atm, but not too bad)
  • Fixed some crashing that was happening due to physics objects not being properly removed
  • Tried it out on linux – I get segfaults at random, and I have no idea how to debug properly on linux *sigh*

So the reason I’ve done the snap-to-grid feature is so I can work on mazing. Try it out now – You can build mazes with magnets or turrets, and you can walk through it. However, that is kind of useless without some shortest path algorithm.

The best algorithm for this application will be A* – it can find the shortest path to a destination node (the fridge) from every other node. I only need to run it once for every blocking object that gets added, so performance is good, and with proper heuristics, no problemo!

I was pondering the idea of using fluid dynamics for the pathfinding. See, the pressure stabalisation step of fluid dynamics essentialls “smooths” things out, and makes the fluid run along boundaries. All I’d have to do is initialise every grid position with a vector pointing to the destination node, and run a few jacobian iterations over the domain, and voila! Done! I want to try it out and see how it goes, seems like a novel approach that could work. The main problems I see are with very complex mazes (fluid would virtually stand still due to compression/numerical accuracy), very thin mazes (if walls are on either side of a single cell, it’s hard to solve), and U shaped areas (the fluid may end up just going in circles once inside which would be funny, but not good for gameplay). I’ll let you know how it goes :)

The only other thing I’ve done is update the ZAMF page to have the link to the latest at the top, beneath the picture, rather than the bottom. Woohoo!! As always, click the link on the right to check it out

Largest Update Yet!

April 8th, 2009

Whew, I’ve just finished my biggest update yet, feature wise. I was surprised at how fast this one came out, but I’m quite pleased with the state of this product – it seems to be rock solid, fast, accurate and *gasp* even a little bit fun!

So, since this seems almost like a milestone release, I think I’ll write a bit about what’s been done. Most of the content of this post will be over on the project’s page, too, which will be updated as I go on.

As you know, I had this project done a fair bit using my own custom rolled engine, but maintenance became just a tad extreme, and I figured that other people have already done stuff, so why should I have to reinvent the wheel? Some research found me Ogre

The hardest thing about changing to Ogre was the way the main loop is done. In my own system, every scene node had an overrideable “Update” function, where I implemented my AI and everything. Basically, I extended scene nodes for every type of actor there was. In Ogre, you can’t really extend the scene node class, without overriding the scene manager as well (which I didn’t want to do) – instead, “frame listeners” are used – a function is called every tick on a frame listener, and they have to update the scene node. So I wrote a wrapper around all this so I can simply register my own AI classes, and this handled all the keyboard and mouse events

While I was at it, I put in a game state manager and level loader – this time actually thinking about the transitions between levels. There’s functionality in place now to put loading screens in (but not actually used), and properly clear any cache or anything that I have lying around. Woohoo!

The next big task was deciding on a physics engine. My first instincts told me to go for PhysX (aka Nx) – there were binding classes around to do some of the integration work for me, and it wasn’t long before I had a dummy app in Ogre that I could throw boxes around and watch them smash each other up.

However, after trying to get it into my engine, it became apparent that the binding classes included were too restrictive – it tried to wrap every single function up, and so I was left with a half of a physics engine that I could actually use, with the overhead of the whole library, and it lacked very VERY important features – such as a simulation tick callback, or listeners.

I decided to scrap Nx and go for bullet. The first set of bindings I used was similar to the nx bindings – tried to wrap every function – so I had issues with that straight away. Then I found a second set, far more slim – more of a converter than integration. It allowed me to throw entities at it, and get back bullet representations of those – cylinders, boxes, spheres, convex hulls, trimeshes, you name it. Brilliant! I now have a physics engine.

Ahh, physics is difficult. I’ll give a brief rundown on how things work here, but it’s a very complicated topic. It took me several forum posts, hours of reading, and hours of “DARGH WHY ISN’T THIS WORKING” until I got it down. So here goes.

The bullet physics engine is governed by 4 parts – the world, dispatcher, solver and broadphase. The idea is we create a world (which holds physics objects) and attach a dispatcher to it (which stores and moves collision information around). We also need to set up the broadphase – a topic in and of itself, but this handles the broadphase part of the collisions (checks bounding boxes, or whatever – cull lots of objects quickly). The solver is responsible for resolving collisions – if a truck hits a tennis ball, what is the result?

So, how does one set up bullet physics? Simply:

  • Set up the world, dispatcher, solver and broadphase
  • Attach some form of internal callback function, to handle the results of the collision
  • As the game is going, add collision objects/rigid bodies to the world. Each object should have a motionstate attached to it – which synchronises the scene node position/orientation with the physics object
  • At each timestep, tell bullet to step the simulation

This will get everything set up, and even make things bounce of each other properly. However, that last bullet point is a doozy. I’ll put what I think happens inside that step to clarify:

  • Simulation step is started
  • The broadphase goes through and finds all possible collisions, creating a contact manifold for each and throwing it at the dispatcher
  • The dispatcher looks at each manifold, and performs a low-level collision detection on each primitive (ie. box, sphere), storing the information of any contact points in the contact manifold
  • If dynamics is enabled, solves any collision responses, making each object interact
  • Calls the internal tick function specified by the user, with the collision world as a parameter
  • Here, the user must loop through the manifolds, find all the contact objects and points, and perform any custom collision responses (playing sounds, losing health, whatever). To make this step more possible, one can set up a user pointer (void*!!!), which can hold anything. I chose to make it hold a physics response interface which I can subclass, it works really well. I just need to cast it to this IPhysicsResponse, and call my Collide function. Yay!

And that’s that! Physics was definitely the hardest thing to set up – harder than the graphics engine, I would say. The main reason it’s so hard is because documentation is really, really bad. It’s written by a bunch of academics, and it’s more fun to make the physics engine than it is to document it. Oh well. The forums are absolutely awesome though, hurrah!

Once I got the physics sorted out, I could move on to implenting decent gameplay. Here’s where things sped up somewhat. I was able to perfect the collisions between bullets and zombies, and stop the zombies running through each other, and add a magnetised weapon, and stuff. I tried to add a kinematic player controller (basically, the user is governed by physics rather than by moving it), but it seems I should wait until the next Bullet release for that.

My most recent additions to the engine include a config file, so I can much more easily tweak things like zombie health, cooldown rates and starting money, and sound. That’s right, the sound that added so much to the previous version is now in this one! And improved – I now have a dying sound, 2 sets of music and a zombie hitting sound.

All in all, I’m quite pleased with my progress. Check it out here, and let me know any suggestions/ideas/critcism/anything! Feedback is most welcome!

Getting there…

April 3rd, 2009

Whew, so I’m 90% done moving to Ogre.

Check it out here. Ignore what that page says, I haven’t updated it yet.

Time for sleep. I shall edit this post later.

Status Update and New Page

March 4th, 2009

So I’ve been working on moving engines – bigger job than I thought. I’ve put a state manager in, so I can easily allow the game to be paused, have a menu etc. – it adds quite a bit of polish, really. I’ve also put in a message dispatcher, so there’s no one central hub for all messages, and components can register themselves there in order to receive messages – it makes message handling much easier, and allows me to customise input quite easily.

But as for the game itself, well I have a zombie running around in circles, and the ability to create turrets which destroys the zombie that runs around. It shouldn’t be long before I have a replica of the old stuff – I only have to add zombie behaviour and scoring, really, and it’s done! (ish).

In other news, I’ve updated the ZAMF page – it now includes a downloadable version. I figured there’s no harm in sharing it with the world! :-)

Be sure to give me feedback by commenting here! Tell me what you’d like to see, what you’d like to not see, things to add/remove and all that, I’ll do what I can :-)