Author Topic: Event Input Parameters  (Read 2884 times)

For registering the events -
A simpler method might be this:
Code: [Select]
registerInputEvent("fxDTSBrick", "onProjectileHit",
                                     "Self fxDTSBrick" TAB
                                     "Player Player" TAB
                                     "Projectile Projectile" TAB
                                     "Client GameConnection" TAB
                                     "MiniGame MiniGame",
                                 "datablock ProjectileData");
Code: [Select]
function fxDTSBrick::onProjectileHit(%obj,%projectile,%client)
{
   ...
   %obj.processInputEvent("onProjectileHit", %projectile.dataBlock, %client);
}
When you register it, you specify a type it should be, then when it's triggered you put in the value it should check that against. In this case it checks a projectiledata against the one that hits its' datablock.

Not many types of fields would fit in that space, the most you could do is two boolean or integer fields - the rest would end up being too long.
Maybe check if function fxDTSBrick::onProjectileHit_Check exists and call it like yours in that case for more advanced checks than [datablock == selected value]. For datablock checks, "NONE" should be changed to "ANY" or "ALL" or something so it's clearer.

Apart from that, it looks very nice.
« Last Edit: December 31, 2009, 12:45:24 PM by Space Guy »

For registering the events - Maybe check if function fxDTSBrick::onProjectileHit_Check exists and call it like yours in that case for more advanced checks than [datablock == selected value]. For datablock checks, "NONE" should be changed to "ANY" or "ALL" or something so it's clearer.

Apart from that, it looks very nice.

I might delay the release so that I can add these in, as well as some other stuff I've thought of. I've been putting it off, because it involves me pretty much rewriting the whole thing. I doubt I can get that done + test it in a reasonable amount of time (family holding new years party, being nagged to help set up), so everyone will just have to be patient.

Well, it's been over a month since New Years - what happened to this? I think it'll be really helpful once done.

Oh, so these will [Eventually] be released?

I wanted to bump this due to the amazing nature of the mod.