Page MenuHomeFeedback Tracker

createShot, a dedicated command to create shots
New, NormalPublic

Description

I'd like to request porting of VBS's createShot command: http://web.archive.org/web/20110801065020/http://resources.bisimulations.com/wiki/createShot

Reason for dedicated command is to broadcast shot transformation data (orientation, velocity) right in the create message without having to wait for the engine to update it over network, which is often never happens as shots hit something very quickly.

If possible I'd also like to add additional parameters into the command: Source, Instigator, Orientation, Real or not, Tracer.

ENTITY = createShot [CLASS, POSITION, VELOCITY, VECTORDIR, VEHICLE, INSTIGATOR, REAL, TRACER]

CLASS - String classname from CfgAmmo
POSITION - PositionASL of the shot
VELOCITY - Initial shot velocity
VECTORDIR - (Optional) orientation of the shot. Could be nil so its calculated from velocity. Maybe can be 2 arrays for vector dir and up?
VEHICLE - (Optional) getShotParents source vehicle
INSTIGATOR - (Optional) getShotParents instigator
REAL - (Optional) fake shot for visual effect, maybe only for shotBullet? Alt name: LOCAL
TRACER - (Optional) force tracer on/off for shotBullet?

Details

Severity
Feature
Resolution
Open
Reproducibility
N/A
Operating System
Windows 10 x64
Category
Scripting

Event Timeline

SaMatra created this task.Apr 27 2024, 7:40 AM
dedmen added a subscriber: dedmen.Apr 30 2024, 9:10 AM

This seems it would just make it easier for cheaters to post bullets impersonating other players.

Sure, but they already do that with proper cheats bypassing SQF and creating own shot messages. Is it really *that* much worse than creating shots with createVehicle and createVehicleLocal? You can already do a lot of mess with {createVehicleLocal ["HelicopterExploBig", getPos player, [], 0, ""]} forEach allPlayers and its not even logged in createvehicle.log. (Censor this if needed)

Amount of modding benefits greatly overweight small amount of potential harm (which I'd argue is none as cheaters can already do all that)

Reposting from discord:

I think the main use for this command will be clientside for scripted weapons and the like, forcing it to only be run on the server would add lag to the mix and be bad for general 'feel' and hit registration locally.

If security is a concern the command could have two different behaviours when running on the server or a non-server client in MP.
For the server the command is unlimited, any unit can be assigned as INSTIGATOR/VEHICLE
For non-server clients only units local to their machine can be assigned, so their player unit, AI local to their machine etc. Or objNull ofcourse