der bastler 0 Posted December 15, 2002 Ok, it seems we can create custom animations (to be used with SwitchMove()) in near future. I found the class CfgMoves in OFP's config. It seems to define the soldier's movement animations. I can create my own animations; I can write my own CfgMoves class; Can I create my own Mech? I guess these entries in the CfgMoves are hard-wired to OFP's control engine. No chance to change it, right? But if I write a script which processes the user's input (cursor up, cursor down, fire) and activates the right output(=animation), it should be possible to simulate a mech? Other idea: I use a tank as base class and connect some walking animations to the tank's track animations... Share this post Link to post Share on other sites
DragoFire 0 Posted December 15, 2002 Why don't you just put the mech/gear/etc... under the class TANK and then simulate "MAN"? I don't know why people think out of the square. DragoFire Share this post Link to post Share on other sites
der bastler 0 Posted December 15, 2002 How does a tank become a tank? Right, with simulation="tank"... Share this post Link to post Share on other sites
DragoFire 0 Posted December 15, 2002 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (der bastler @ Dec. 16 2002,05:58)</td></tr><tr><td id="QUOTE">How does a tank become a tank? Right, with simulation="tank"...<span id='postcolor'> That's right, the same for a plane it simulates a plane. The one thing people forget is when their looking at a addons CPP file, the addon has the same profile as it's parent class, until you add a new setting to your addon's profile which overwrites it's parent's one. So always check out the parent class's CPP setting, to see if anything needs changing. DragoFire Share this post Link to post Share on other sites
der bastler 0 Posted December 15, 2002 But if I define </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE">simulation="soldier"<span id='postcolor'> in an inherited tank class, the new class won't behave like a tank anymore. As you mentioned correctly, this value is overwritten and all corresponding values will be ignored... All classes are derived from a default class which initializes the fields. But if I set a type flag (our simulation=thingy), only a few fields are read and the rest will be ignored. Examples: Soldiers have no turrets, tanks can't walk... So I'd like to know if I can merge two different classes using some kind of work-around... Share this post Link to post Share on other sites
DragoFire 0 Posted December 15, 2002 Have a look at the V80 I think it's called. It's a plane that take-off like to copter, but flies like a plane. I think they were playing around with ideas simular to this. DragoFire Share this post Link to post Share on other sites
philcommando 0 Posted December 16, 2002 er....just my 2cts worth. 1. All animations begins with the model. 2. Animations are created by moving some parts of the body over a period of time. 3. Such body parts are named( selected vertices) 4. The animation is then saved. 5. A body can have several animations, eg sit, stand, prone. 6.Such behavior( animations) are then classified as man, vehicle, heli behaviour. 7. Ofp engine will then animate the named ( selected vertices part) accordingly thru the saved animations file to the type of classification of object when instructed. Therefore:- To use the config file, one must- 1. create the model and name the body parts according to ofp original model, eg...self created human left arm named left_arm must = ofp sniper left arm named in czech. 2. Should u not named the parts correctly, ofp engine will not recognise the object even with the proper config and becomes a static object at best or wont load at worst. Workaround:- 1. Create your own model but animate it using an outside script. ( animation is but the movement of an object's vertices -xyz axis- over a period of time) 2. For Mech makers, perhaps u might wanna download Col Blinks robots, open it O2 and see how he modified an existing ofp soldier into a robot while keeping the body parts named alone. Share this post Link to post Share on other sites
Tanelorn 0 Posted December 16, 2002 Please give me a link to COl. BLink's robots that would be of very great importance to my MOD team. Also using custom animations is very limited right now as you can not give a selection more than one animation. So it is very difficult to animate legs because they have multiple sections that must animate differently yet in unison. Share this post Link to post Share on other sites
philcommando 0 Posted December 16, 2002 oops! sorry, its not Col Blinks...its Cpt Moore's MOD pack 1. The robots are the starwars droids. here's the link. http://ofp.gamezone.cz/index.p....&page=3 Inherent problem of using ofp soldier as model for Mechs:- 1. The cockpit has to be positioned as soldier's head as the head is the most stable part of the body. 2. U cant enter the Mech cos U are the giant Mech. 3. U cant fire or need additional scripts to fire or use another giant weapon. Inherent problem of using ofp tank as model for mechs. 1. Seems only problem is that the Mech can only roll and not walk, which defeat the purpose of Mechs as they are built to go to terrain where tanks cant go or do. Possible solution:- 1. Model and config Mech as tank. 2. Do not model wheel geometry LOD for it. 3. Copy the bottom torso of an ofp soldier's part and use it for your Mech's lower torso - hips, thighs ankle, foot, etc. 4. In ofp your Mech will become a stationery object cos no wheel LOD. However, lower torso movement can be animated by switchmove command of a soldier? The fascination with Mechs probably stems from a US report that the US army were looking for defense contractors to build the 1st generation of amoured exoframes for troops 2 yrs ago. Perhaps the prototype has been built and is currently undergoing trials. Should it be successful and production begins it would be likely only US has such troops. It would be interesting to see how thin skinned soldiers battle with such exoframed troops.;-) Share this post Link to post Share on other sites
Glare 0 Posted December 16, 2002 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE">Should it be successful and production begins it would be likely only US has such troops. It would be interesting to see how thin skinned soldiers battle with such exoframed troops.;-)<span id='postcolor'> Easy same way they fight tanks, ATGM's Share this post Link to post Share on other sites
der bastler 0 Posted December 16, 2002 My fascination with mechs started years ago with some BT books like "decision at thunder rift"... Infantry-fight against mechs? Yes, with "inferno rockets" (napalm)! Never read the books? Back to OFP: - Imho this VTOL-vehicle was a script lifted airplane. - If you use a soldier model for mechs, you can't build a chicken-walker. - With very complex scripting it could be possible to animate a tank with legs, but it would be much easier if BIS includes merging of vehicle classes/creating custom vehicle classes in future patches... Script idea; indefinite loop, polls user controls (silly stile: cpu time consumpting): Player wants to move forward? Move mech a little bit forward and up/down, animate legs (well, you've to calculate kinematics of a 2*6dof-structure ). Share this post Link to post Share on other sites
der bastler 0 Posted December 16, 2002 Here's a robot from my university: BARt-UH Share this post Link to post Share on other sites
Tanelorn 0 Posted December 16, 2002 Combining simulation types is really asking alot. It's a major change in the source code. Many of our problems can be solved, however, if BIS can allow more than one animation per selection. If that can be done, we can use scripting to animate anything the way we want to. Another important extra would be the addition of the "translation" animation that allows selections to move in straight lines. Der Bastler, you wouldn't be interested in forming an alliance with the TA Mod would you? We both are trying to create units that stretch the capabilities of the OFP engine. I won't go so far as to try to recruit you, as you have your own mod (very nice dropship and Pulse Rifle by the way), but I do offer our hand in friendship. =) Of course if you did want to join us, we could very much use a modeler and a map maker. Share this post Link to post Share on other sites
philcommando 0 Posted December 17, 2002 LOL! . If anyone here think the US army gonna pay for some metal box with legs easily destroyed which any guy with a garage can construct, u gotta be kidding! Some of the specs the US army would require for their exoframes are- 1. Able to shoot down rockets and missiles - incorporation of Reagan's starwars programme? Multi arry radar guided laser cannons successfully tested on White Sands test range in june02? 2.Stealth - extension of the current F117 and upcomming stealth boats technology so that the mech doesnt show up like a Christmas tree on radar? 3. Smaller control units - latested intel chips? 4. Avoidance of artillery barrage - Jet packs? Titanium alloy shell construction for toughness but light to achieve speeds beyond 300km/hr? 5. Power - energy derived from scaled down and controlled decaying of uranium? 6. Force field - high enery magnetic pulses to deflect metal based projectiles? I am sure the actual list is long ( perhaps a minifridge with budwiser to go along too?) My point of this post is to support der Bastler interest in mech. To some folks mechs are just 'silly metal box with legs better off playing the Mechwarrior series', but to others, with the right script and codes, the mech will be a demostration of eventual battlefields to come, the use of one's wit and bravery to overcome an enemy - nation state or guerillas - who have exotic arsenal. Disclaimer:- No actual human blood was shed, animals harmed or trees destroyed while battling it out in OFP! Share this post Link to post Share on other sites
der bastler 0 Posted December 17, 2002 @philcommando: </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE"> LOL! . If anyone here think the US army gonna pay for some metal box with legs easily destroyed which any guy with a garage can construct, u gotta be kidding! <span id='postcolor'> Was that related to BARt-UH? @Tanelorn: A cooperation in certain projects e.g. mechs? Sure... Share this post Link to post Share on other sites
philcommando 0 Posted December 18, 2002 Nope, der Bastler, i wasnt referring to it. I think your BARt-uh is great and obviously it is not the finished product yet but a prototype of the future for advance mobility of artificially created intelligence. All the best! Share this post Link to post Share on other sites
1B1KSniper 0 Posted December 22, 2002 My mod also needs help in the same area, as we will be making an AT-AT and AT-PT... and those will be pretty hard to do as well... Share this post Link to post Share on other sites
soul_assassin 1750 Posted December 22, 2002 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (der bastler @ Dec. 17 2002,16:11)</td></tr><tr><td id="QUOTE">@philcommando: </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote </td></tr><tr><td id="QUOTE"> LOL! . If anyone here think the US army gonna pay for some metal box with legs easily destroyed which any guy with a garage can construct, u gotta be kidding! <span id='postcolor'> Was that related to BARt-UH?<span id='postcolor'> LOL Share this post Link to post Share on other sites
stoppelhopser 0 Posted March 9, 2003 hmmmm... i read this post with interest! i have no interest in mechs at all, but i try to find out a s much as possible about what you can do to ofp. and i might be wrong but: i think there´s only two limits set to creating new types of vehicles: 1.) class CfgVehicles::All{}; 2.) your time and stamina so you wanna do mechs? well i don´t see why you couldn´t make a soldier with a turret and a gunner proxy. class All{} provides it as far as i can see. the only prob here is the animations. the set of anims for ofp doesn´t provide mech anims, but you can always define a whole custom set of anims by creating your own cfgVehicleActions, cfgManActions and CfgMoves classes and, and here comes the tuff one, your own f***in set of anims (amount unlimited!. sure you can´t add any new <sections> to your model as they won´t be treated by the engine, but i think with a flexible anim tool you can always define custom "named selections" for your model in o2 and animate them. if it works as i suppose, the .rtm file is scanned for named selections and it´s corresponding move is then performed... if you define a selection like "pendular", and have that selection swing left-to-right in an anim, i bet ofp will swing it, too. but as i already said.... i might be wrong Share this post Link to post Share on other sites
Sigma-6 29 Posted March 9, 2003 Are you saying that I might be able to create a brand new custom class if I was willing to code its inheritance in all aspects directly up from the 'all' class? If so, you are my saviour, and I will kiss you. What I'm hoping for here is an explanation from a BIS staff member telling me it can't be done so that I don't have to kiss this guy. . . Share this post Link to post Share on other sites
der bastler 0 Posted March 9, 2003 The problem is that some class fields are ignored by OFP if others are set. E.g. simulation="soldier" -> turret values are ignored. That's hard-wired to OFPs core engine (imho). Other way: Create Mech, defined as tank. Arms=canon, torso=turret, no engine inside. Create some animations for walking, shutdown sequence etc. Add eventhandlers to execute something like "Mechcontrol.sqs" Script "Mechcontrol.sqs" plays the animations depending on the player's input, controls heat dissipation etc. How to get the input? Create a camera, set it to "manual on", read it's velocity values... Here's a small test, just exec this script inside a mission (player exec "thisscript.sqs"): </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Code Sample </td></tr><tr><td id="CODE"> _meinepos = GetPos _this _meinekamera = "Camera" CamCreate _meinepos _meinekamera camCommand "Manual on" _meinekamera camCommand "Interia off" _meinekamera camCommit 0 _zaehler = 10; #schleife ~1 _richtung = GetDir _meinekamera _positionx = (GetPos _meinekamera) select 0 _positiony = (GetPos _meinekamera) select 1 _positionz = (GetPos _meinekamera) select 2 _geschwx = (Velocity _meinekamera) select 0 _geschwy = (Velocity _meinekamera) select 1 _geschwz = (Velocity _meinekamera) select 2 hint(format["dir: %1\nx: %2 Â vx: %5\ny: %3 Â vy: %6\nz: %4 Â vz: %7\nCountdown: %8",_richtung,_positionx,_positiony,_positionz,_geschwx,_geschwy,_geschwz,_zaehler]) _zaehler = _zaehler - 1 ?(_zaehler > 0):goto "schleife" camDestroy _meinekamera exit <span id='postcolor'> There will be a hint-output, which will display... ...vy=+4 if you walk forward ...vy=+16 if you run forward ...vy=-4 if you walk backward etc... Now you could say: ?(vy=4): playmove(MechWalkForwardAnim) ?(vy=16): playmove(MechRunForwardAnim) ?(vx=-4): playmove(MechSidestepLeftAnim) I'm still analysing ProSphere Lite (can't read dir-value yet), but I think that's the way... Share this post Link to post Share on other sites