# Bart.Jan

Member

739

1. ## Macros in functions

Thanks for the tip, but there is nothing about macros. I found nothing about macros in tutorials and in any function there.
2. ## Set view distance?

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> setviewdistance 500 <span id='postcolor'> Put it to init line of any unit on the map.
3. ## Propaganda doesn`t change at all

United States of America : The World's Foremost Nation of War Just interesting reading. Is it something that some nation can be proud of or is it anti-US propaganda ?

Create a seagul : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _sg = "seagull" camCreate [x,y,z] <span id='postcolor'> Make a seagul to move : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _sg camSetPos [x,y,z] <span id='postcolor'> Make a seagul to land : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _sg camCommand "landed" <span id='postcolor'>
5. ## How do you make a unit immortal?

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (starstreams @ Mar. 15 2003,16:54)</td></tr><tr><td id="QUOTE">Wow it looks pretty deep man. Iâ€™m not even sure what an addEventHandler is? Iâ€™m guessing itâ€™s some kind of built in component that requires an Acton or parameters. Either way where did start learning this? I mean is there some kind of tutorial that walks you though all the different Parameters?<span id='postcolor'> I'm sure there are good english scripting tutorials somewhere but I prefer czech tutorials. But generally very useful are : - official comref -Unofficial Operation Flashpoint Command Reference Manual (slightly out of date but still useful)
6. ## How do you make a unit immortal?

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (starstreams @ Mar. 14 2003,03:15)</td></tr><tr><td id="QUOTE">I donâ€™t know how you figured that out but I wish I understood the science of scripting. Iâ€™m just glad it worked! <span id='postcolor'> It's not so difficult as it looks. It's about knowledge of OFP scripting commands. </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> this addEventHandler ["hit",{{_x setDamage 0} forEach [_this select 0]+crew (_this select 0)}]<span id='postcolor'> Immortal unit -> unit take no damage -> but unit always take damage after hit so unit (tank and its crew) must be healed after hit. after hit -> event handler "hit" -> addEventHandler healed -> setDamage 0 helaing for tank and its crew -> forEach command unit (tank) -> first parameter of event "hit" : _this select 0 crew of tank -> crew command -> crew of tank : crew (_this select 0)
7. ## Help

Or create ending trigger with 0,0 axis activated by nobody and change condition to : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> !alive soldierName <span id='postcolor'>
8. ## How do you make a unit immortal?

You can use event handler. Just make sure tanks are in "combat" behaviour. Put in init field of each tank : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">this addEventHandler ["hit",{{_x setDamage 0} forEach [_this select 0]+crew (_this select 0)}]<span id='postcolor'>
9. ## Hmmmm help

It looks like problem with script calling. It shoud be something like : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> [player,triggerName] exec "scriptName.sqs" <span id='postcolor'> and I think you doesn't understand format yet. Even your example works. It shoud be : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> titleText[FORMAT["%1: wins THA RACE", name _player], "PLAIN"]<span id='postcolor'> In commas " Â " is text that will be dislpayed. %1, %2 ... are substitutes that will be replaced by code after "" %1 takes first thing after "" - that is name _player in your example. And semi-colon ; is not needed at the end of each script line. Maybe it can be the problem.
10. ## Respawning vehicles

Oops. I should read whole thread more thoroughly. Sorry. It was just little late night scripting inspiration.

I do not need travel a lot to tour Davle with its bridge. Another pictures of czech Davle : www.davle.cz Another picture of Davle's bridge : http://www.davle.cz/foto/most_n/004.jpg
12. ## Is there a list of actions around?

Open stringtable.csv file from OperationFlashpoint\Res\Bin folder. Find string STR_NO_ACTION. From that point there are list of possible actions. Mostly action name is string without first STR_ACTION_ . But there is no list with parameters I know about. Â These strings are also listed in Unofficial Operation Flashpoint Command Reference Manual but without parameters.
13. ## Forum word-censoring

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (Grendelman @ Mar. 05 2003,18:41)</td></tr><tr><td id="QUOTE">Dikke kankerzooi man, dit is godverdomme toch niet normaal meer. Dat een kutforum als deze hoerezooi dit gewoon toelaat?<span id='postcolor'> Board rules : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">3.Rules of Format Â§7)Write in English In the English part of the board write in English and in the Czech write in Czech. Try avoiding writing in any other language since the majority of the members most likely won't understand it.<span id='postcolor'> Give me a translation !
14. ## Some questions regarding

Put whole script code into text file. Name that file "way.sqs" and put it into your mission folder OperationFlashpoint\Users\yourUserName\missionName\ Then, in mission editor, put : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> [] exec "way.sqs" <span id='postcolor'> into init line of any unit.
15. ## 2 questions

If you want to remove action from unit after first use you can use : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> (_this select 0) removeAction (_this select 2) <span id='postcolor'> in that action script.

17. ## Some questions regarding

No, but you can use : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> ?(_this select 0) != (_this select 1):exit <span id='postcolor'> as first line of action script. Script ends when action is not used by its owner.
19. ## Create a civilian using a script

Change creating line in script to : </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> "civilian6" createunit [getpos _pos,_grp,"this addMagazine ""cz75mag"";this addWeapon ""cz75""",1,"PRIVATE"] <span id='postcolor'> Civilian is created with loaded CZ75.
20. ## Delete people

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">{deleteVehicle _x} foreach thislist<span id='postcolor'>
21. ## Overview pic problems

Allowed sizes of picture are : 2, 4, 8, 16, 32, 64, 128, 256 ... (2^n) 170x64 - change dimension of your picture.
22. ## Fun missions

</span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (iNeo @ Feb. 26 2003,02:11)</td></tr><tr><td id="QUOTE">Armagedon was cool too, but what did the mission maker actually use for meteors? <span id='postcolor'> Armagedon is from section FUN.