onBotHeadShot event

Poll

Should this be a thing?

Yes
1 (25%)
No
0 (0%)
Maybe
0 (0%)
Only if whoever creates it releases it to e public
3 (75%)

Total Members Voted: 4

Author Topic: onBotHeadShot event  (Read 1186 times)

I was wondering if someone could make an event involving head shots on bots? If it is possible, at least. I'm making an RPG in Blockland and wanted an enemy that functions like the Goliath from Borderlands. If you're willing to do it, thank you!

It has been proven to be possible by Darksaber and Crystalwarrior, thank you both for that!
Actually, you can detect hitboxes by using the paintcan particles. There was a script for it... let me find it...

EDIT:
Yes, here's the code for checking for a hitbox with hitboxes.cs (assuming this is in a ProjectileData::damage(%this, %obj, %col, %pos, %etc..,) function)
Code: [Select]
%hitbox = getHitbox(%obj, %col, %pos);

if(strPos(%hitbox, "headskin") > -1)
{
//do stuff for headshot
}
What, this is completely possible.
You could detect in the general projectile/raycast code when it hits the bot. If it does hit the bot, call a specially created function on it and send positional arguments.
In that function you'd check if it's an actual headshot and then call the event on spawner brick.
It's really not that difficult.
« Last Edit: June 09, 2015, 07:05:51 AM by Space1255 »

i dont think torque makes individual hitboxes, i think its just one hitbox so it wont be possible to detect headshots i bet

i dont think torque makes individual hitboxes, i think its just one hitbox so it wont be possible to detect headshots i bet
But the Tier Tactical Sniper and Magnum use headshots, tested it against the bots and just as effective against a bot.

i dont think torque makes individual hitboxes, i think its just one hitbox so it wont be possible to detect headshots i bet
a certain sniper rifle does a 1-hitkill for headshots and even has a bloody head effect

i dont think torque makes individual hitboxes, i think its just one hitbox so it wont be possible to detect headshots i bet
the head shots work by crunching some numbers to see if a shot landed in the player's general head area. there are no hit boxes needed for this.

the head shots work by crunching some numbers to see if a shot landed in the player's general head area. there are no hit boxes needed for this.

Ah, that's why head shots on custom model bots are a real bitch to pull off. There should be precautions to prevent that.

Also, don't most/all/(the ones that exist)headshot scripts rely on weapon sided code to work?

If that's the case, then this might be impossible (cri). If it's impossible I'll lock the thread.

What, this is completely possible.
You could detect in the general projectile/raycast code when it hits the bot. If it does hit the bot, call a specially created function on it and send positional arguments.
In that function you'd check if it's an actual headshot and then call the event on spawner brick.
It's really not that difficult.

Actually, you can detect hitboxes by using the paintcan particles. There was a script for it... let me find it...

EDIT:
Yes, here's the code for checking for a hitbox with hitboxes.cs (assuming this is in a ProjectileData::damage(%this, %obj, %col, %pos, %etc..,) function)
Code: [Select]
%hitbox = getHitbox(%obj, %col, %pos);

if(strPos(%hitbox, "headskin") > -1)
{
//do stuff for headshot
}
« Last Edit: June 09, 2015, 06:50:29 AM by Darksaber2213 »

[shedding tears of joy knowing that this is possible] Thank you all for confirming this for me.