Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package BdayPartyDeath
- {
- function projectileData::onCollision(%this,%obj,%col,%fade,%pos,%normal)
- {
- %result = parent::onCollision(%this,%obj,%col,%fade,%pos,%normal);
- if(matchBodyArea(getHitbox( %obj, %col, %pos ), $headTest ))
- {
- if(%col.getType() & $TypeMasks::PlayerObjectType)
- {
- if(%col.getState() $= "Dead")
- {
- %proj = new Projectile()
- {
- scale = %obj.getScale();
- dataBlock = bdayDeathProjectile;
- initialPosition = %obj.getPosition();
- sourceObject = %obj;
- sourceSlot = 0;
- client = %obj.client;
- };
- MissionCleanup.add(%proj);
- serverPlay3D(BdayDeathSound,%obj.getTransform());
- }
- }
- }
- return %result;
- }
- };
- activatePackage(BdayPartyDeath);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement