Blockland Forums > Suggestions & Requests
randomized pain sounds
<< < (3/3)
Danny Boy:

--- Quote from: Port on July 03, 2013, 08:28:11 AM ---
--- Code: --- function Armor::Damage(%this,%obj,%sourceObject,%position,%damage,%damageType)
{
if(%obj.client.getClassName() $= "GameConnection")
{
if(!%client.justdied)
{
if(%damage > 0)
%obj.client.player.PlayRandomPain();
}
}
return Parent::Damage(%this,%obj,%sourceObject,%position,%damage,%damageType);
}

function GameConnection::onDeath(%client)
{
%client.justdied = 1;
%client.player.PlayRandomDeath();
return Parent::onDeath(%client);
}

function GameConnection::spawnPlayer(%client)
{
%client.justdied = 0;
return Parent::spawnPlayer(%client);
}

--- End code ---

What's this? You don't define Player::playRandomPain anywhere, and you've already modified Player::playPain to play random pain sounds anyway.

--- End quote ---
Oh stuff, I forgot about that, I had it set as PlayRandomPain before I realised I could just overwrite the default function, I'll fix it now.

Edit: That's everything fixed now. Sorry about the silly mistake.
MunkeyCheez:
thank you very much :)

release to rtb?
Danny Boy:

--- Quote from: MunkeyCheez on July 03, 2013, 07:20:45 PM ---thank you very much :)

release to rtb?

--- End quote ---
I might later I guess, I'll probably add an RTB pref for enabling/disabling and maybe even one so you can select one of the other voices you gave me.
MunkeyCheez:

--- Quote from: Danny Boy on July 04, 2013, 08:52:24 AM ---I might later I guess, I'll probably add an RTB pref for enabling/disabling and maybe even one so you can select one of the other voices you gave me.

--- End quote ---
excellent!
Navigation
Message Index
Previous page

Go to full version