{"name":"setShotParents","operator":null,"title":"setShotParents","type":"command","url":"https://community.bistudio.com/wiki/setShotParents","revid":349182,"updated":"2023-11-08T14:50:39Z","groups":["Weapons"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.66"}],"since":{"game":"arma3","name":"Arma 3","version":"1.66"},"arma3_since":"1.66","branch":null,"locality":{"argument":"global","effect":"global","server_exec":true},"exec":null,"description":"Sets vehicle and instigator pair for the given projectile.","syntaxes":[{"syntax":"projectile setShotParents [vehicle, instigator]","since":null,"effect":null,"exec":null,"params":[{"name":"projectile","type":"Object","optional":false,"default":null,"description":"the actual projectile shot","types":["Object"],"since":null,"text":"projectile: Object - the actual projectile shot"},{"name":"vehicle","type":"Object","optional":false,"default":null,"description":"vehicle shooting projectile (appears as the 'killer' in \"Killed\" EH)","types":["Object"],"since":null,"text":"vehicle: Object - vehicle shooting projectile (appears as the 'killer' in \"Killed\" EH)"},{"name":"instigator","type":"Object","optional":false,"default":null,"description":"person pulling the trigger (appears as the 'instigator' in \"Killed\" EH)","types":["Object"],"since":null,"text":"instigator: Object - person pulling the trigger (appears as the 'instigator' in \"Killed\" EH)"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"projectile","types":["Object"]},"right":{"text":"[vehicle, instigator]","types":["Array"]}}],"examples":[{"text":"```sqf\nmyProjectile setShotParents [vehicle bob, bob];\n```","code":["myProjectile setShotParents [vehicle bob, bob];"]},{"text":"```sqf\ntank addEventHandler [\"Fired\", {_this select 6 setShotParents [tank, commander tank]}];\n```","code":["tank addEventHandler [\"Fired\", {_this select 6 setShotParents [tank, commander tank]}];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["getShotParents"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: Weapons","Introduced with Arma 3 version 1.66","Scripting Commands","Scripting Commands: Global Effect","Scripting Commands: Server Execution"]}