{"name":"ppEffectCreate","title":"ppEffectCreate","type":"command","url":"https://community.bistudio.com/wiki/ppEffectCreate","revid":376949,"updated":"2025-12-31T23:30:11Z","groups":["Camera Control"],"status":"ok","games":{"arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"arma2 1.00","arma3_since":"0.50","description":"Creates Post Process Effects specified by effect name and priority.\nSupported effects:\n\n- \"RadialBlur\"\n- \"ChromAberration\"\n- \"WetDistortion\"\n- \"ColorCorrections\"\n- \"DynamicBlur\"\n- \"FilmGrain\"\n- \"ColorInversion\"\n- \"SSAO\"\n- \"Resolution\"","syntaxes":[{"syntax":"ppEffectCreate [name, priority]","params":[{"name":"name","type":"String","description":"name of effect type","type_expr":"String"},{"name":"priority","type":"Number","description":"unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail","type_expr":"Number"}],"returns":{"type":"Number","type_expr":"Number","description":"handle or -1 if failed"},"form":"unary","right":{"text":"[name, priority]"}},{"syntax":"ppEffectCreate [[name1, priority1], ...]","params":[{"name":"nameN","type":"String","description":"name of effect type","type_expr":"String"},{"name":"priorityN","type":"Number","description":"unique priority, defines order of applying effect to the scene. If there is another effect using the same priority, creation will fail","type_expr":"Number"}],"returns":{"type":"Array of Numbers or Nothing","type_expr":"Array<Number> | Nothing","description":"if failed","text":"Array of Numbers or Nothing if failed"},"form":"unary","right":{"text":"[[name1, priority1], ...]"}}],"examples":[{"code":["_ppGrain = ppEffectCreate [\"filmGrain\", 2005];"]},{"text":"If an effect ID is already used, the effect is not created. Use the following:\n\n```sqf\nprivate _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwhile\n{\n    _handle = ppEffectCreate [_name, _priority];\n    _handle < 0;\n} do {\n    _priority = _priority + 1;\n};\n\n// _handle can be used here as usual\n```\n\nor\n\n```sqf\nprivate _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwaitUntil { _handle = ppEffectCreate [_name, _priority]; _priority = _priority + 1; _handle > 0; };\n\n// _handle can be used here as usual\n```","code":["private _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwhile\n{\n\t_handle = ppEffectCreate [_name, _priority];\n\t_handle < 0;\n} do {\n\t_priority = _priority + 1;\n};\n\n// _handle can be used here as usual","private _name = \"ChromAberration\";\nprivate _priority = 200;\nprivate _handle = -1;\nwaitUntil { _handle = ppEffectCreate [_name, _priority]; _priority = _priority + 1; _handle > 0; };\n\n// _handle can be used here as usual"]}],"see_also":["Post Process Effects","ppEffectForceInNVG","ppEffectEnable","ppEffectEnabled","ppEffectDestroy","ppEffectCommit","ppEffectCommitted","ppEffectAdjust"],"notes":[{"user":"Lou Montana","date":"2009-06-29T22:33:00Z","text":"For some examples, check [this forums' topic](http://forums.bistudio.com/showthread.php?t=75528)."},{"user":"Raymix (DayZ)","date":"2015-06-24T04:08:00Z","text":"\"wetDistortion\" only works if handle is used."}]}