Unnamed_
Member-
Content Count
144 -
Joined
-
Last visited
-
Medals
Community Reputation
0 NeutralAbout Unnamed_
-
Rank
Sergeant
-
Thats just setpos positioning the objects relative to the current height of the rising and falling tide. Vektorbosons height above sea level function will return the height of the tide, just subtract (well add...as the function returns a negative number) that value from the Z value of your SetPos command. You just have to call Vektorbosons function and your SetPos command as a single function, so you get the correct tide, the moment you setpos. Oh and just in case. GetPos returns a Z value relative to any roadway LOD you happen to be above. Setpos is relative to the terrain your above, and will ignore the height of the roadway LOD if you try and position something directly on top of the roadway itself. So unless your aircraft stays at a fixed altitude, you will have to call extra functions to get it's absolute height for the guys walking around inside.
-
No it does not work, and I did test it. At least on Res V1.91 using Empty\Objects\Fire in the editor. I cant say I've tested every possible connotation, but I did try and test it from within a config to. But I assumed it was common knowledge that you cant use RemoveAction for every action in OFP? For anyone who is interested there are two kinds of actions: Those you add using AddAction in a script or mission, they can be removed with RemoveAction, have a default activation radius of about 50 meters, and are available to everyone within that radius. The others are User Actions, those you add via a config, they have a user defined radius that goes up to the maximum view distance you set in OFP's config. Have a condition field to decide who gets to display the action and a statement field to say what’s to be done when selected: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class FOStartStandScan {      displayName=$STR_DN_FOStartStand;     position="zbran";     radius=0.5;     condition="(([This] Call FO_ObserverReady) and (CanStand This) and (Alive This))";     statement="[This,True,FO_STAND] Call FO_SetActiveStatus";    }; @Sanctuary Just out of curiosity what did you intend to use the InFlame command for, Mission editors or internally in your scripts?
-
You can only use RemoveAction, with the Action ID's returned by the script command, AddAction. If your only using the fire class for the InFlame command. Why not just move the object out of the way, once the fire script has been started?
-
Yes you can, but nobody has made the required library of sound files or written the proper scripts for MP. But I do have an example that uses some of the default voice samples of OFP, to play simulated custom radio messages. If your interested?
-
If you just want to get it into the game, I have a basic example: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class CfgPatches { class FOU_DataV10 { units[] = {}; weapons[] = {}; requiredAddons[] = {BIS_Resistance}; requiredVersion = 1.91; }; }; class CfgMovesMC { class Default {}; class CombatBase: Default {}; class StandBase: Default {}; class States { Â Â Â class FOBinoc: CombatBase { actions = BinocActions; file=sdalekstat.rtm; // TODO: ai variants speed=-2; looped=true; disableWeapons=false; showItemInHand = true; soundEnabled=false; enableBinocular = true; head=headNo; connectFrom[] = {CombatToBinoc,1}; interpolateTo[]={CombatDying,0.1,CombatDyingVer2,0.1,CombatDyingVer3,0.1}; }; class FOBinocLying: CombatBase { actions = BinocLyingActions; file=plazenidalekstat.rtm; // TODO: ai variants speed=-2; looped=true; disableWeapons=false; showItemInHand = true; soundEnabled=false; enableBinocular = true; onLandBeg=true; onLandEnd=true; //duty = RestDuty; connectFrom[] = {LyingToBinocLying,1}; interpolateTo[]={LyingDying,0.1}; }; class FOBinocStand: CombatBase { actions = BinocStandActions; file=bezdalekstat.rtm; // TODO: ai variants speed=1; looped=true; disableWeapons=false; showItemInHand = true; soundEnabled=false; enableBinocular = true; connectFrom[]={StandToBinocStand,0.1}; interpolateTo[]={StandDying,0.1,StandDyingVer2,0.1}; }; class FOBinocCrouch: CombatBase { actions = BinocCrouchActions; file=klekdalekstat.rtm; // TODO: ai variants speed=2; looped=true; disableWeapons=false; showItemInHand = true; soundEnabled=false; enableBinocular = true; connectFrom[]={CrouchToBinocCrouch,1}; interpolateTo[]={CrouchDying,0.1}; }; class FOCrouch: CombatBase { preload = true; actions=CrouchActions; file=klek.rtm; speed=2; variantsPlayer[]={}; variantsAI[]={}; visibleSize = 0.6; aimPrecision = 0.5; soundEnabled=false; recoilSuffix = "halffixed"; connectFrom[]={CombatToCrouch,1}; interpolateTo[]={CrouchDying,0.1}; }; }; }; I just made some slight variations on the original BIS anims. Get the documented CfgMoves file for more examples.http://web.quick.cz/fholesinsky/OF/index.html
-
Starting animations from map objects
Unnamed_ replied to Unnamed_'s topic in OFP : CONFIGS & SCRIPTING
It works best when placed by visitor. You should be able to use the method as either a single init event for an island. Or as individual init events for objects placed on the island with visitor. -
Hi, I noticed the old chestnut about starting anims from map based objects, cropped up again. Remembering a couple of posts by Dinger and Bn880 I put this together. As an example add the following user actions to the JOF_Objects1 config for: class JOF_Radar002 <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class UserActions { class JOF_Radar002Init { displayName="Nil"; position="Achse1"; radius=3000; condition="call {private ""_t"";_T=True;If JOF_Radar002 Then {_T=False};If _T Then {JOF_Radar002=True; [This] Exec ""\JOF_Objects1\Radar.sqs""};_T}"; statement=""; }; }; class JOF_Haus006Init <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">class JOF_Haus006Init { displayName="Nil"; position="Achse1"; radius=3000; condition="call {private ""_t"";_T=True;If JOF_Haus006 Then {_T=False};If _T Then {JOF_Haus006=True; [This] Exec ""\JOF_Objects1\Radar.sqs""};_T}"; statement=""; }; When you start a mission on Mapfacts Nogova, both Radars should be working. It's activated when the player is within 2000 meters of the radar (2000m is the max range of user actions?) There are better ways of starting more than one anim, but this was just a quick test. The downside, the following function: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">call {private ""_t"";_T=True;If JOF_Radar002 Then {_T=False};If _T Then {JOF_Radar002=True; [This] Exec ""\JOF_Objects1\Radar.sqs""};_T} Is called every 0.04 seconds for the duration of the mission. But it's only a couple of logic test on some Booleans, so it should not be that bad. Cheers
-
Your script should use the global variable UKF_HMGCount not the local variable _UKFHMGCount. If you drop the underscore and make them all global, then you cant have more than one in a mission. To do that you would have to use global arrays or dynamic global variables (like COC) or store the shot counter as part of the units rating. Assuming there is no OFP script command to get the number of rounds. There are no easy solutions, but I can point you to posts that cover all of the above.
-
Prevent unit from watching unknown objects
Unnamed_ replied to DanAK47's topic in OFP : MISSION EDITING & SCRIPTING
Can you get away with creating a "dumb" soldier with CreateVehicle. Then delete him and create a proper soldier when you want the guy to do something? -
WW2 Mods come second to modern day, according to the OFP info poll. Perhaps it's harder to envisage the Pacific theatre in OFP? Everything I've done so far (Mortars,Beach Landings and Aircraft Carriers) are geared towards getting a MP Mission template, covering WW2 in the Pacific.
-
AFAIK you cant run scripts from objects inside a wrp file, thats sounds like the problem your having? I think you would have to assign the damaged bridge script manualy from the mission editor.
-
My plan was to make the gunners invisible, although you can see him ATM. As I use a dedicated Cargo Slot just for the the rear guns pivot point, I will have the regular aircraft cargo position act like a static, fake gunner. Set positioning is an old idea, but using a dedicated cargo position, allows you to account for pitch and bank when set pos'ing the gun. So IMHO it's an improvment over previous methods. Although the problem of setting the gunners pitch and bank is still there, thats why I still need the invisible gunner ATM. All I want to do, is make the prospect of attacking a close formation of AI bombers, a bit more daunting. WW2 carriers like the Kaga will work well as hard coded runways, there elevated takeoff position will help with some of OFP's logic to. I guess your going to use gamelogics and ObjectID, or something, to activate the turret scripts for static objects? It's just, an ILSPosition without taxiways, defined around the centre of a Map. Will give more flexibility for multiple carriers at just about any location, and I want to code each carrier to reflect it's own particular landing and takeoff procedures. @BraTTy Any plans for dedicated WW2 AA guns? I know there are a few ground based guns in the works, from various MODS. It would be nice to come up with a generic Flak script, to recreate the density you see in the old WW2 movie footage.
-
Hi, Good news, your Corsair is a great addition to OFP, so I'm looking forward to more. I've been messing with this on and off. It's possible to add an AI tail\rear gunner, I added one to the Storch. There not perfect, if you look to close. But then if you do that, you don’t stay alive long enough to spot the flaws I'm hoping this wont be an issue soon, I have just about finished the scripting of a system that supports multiple runways, all that’s left is dotting the I's and crossing the T's. Once that’s done I'll have to test and configure around 80 aircraft and Islands. For example, Gaia has eight individual runways, testing 70+ aircraft on them all takes time. There is also someone else working on a similar system, so don’t worry to much about runway limitations, until you get a chance to check out some of the alternatives.
-
Player markers and names on maps in game
Unnamed_ replied to RN Malboeuf's topic in OFP : MISSION EDITING & SCRIPTING
But how would you break the player names down to individual characters? I suppose you could add a list of predefined player names, would at least work for your clan and regulars. -
Try user actions if your doing it from a config. You can define the radius so only the individual can use it. Plus you can access it from the command menu to. Something like this: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE"> class UserActions { class FOPlotTarget { displayName=$STR_DN_FOPlotTarget; position="zbran"; radius=0.5; condition="([This] Call FO_PlotTarget) and (This==Player) and ([Group This] Call FC_ValidGroup)"; statement="[This] Call FO_MapClick"; }; };