OCD2 Posted February 17, 2021 Share Posted February 17, 2021 Hello, Was wondering if you can can you script an NPC to target and attack funcbreakables when the NPC comes in proximity to the funcbreakable in a map? Or would that be a coding mod? Droidy365 likes this Link to comment
Droidy365 Posted February 18, 2021 Share Posted February 18, 2021 It might be possible to have an invisible and invincible NPC that your NPC wants to attack, with the func_breakable being "collateral damage." Other than that, I think it might be possible with scripting? I'm not all that experienced with that sort of thing, so I don't know for sure. Link to comment
OCD2 Posted February 18, 2021 Author Share Posted February 18, 2021 1 hour ago, Droidy365 said: It might be possible to have an invisible and invincible NPC that your NPC wants to attack, with the func_breakable being "collateral damage." Other than that, I think it might be possible with scripting? I'm not all that experienced with that sort of thing, so I don't know for sure. Ah, I see your line of thinking. That seems like it could produce the effect im trying to achieve. Could the invisible invincible NPC then be connected to the funcbreakable somehow, so that when the funcbreakable is destroyed, the invisible invincible NPC "disappears"/dies? Droidy365 likes this Link to comment
Ramikad Posted February 18, 2021 Share Posted February 18, 2021 I think (but I'm not 100% sure) that you can set a deathscript to the func_breakable to remove (through script) the NPC: //(BHVD) remove ( "NPC targetname" ); OCD2 and Droidy365 like this Link to comment
OCD2 Posted February 18, 2021 Author Share Posted February 18, 2021 9 hours ago, Ramikad said: I think (but I'm not 100% sure) that you can set a deathscript to the func_breakable to remove (through script) the NPC: //(BHVD) remove ( "NPC targetname" ); I'll have to give that a try, thank you. Droidy365 likes this Link to comment
AshuraDX Posted February 19, 2021 Share Posted February 19, 2021 If the deathscript doesn't work you can target a scriptrunner from the func_breakable and use that to run the script when it is broken. OCD2 likes this Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now