Outerra forum

User mods, screenshots & videos => Vehicles => Tracked vehicles => Topic started by: M7 on April 26, 2013, 04:56:22 pm

Title: Tiger2
Post by: M7 on April 26, 2013, 04:56:22 pm
Found this tiger2 in a free 3d model site. It had pretty good textures and i used it as a test to add a normal map texture. I may have gone overboard with it, i just learned how to make normal map, so it had to be obvious :-)  It's  just an object for  now but i might make it into a drivable vehicle.

(http://imageshack.us/a/img19/2572/tigerda.jpg)

(http://imageshack.us/a/img13/1276/tiger2k.jpg)

edit: Here's the up to date version of this Tiger2. As it get improve, i will update this file.
https://docs.google.com/file/d/0B96RrTcNJsI2dm5Yc3JiZmdWZ3c/edit?usp=sharing (https://docs.google.com/file/d/0B96RrTcNJsI2dm5Yc3JiZmdWZ3c/edit?usp=sharing)
Title: Re: Tiger2
Post by: Zirran on April 26, 2013, 06:09:03 pm
I see a theme going on here in the Tracked Vehicles section of the forum. Anyone else see it? ;)

Nice pics.
Title: Re: Tiger2
Post by: PytonPago on April 27, 2013, 02:09:50 am
That is some nice piece of germany´s tech in OT !  ;D
Title: Re: Tiger2
Post by: M7 on April 27, 2013, 02:44:30 am
Now fully mobile... 8)

https://docs.google.com/file/d/0B96RrTcNJsI2WUpOVDRQUWdZbFU/edit?usp=sharing

I played some tricks with the steering. I gave a very low turning rate to all wheels (front positive, back negative turning) so that it could look like a real tank steering. Now will wait for turrets to turn and  tracks to animate.
Title: Re: Tiger2
Post by: ZeosPantera on April 27, 2013, 03:05:16 am
Looks good considering the hackery of the steering mechanic. It does need a bit more admin love.
Title: Re: Tiger2
Post by: M7 on April 27, 2013, 11:41:33 am
Here's a bunch of these babies!

tiger2 (http://www.youtube.com/watch?v=fKyHbwKpZ7I#)
Title: Re: Tiger2
Post by: PytonPago on April 28, 2013, 04:58:38 am
Here's a bunch of these babies!

tiger2 (http://www.youtube.com/watch?v=fKyHbwKpZ7I#)

Tiger 2 battlegroup ready to take the light-tower !  ;D  ... they look awesome.
Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 01:19:41 pm
Please enjoy this attached physics V1..

I would like to add full engine simulation and have the wheels at least turn with some more maths. As a quick one hour hack it works pretty well. Give it a shot.

http://www.mediafire.com/view/?5pvp2z725w473kg (http://www.mediafire.com/view/?5pvp2z725w473kg)

Title: Re: Tiger2
Post by: M7 on April 30, 2013, 01:25:00 pm
dont see the attachment. I actually reworked the original collada to get the turret and cannon as bone. Might need some help to get the geometry code done right.

edit: ah see it now
Title: Re: Tiger2
Post by: M7 on April 30, 2013, 01:43:20 pm
thought you would have tried to hack Cameni tank config

Here I've got one tank script with turning, done for another user (murkz), it may be helpful for you:

Code: [Select]
//vehicle script file
//see http://xtrac.outerra.com/index.fcgi/wiki/vehicle for example and documentation

//invoked only the first time the model is loaded, or upon reload
function init_chassis(){
  var wheelparam = {
    radius: 0.46,
    width: 0.20,
    suspension_max: 0.2,
    suspension_min: -0.35,
    //ride height   
    suspension_stiffness: 3.0,

    damping_compression: 0.2,
    damping_relaxation: 0.12,
    slip: 0.5,
    roll_influence: 0.1
  //rotation: -1
  };
  this.add_wheel('wheel1', wheelparam);
  this.add_wheel('wheel2', wheelparam);
  this.add_wheel('wheel3', wheelparam);
  this.add_wheel('wheel4', wheelparam);
  this.add_wheel('wheel5', wheelparam);
  this.add_wheel('wheel6', wheelparam);
  this.add_wheel('wheel7', wheelparam);
  this.add_wheel('wheel8', wheelparam); 
  this.add_wheel('wheel9', wheelparam);
  this.add_wheel('wheel10', wheelparam);
  this.add_wheel('wheel11', wheelparam);
  this.add_wheel('wheel12', wheelparam);
  this.add_wheel('wheel13', wheelparam);
  this.add_wheel('wheel14', wheelparam);
  this.add_wheel('wheel15', wheelparam);
  this.add_wheel('wheel16', wheelparam);
  return {mass:7530, steering:2.0, steering_ecf:60, centering: 10, centering_ecf:20};
}

//invoked for each new instance of the vehicle
function init_vehicle(){
  this.set_fps_camera_pos({x:-0.33,y:2.00,z:2.10});
}

//invoked when engine starts or stops
function engine(start){
}


const EF = 10000.0;
const BF = 4000.0;
const maxkmh = 50;
const forceloss = EF / (0.2*maxkmh + 1);

//invoked each frame to handle the inputs and animate the model
function update_frame(dt, engine, brake, steering){
  var kmh = this.speed()*3.6;
 
  //reduce engine force with speed (hack)
  var redux = engine>=0 ? 0.2 : 0.6;
  var esign = engine<0 ? -1 : 1;
  engine = EF*Math.abs(engine);
  var force = (esign>0) == (kmh>=0)
        ? engine/(redux*Math.abs(kmh) + 1)
        : engine;
  force -= forceloss;
  force = Math.max(0.0, Math.min(force, engine));
  engine = esign*force;
   
  var el = steering>0 ? 0 : engine;
  var er = steering<0 ? 0 : engine;

  this.wheel_force(0, el);
  this.wheel_force(2, el);
  this.wheel_force(4, el);
  this.wheel_force(6, el);
  this.wheel_force(8, el);
  this.wheel_force(10, el);
  this.wheel_force(12, el);
  this.wheel_force(14, el);
   
  this.wheel_force(1, er);
  this.wheel_force(3, er);
  this.wheel_force(5, er);
  this.wheel_force(7, er);
  this.wheel_force(9, er);
  this.wheel_force(11, er);     
  this.wheel_force(13, er);
  this.wheel_force(15, er);
   
  brake *= BF;
  var bl = steering>0 ? BF*steering : 0;
  var br = steering<0 ? -BF*steering : 0;
  bl += brake;
  br += brake;
 
  this.wheel_brake(0, bl);
  this.wheel_brake(2, bl);
  this.wheel_brake(4, bl);
  this.wheel_brake(6, bl);
  this.wheel_brake(8, bl);
  this.wheel_brake(10, bl);
  this.wheel_brake(12, bl);
  this.wheel_brake(14, bl);
   
  this.wheel_brake(1, br);
  this.wheel_brake(3, br);
  this.wheel_brake(5, br);
  this.wheel_brake(7, br);
  this.wheel_brake(9, br);
  this.wheel_brake(11, br);     
  this.wheel_brake(13, br);
  this.wheel_brake(15, br);

  this.animate_wheels();
}
Title: Re: Tiger2
Post by: M7 on April 30, 2013, 02:04:16 pm
Your config look more realistic for sure especially when climbing hills, these thing should not have been very swift climbing up. I tried Cameni script for tank but still it  doesn't turn. Might need to have a separate clutch for each side or something.
Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 02:31:34 pm
When I use to code Expression 2's in Gmod for tanks I would have a simple system in the code that could look at the keys (WSAD) and when a different combination was used the forces would change per side..

So

{W} alone meant TrackL and TrackR get +1
{S} alone meant TrackL and TrackR get -1
{A} alone meant TrackL gets -1 TrackR get +1
{D} alone meant TrackL gets +1 TrackR get -1

If needed for a static turn the value could be hire so that more torque was used to twist the vehicle.. IE {D} alone meant TrackL gets +3 TrackR get -3

When on the move a turn would be..


{W+A} meant TrackL gets 0 TrackR get +1
{W+D} meant TrackL gets +1 TrackR get 0
{S+A} meant TrackL gets 0 TrackR get -1
{S+D} meant TrackL gets -1 TrackR get 0

That was back in the Garrys mod days for me. I would need to re-learn how to actually code to be useful here.
Title: Re: Tiger2
Post by: M7 on April 30, 2013, 02:49:49 pm
i haven't play many tank games, mostly  WW2OL. They use brakes and clutch to stear.  That's probably how it is done in RL not sure.  So if you brake on the left side, you did need to have the clutch on as well so that the engine doesnt power that side while braking/turning left. Not sure if tracks could turn in reverse direction at the same time in the 40s though....
Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 03:11:48 pm
I will diddle around with Cameni's script. I have the basic concept but need to work out the syntax to get it working.
Title: Re: Tiger2
Post by: cameni on April 30, 2013, 04:11:35 pm
Murkz pointed me to a nice doc about it: http://www.gizmology.net/tracked.htm (http://www.gizmology.net/tracked.htm)
Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 04:40:09 pm
Fiddled.. The animations are backward but everything else works swimmingly.
Title: Re: Tiger2
Post by: M7 on April 30, 2013, 04:48:04 pm
pretty good! Now if there was somekind of clutch on each side, it could turn while moving
Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 07:21:11 pm
Well the way it should work is a brake is applied to one side and it turns. Which is what is happening right now. The problem is the mechanics of the real tank transfer some of the power/speed from the braking side to the moving side so it can maintain itself. Lots of gears doing things.
Title: Re: Tiger2
Post by: M7 on April 30, 2013, 10:41:39 pm
I trying to get something that sound like a tank. I know nothing about these things so i tried to find something on the net and quite expectively, nothing sounded any good. but i did find some youtube video that had ok sound. Actuall i found one with a tiger 2 driving around. So i got myself a copy of audacity and tried to edit some sample. So far i think i got something ok for the idle state. But it sounds crap whenever it get a pitch change, so i will try to get 4 sample of the tiger and ill test by hackingh mLichy Belair  ;) since i wouldn'know how to integrate that kind of script to the tiger script yet.


Title: Re: Tiger2
Post by: ZeosPantera on April 30, 2013, 11:16:20 pm
Mother of god... LOUD.

I was thinking about finding a good clip of the track squeaking like from Indiana Jones.. Not sure how that would do with a pitch mod.

Here is the island I am using for tank testing. http://goo.gl/maps/3aB8x (http://goo.gl/maps/3aB8x)

I would love to re-create that ring road around the island. Looks like an epic drive!
Title: Re: Tiger2
Post by: M7 on May 01, 2013, 01:55:35 am
oh boy!! i think i'm on something. Have to say that i was going nowhere  until i played with this

this.pitchMultiplier = 0.6; that's the setting it was on, i changed it to 1.9 and wow ! that was it. It does sound way better than the original sound recorded on youtube. Yet it's not that far from the real thing. Again i'm really no expert to really tell.

I've attached a sample the sound i hear in game while decelarating.
Title: Re: Tiger2
Post by: ZeosPantera on May 01, 2013, 02:22:42 am
Not bad.
Title: Re: Tiger2
Post by: M7 on May 02, 2013, 02:41:08 pm
I tried so much stuff to get something that could sound somehow right. First i tried to use the BMW kind of js config with 3 sound , idle, onlow, offlow. The off low (decelaration) was good  but could not get the onlow (acceleration) to sound anything good. Next i tried to use the tatra .js . It use only one sound for driving and idle state,  but it use shifting gear in a way that the pitch variation dont get too extreme. In the end i find it doesn't sound too bad but still not what i had in mind . 

But now the problem is that i could not copy/paste  the new tatra config and make work that into the tiger  config. I always get syntax error.

Anyhow, here's the tatra with the edited sound for the tiger eventually . Zeos you're welcome to try yourself if you feel like!!

https://drive.google.com/folderview?id=0B96RrTcNJsI2RGlWeVpNUnUya2M&usp=sharing
Title: Re: Tiger2
Post by: ZeosPantera on May 03, 2013, 03:55:18 am
Got the sound working. Now we need to get the wheel animations the right way.

Config Attached.
Title: Re: Tiger2
Post by: M7 on May 03, 2013, 09:04:27 am
That's great, thanks a lot! everything seems to load right but there's something with the sound that is kind of messed up compare to the  tatra version i edited. And looking at both .js, I can't understand yet what could cause that. It's like the new tiger version, the sound seems to switch back and forth between one ear to the other as speed goes up, where in the Tatra i dont ear these wobling sound .
Title: Re: Tiger2
Post by: ZeosPantera on May 03, 2013, 11:09:24 am
Wait a sec.. What did you parent the sound to? Does it rotate?
Title: Re: Tiger2
Post by: M7 on May 03, 2013, 11:32:59 am
 I just copy paste your new script into the tiger vehicle and i didn't edit anything yet.
 Now the sound emiter was set  to one  wheel,  i changed it to the chassis and  the engine still woble.

You should hear the same thing don't you?
Title: Re: Tiger2
Post by: ZeosPantera on May 03, 2013, 11:55:56 am
Yeah but I figured it was something to do with the looping of the sound file. I hadn't tried it with the tatra.

What is the chassis name so I can set the emitter to it.
Title: Re: Tiger2
Post by: M7 on May 03, 2013, 02:20:34 pm
the chassis name is  chassis
Title: Re: Tiger2
Post by: ZeosPantera on May 03, 2013, 03:17:02 pm
Devious.
Title: Re: Tiger2
Post by: M7 on May 03, 2013, 04:14:18 pm
sorry, just saw that using chassis as the name of the emiter, doesn't work even though it's the name of the parent group  of the vehicle  i gave in sketchup. But i didn't made it a bone so that's probably why you cant use it as emiter, i dont know. So looks like you can only set one of the wheel as emiter.

In the tatra js the emiter is set on a .... wait a sec. ... i was about to say that it's set on a wheel but no it is set on the half axle which doesn not turn!!!!

 this.add_sound_emitter("halfaxle_l0");

so that might be the reason it is not wobleling on the tatra. I will reimport the tiger and add the chassis as bone this time and see if it make a difference.

Title: Re: Tiger2
Post by: M7 on May 03, 2013, 05:12:30 pm
Yep i reimported the dae file and adding chassis as a bone and voilà! nomore wobling. Thanks Zeos for the cue about the wheel emiter!!!

I also reimported an other version of the tiger, this time with the 'turret' and the 'cannon' as separate bone so these could be scripted to rotate. I have a problem atm with google drive though. I can upload the .rar file but i cant see it in the browser, so i can't share it yet. As soon as it show, i'll put the link.
Title: Re: Tiger2
Post by: ZeosPantera on May 03, 2013, 09:54:25 pm
Yeah the Google drive and MSN skydrive systems are slow. Easy to edit but I still like my mediafire for just strait filesharing. \\

Oh, any luck fixing the wheel animations? They are still very backward.
Title: Re: Tiger2
Post by: M7 on May 03, 2013, 11:46:24 pm
I didn't actually notice the wheels, i was so focused on the sound but no i have no idea what could cause that.

Now here's the new tiger with new bones ( turret, cannon) . It does have issue with the normal map texture (which it lack now) . Eventually i'll replace the tiger2 with this one when every think has been fixed.

https://docs.google.com/file/d/0B96RrTcNJsI2c2VUZ1FTd3NROFU/edit?usp=sharing
Title: Re: Tiger2
Post by: deathevor on May 04, 2013, 12:43:09 pm
Just in case, you can export your model from Outerra as a single file. And share it.
Easier to install. Works like a charm.
Title: Re: Tiger2
Post by: M7 on May 04, 2013, 12:58:23 pm
Ah cool! Will use the export next time cause now i have been messing up with the textures. This is a quick test for camo color. Didn't work on a a nice pattern yet, i just wanted to get the color right for now..

(http://imageshack.us/a/img706/7025/tigercamo.jpg)
Title: Re: Tiger2
Post by: ZeosPantera on May 04, 2013, 01:34:08 pm
Sexy. I guess we are waiting for Cameni to explain how to code the turret to move?
Title: Re: Tiger2
Post by: cameni on May 04, 2013, 02:03:48 pm
There's an example in the wiki http://xtrac.outerraworld.com/trac.fcgi/wiki/action_code (http://xtrac.outerraworld.com/trac.fcgi/wiki/action_code)
Title: Re: Tiger2
Post by: M7 on May 04, 2013, 06:11:26 pm
Now in winter gear. Pretty easy to edit the overall color.

(http://imageshack.us/a/img211/4108/tigerwinter.jpg)

(http://imageshack.us/a/img841/1204/tigerwinter2.jpg)
Title: Re: Tiger2
Post by: PytonPago on May 05, 2013, 04:40:59 am
That is some Eye-Candy camo !  ;)
Title: Re: Tiger2
Post by: M7 on May 05, 2013, 05:07:56 am
That is some Eye-Candy camo !  ;)

Thanks! I actually got that effect by accident while playing with the texture in photoshop, but it looks so right when it first appeared, i couldn't believe it would be so simple.

Now i updated the summer version with murkz script. Thanks murkz!!!

https://docs.google.com/file/d/0B96RrTcNJsI2dm5Yc3JiZmdWZ3c/edit?usp=sharing

I fixed the wheels, they now turn in the right direction 

Still a few bugs. Barrel wont move up, startup sound wont play.
Title: Re: Tiger2
Post by: murkz on May 05, 2013, 05:18:23 am
You are very welcome M7.

Really nice work on the Tiger 2 script, it sounds great. I have a turret sound I can pass along if you can get it to play when the turret rotates.

Cameni is the guy who takes all the credit for the script, I did a very little bit research for him and some testing.

I hope the talented guys we have here can now take this script to the next level. Gears and associated sounds would be nice as a start.
Title: Re: Tiger2
Post by: M7 on May 05, 2013, 01:05:46 pm
Quote
Really nice work on the Tiger 2 script, it sounds great.

Thanks but i know very little about scripting, I wish i knew more about that stuff. i pretty much rely on Zeos to get these things working actually  ;D. Thanks Zeos!!!! but i'm fairly happy with how the main engine sound so far.

 I'm actually wondering if it's possible to have multiple sounds from one vehicle at this same time. Would be great to have separate sound like engine , transmission gear (the kind of sustained high pitch noise) , gear changing, turret sound, squiking tracks that can play simultaniusly . I imagine it would be a mess to script these thing , so i will have to wait and vulture these when they show up in the forum. 

Quote
I have a turret sound I can pass along if you can get it to play when the turret rotates.

That would be so cool. Though i did find a  video with good sound of a panther turret rotating. though. It will  save me the trouble to edit it for something else.

Quote
I hope the talented guys we have here can now take this script to the next level. Gears and associated sounds would be nice as a start.

That's an exciting prospect to think of how these things will buiild up in the future.
Title: Re: Tiger2
Post by: ZeosPantera on May 05, 2013, 11:35:47 pm
I am very sure you can have a bunch of sound all emitting at the same time.

And don't rely too much on my coding ability. I just have a talent for hammering my keyboard until things work.
Title: Re: Tiger2
Post by: murkz on May 06, 2013, 02:08:30 am
We have a bunch of sounds created by SirDieaLot for T34 vs Tiger that we would really like to see added to the Tiger and G.

New corrected gun elevation and depression figures for you M7:

const MinTurretAngle = -8;  //deg gun depression
const TurretAngleSpan = 15; //deg gun elevation

*Germany's Tiger Tanks VK45.02 to Tiger II page 154
Title: Re: Tiger2
Post by: murkz on May 06, 2013, 04:31:07 am
Here are the turret rotation speeds for the Tiger 2. I have no idea how, or if it is possible to have this simulated but it is here for completeness :)

(http://farm9.staticflickr.com/8557/8712593935_21e9f1d40d_o.jpg)
Title: Re: Tiger2
Post by: M7 on May 06, 2013, 08:09:05 am
Perfecto!

Do you have a t-34 in the works? I know i found a nice one, more detailed than the tiger2,  in the sketchup warehouse but it has no texture. There's quite a few more that could look incredable in the right texture artist hand.

(http://imageshack.us/a/img802/5987/t34stug.jpg)
Title: Re: Tiger2
Post by: PytonPago on May 06, 2013, 08:39:09 am
Here are the turret rotation speeds for the Tiger 2. I have no idea how, or if it is possible to have this simulated but it is here for completeness :)



 .... 300 + turns on manual  ? .. Lets simulate the manual control - get the mouses burning !  ;D   .... how is the gear to the turret function, if its track-gearbox dependent ?
Title: Re: Tiger2
Post by: M7 on May 06, 2013, 09:01:03 am
Here are the turret rotation speeds for the Tiger 2. I have no idea how, or if it is possible to have this simulated but it is here for completeness :)



Interesting!. Cameni did add some extra button to play with. Could probably use some of them for this kind of stuff.

Now here's the latest tiger2 version. I also added a link on the first page.
https://docs.google.com/file/d/0B96RrTcNJsI2dm5Yc3JiZmdWZ3c/edit?usp=sharing
Title: Re: Tiger2
Post by: murkz on May 06, 2013, 09:22:23 am
Here are the turret rotation speeds for the Tiger 2. I have no idea how, or if it is possible to have this simulated but it is here for completeness :)



 .... 300 + turns on manual  ? .. Lets simulate the manual control - get the mouses burning !  ;D   .... how is the gear to the turret function, if its track-gearbox dependent ?

I know it was hydraulically driven and I am guessing engine rpm dependent.
Title: Re: Tiger2
Post by: Chaoz on May 06, 2013, 10:29:56 am
i noticed that the tank is speeding up crazy fast when in reverse, there must be something wrong
Title: Re: Tiger2
Post by: M7 on May 06, 2013, 10:43:34 am
Quote
i noticed that the tank is speeding up crazy fast when in reverse, there must be something wrong

Yeah just noticed that. No idea atm how to fix it.
Title: Re: Tiger2
Post by: cameni on May 06, 2013, 11:10:09 am
It's a bug in max_rpm and max_tire_speed not returning signed values.
Title: Re: Tiger2
Post by: ZeosPantera on May 06, 2013, 12:18:35 pm
Wow. Imagine building an actual manual turret control setup.. Infinitely rotatable control platforms do exist so.. Get turnin'.

Also that T34 is so nice but if we are living out our fantasies.. A T28 would be more appropriate.

(http://www.angelfire.com/ak3/DamselsandDuelists/images/T28.JPG)
Title: Re: Tiger2
Post by: PytonPago on May 08, 2013, 02:44:26 am
Wow. Imagine building an actual manual turret control setup.. Infinitely rotatable control platforms do exist so.. Get turnin'.

Also that T34 is so nice but if we are living out our fantasies.. A T28 would be more appropriate.
   
 
... well, i want to see the manual turning controls for that one Zeos. Would need a battleship canon gearbox platform.  ;D :D ;D ;D ;D ... Do you plan to make realistic insides ? Or just gun sighting/driver periscope views ?
Title: Re: Tiger2
Post by: murkz on May 08, 2013, 03:30:49 am
I have this labour of love, that is a long way off being finished but I hope to finish one day

http://theantisocialgamer.blogspot.co.uk/2012/08/tiger-2-interior-revisit.html (http://theantisocialgamer.blogspot.co.uk/2012/08/tiger-2-interior-revisit.html)

(http://3.bp.blogspot.com/-v0nucvNyN6o/UB4uD7JykUI/AAAAAAAACLE/JE9ugIFM2QY/s1600/render8.png)
Title: Re: Tiger2
Post by: PytonPago on May 08, 2013, 04:27:12 am
I have this labour of love, that is a long way off being finished but I hope to finish one day ...


THAT is definitely My and Zeoses kind of model standard thinking for OT.  ;D ;D Your got my attention on that work progressing !   ;) 
Title: Re: Tiger2
Post by: M7 on May 08, 2013, 09:46:24 am
wow, the immersion factor will be amazing to drive/shoot from inside this thing.
Title: Re: Tiger2
Post by: ZeosPantera on May 08, 2013, 12:56:34 pm
Make it so.
Title: Re: Tiger2
Post by: murkz on May 29, 2013, 07:15:27 am
http://www.mediafire.com/?13e4n8xq7tii17a (http://www.mediafire.com/?13e4n8xq7tii17a)

I hope you don't mind M7, I have updated the Tiger 2 to work with the new build released yesterday, as turrets now use a different code. I have also set the turret speed to 54 seconds.

Title: Re: Tiger2
Post by: M7 on May 29, 2013, 09:32:00 am
Perfecto! tanks! ;D
Title: Re: Tiger2
Post by: Revolver on May 30, 2013, 07:42:09 am
Hallo Murkz.

If it helps you anyhow, here is an original drawing of KwK36-Kannone, that
in the PzKw-VI was grown.

(http://www10.pic-upload.de/thumb/30.05.13/iyf7yn6wr6d.jpg) (http://www.pic-upload.de/view-19523824/KwK36.jpg.html)

Are dark grey to movable parts.
Firm parts are light grey.
  ;)

Cheers,

Stefan
Title: Re: Tiger2
Post by: M7 on May 30, 2013, 09:30:18 am
I know i already have the cannon set as separate bone so All is needed is a fire action and the animation script.
Title: Re: Tiger2
Post by: ZeosPantera on May 30, 2013, 09:59:03 am
These are the kind of posts I like.. Super descriptive German tank cannon diagrams!

The devil really is in the details.
Title: Re: Tiger2
Post by: bugsblake on May 30, 2013, 01:52:26 pm
thanks for the tiger2! its coming along real nice! cant wait to fire this thing! :D
Title: Re: Tiger2
Post by: PytonPago on September 13, 2013, 11:45:23 am
i just tried the panzer out and mentioned, the turret just jumps between max and min positions during controlling, or have i just got a bad link ? ... if its truly bad, i played whyte it a little :

Code: [Select]
//vehicle script file
//see http://xtrac.outerra.com/index.fcgi/wiki/vehicle for example and documentation
var turret,mantlet,barrel;


const MaxTurretXSpeed = 10; //deg/s
const MaxTurretYSpeed = 10; //deg/s
const MaxTurretXAccel = 120;//deg/s^2
const MaxTurretYAccel = 160;//deg/s^2
const MinTurretAngle = -8;  //in deg  gun depression
const MaxTurretAngle = 10; //in deg  gun elevation
const TurningBoost = 0.4;   //boost coefficient to help with turning at speed
const TurnForceCoef = 0.8;  //portion of engine force for neutral turns
const RollingFriction = 1000;//force that needs to be overcome to get wheels turning
const EF = 25000.0;         //engine force
const BF = 20000.0;         //braking force
const EFr = 0.02;           //engine force reduction coef with speed
const maxkmh = 40;          //top speed



function radians(v){
  return v*Math.PI/180.0;
}


//invoked only the first time the model is loaded, or upon reload
function init_chassis(){
  var wheelparam = {
    radius: 0.50,
    width: 0.20,
    suspension_max: 0.25,
    suspension_min: -0.25,
    //ride height   
    suspension_stiffness: 3.9,

    damping_compression: 0.5,
    damping_relaxation: 0.4,
    slip: 0.5,
    slip_lateral_coef: 0.7,
    roll_influence: 0.1
  //rotation: -1
  };
  this.add_wheel('2a', wheelparam);
  this.add_wheel('2b', wheelparam);
  this.add_wheel('3a', wheelparam);
  this.add_wheel('3b', wheelparam);
  this.add_wheel('4a', wheelparam);
  this.add_wheel('4b', wheelparam);
  this.add_wheel('5a', wheelparam);
  this.add_wheel('5b', wheelparam);
  this.add_wheel('6a', wheelparam);
  this.add_wheel('6b', wheelparam);
  this.add_wheel('7a', wheelparam);
  this.add_wheel('7b', wheelparam);
  this.add_wheel('8a', wheelparam);
  this.add_wheel('8b', wheelparam);
  this.add_wheel('9a', wheelparam);
  this.add_wheel('9b', wheelparam);
  this.add_wheel('10a', wheelparam);
  this.add_wheel('10b', wheelparam);
 
  var geom = this.get_geomob(0);
  turret = geom.get_joint('turret');
  mantlet = geom.get_joint('mantlet');
  barrel = geom.get_joint('barrel');
 
  this.load_sound("tiger2_eng_starter.ogg");
  this.load_sound("tiger2_forward.ogg");
  this.load_sound("turret.ogg");
  this.add_sound_emitter("turret");
  this.add_sound_emitter("mantlet");

 
  return {mass:20000, com:{z:0.1,y:0.0}, steering:2.0, steering_ecf:60, centering: 100, centering_ecf:20,
   
  };
}

//invoked for each new instance of the vehicle
function init_vehicle(){
  //this.set_fps_camera_pos({x:-0.5,y:2.15,z:1.14});//commander view
  this.set_fps_camera_pos({x:-0.5,y:-0.3,z:2.5});//driver view
  this.snd = this.sound();
  this.snd.set_ref_distance(0, 15.0);
    this.geom = this.get_geomob(0);
  this.turx = new axis_integrator(radians(MaxTurretXSpeed), radians(MaxTurretXAccel));
  this.tury = new axis_integrator(radians(MaxTurretYSpeed), radians(MaxTurretYAccel), radians(MinTurretAngle), radians(MaxTurretAngle));
  this.turretsnd = 0;
}


//invoked when engine starts or stops
function engine(start){
  if(start){
    this.snd.play(0, 0, false, false);
    this.snd.play(0, 1, true, true);
  }
  else
    this.snd.stop(0);
  this.started = start;
}

//handle extra actions
function action(k,v,dt)
{
      switch(k){
     
        //Turret movements
     
  case ATurretX: this.turx.set(v); break;
  case ATurretY: this.tury.set(v); break;
    }
}

const forceloss = 1.0 / (EFr*maxkmh + 1);

//invoked each frame to handle the inputs and animate the model
function update_frame(dt, engine, brake, steering)
{
 
 
  //turret handling
  var tmov=false;
  if(this.turx.changed(dt)){
    this.geom.rotate_joint_orig(turret, this.turx.value, {x:0,y:0,z:-1});
 
   
    tmov = true;
  }
  if(this.tury.changed(dt)){
    this.geom.rotate_joint_orig(mantlet, this.tury.value, {x:1,y:0,z:0});
    tmov = true;
  }
  if(tmov) {
    if(!this.turretsnd)
      this.snd.play_loop(1, 2);
  }
  else this.snd.stop(1);
  this.turretsnd = tmov;
 
 
  var kmh = this.max_tire_speed()*3.6;
 
  //reduce engine force with speed (hack)
  var esign = engine<0 ? -1 : 1;
  engine = EF*Math.abs(engine);
  var force = (esign>0) == (kmh>=0)
        ? 1.0/(EFr*Math.abs(kmh) + 1)
        : 1.0;
  force -= forceloss;
  force = esign*Math.max(0.0, Math.min(force, 1.0));
  engine *= force;
   
  this.snd.set_pitch(0, 1+0.01*kmh);
   
  //if(steering!=0) engine *= 1.5;
  //var el = steering>0 ? 0 : engine;
  //var er = steering<0 ? 0 : engine;
  var df = EF*TurnForceCoef*force;
  var el=engine,er=engine;
  var spd = 1 + TurningBoost*this.speed();
  if(this.started){
    if(steering>0){
      el-=spd*df; er+=df;
    }
    else if(steering<0){
      er-=spd*df; el+=df;
    }
  }

  this.wheel_force(-2, el);
  this.wheel_force(-3, er);
   
  brake *= BF;
  brake += RollingFriction;

  this.wheel_brake(-1, brake);

  //this.log_inf("L:"+el+" R:"+er+"   B:"+brake+"  SPD:"+kmh);
 
  //this.geom.rotate_joint_orig(turret, this.turx, {x:0,y:0,z:-1});
  //this.geom.rotate_joint_orig(mantlet, this.tury, {x:1,y:0,z:0});

  this.animate_wheels();
}
Title: Re: Tiger2
Post by: PytonPago on September 13, 2013, 11:53:23 am
As for the turret dependency for actual gear ... the BelAir has a script for multiple gears whyte rpm-based power. He has a script part saying witch gear witch force multiplier has. Maybe, if you try to change the script into your tank and make the turret rotation speed dependent on the actual gear (whyte their multiplications), it would give such result. Doe, one problem can be there - turret rotation is not dependent on the engine being started, so it would need to fix that little fact (may cause troubles).

Its a little pain in the ass re-scripting but i done it for my Urals, so it does work, you just have to tune the parameters afterwards to make it feel like a panzer ..

P.S.: In the script mentioned above - i added a sound for turning the turret in the name turret.ogg - have just used Murkz´s Luchs turret sound witch i put into the tiger 2 folder and renamed accordingly. You need to do it in order to use the turret. Otherwise OT will give up an error message freezing the vehicle.
Title: Re: Tiger2
Post by: M7 on September 13, 2013, 12:23:55 pm
Have to admit i stop playing with the tiger2 config a while ago. i Know i wanted to rework the texture property, reposition the turret on the hull (it is too much too the back) and add the manual gear from Giucam, but kind of lost interest.

I might get back to it sometimes. I did try your config, works well except turret might be too fast. Murks gave me the turret setting so i think he must know the speed of the real thing.
Title: Re: Tiger2
Post by: PytonPago on September 13, 2013, 12:42:17 pm
Understand.  :) Maybe if i get bored i try that thing i mentioned someday ...
Title: Re: Tiger2
Post by: M7 on December 02, 2013, 08:20:20 pm
I played a bit with the tiger2 texture and kind of accidently end up with this visual (i inverted the textures). Looks  all dusty as it would probably look like if it was deployed in North Africa.

(http://imageshack.us/a/img716/194/5y1j.jpg)

(http://imageshack.us/a/img7/3118/tau5.jpg)
Title: Re: Tiger2
Post by: ZeosPantera on December 02, 2013, 09:31:36 pm
A+ You best make that a Variant
Title: Re: Tiger2
Post by: M7 on December 02, 2013, 11:56:17 pm
...and with a camo... Yeah i think i'll make a couple of variant.

(http://imageshack.us/a/img856/9385/5a6e.jpg)
Title: Re: Tiger2
Post by: ZeosPantera on December 03, 2013, 12:58:13 am
You have to try one of those vintage tanks with the new digital camo!

Also M7 are you the one that posted the Tiger 1 back in the day? That is really my favorite tank.
Title: Re: Tiger2
Post by: M7 on December 03, 2013, 01:13:28 am
Not sure what you mean by those vintage tanks and the only Tiger 1 i've seen on Outerra is the one from Murkz.
Title: Re: Tiger2
Post by: ZeosPantera on December 03, 2013, 04:24:58 am
Vintage tank being something as old as the Tiger 2. Also yeah murkz. Where is he I want my T1!
Title: Re: Tiger2
Post by: PytonPago on December 03, 2013, 06:06:41 am
Nice texture work there, African one is pretty convincing  ... wish i had your skills.  ;) 
Title: Re: Tiger2
Post by: murkz on December 03, 2013, 06:16:01 am
Vintage tank being something as old as the Tiger 2. Also yeah murkz. Where is he I want my T1!

I am never far away from Outerra, the Tiger 1 is still on the todo list Zeos, as soon as I have the skills to import and get the tanks performing as close as possible to reality, the Tiger 1 will get imported.

It is a flagship tank and probably the most well known tank in the world and I would love to do it the justice it deserves.
Title: Re: Tiger2
Post by: M7 on December 03, 2013, 09:44:01 am
Well it doesn't takes much skill so far as i have'nt done the original texture which is an amazing one. All i had to do was to invert the textures and reajust the colors.

It is quite a challenge to do a texture from scratch. And you need  UV mapping which is pretty tough if not impossible to get/make from sketchup models.

But I am taking on to make a texture mapping from scratch for Murkz's Luchs using his model's UV, so we'll see how it comes out.
Title: Re: Tiger2
Post by: PytonPago on December 03, 2013, 01:04:24 pm
It is quite a challenge to do a texture from scratch. And you need  UV mapping which is pretty tough if not impossible to get/make from sketchup models.

Maybe importing to 3DSMax or Blender to do the UV´s ? ... there are some nice vids for learners on the net :

Blender Tutorial Series - Part 13 - UV Mapping (http://www.youtube.com/watch?v=e5_2seDBQrw#)
Title: Re: Tiger2
Post by: M7 on December 03, 2013, 02:17:26 pm
I have blender but never really played with it. Will check this out. Thanks!
Title: Re: Tiger2
Post by: M7 on December 08, 2013, 06:31:48 pm
As for the turret dependency for actual gear ... the BelAir has a script for multiple gears whyte rpm-based power. He has a script part saying witch gear witch force multiplier has. Maybe, if you try to change the script into your tank and make the turret rotation speed dependent on the actual gear (whyte their multiplications), it would give such result. Doe, one problem can be there - turret rotation is not dependent on the engine being started, so it would need to fix that little fact (may cause troubles).

Its a little pain in the ass re-scripting but i done it for my Urals, so it does work, you just have to tune the parameters afterwards to make it feel like a panzer ..

P.S.: In the script mentioned above - i added a sound for turning the turret in the name turret.ogg - have just used Murkz´s Luchs turret sound witch i put into the tiger 2 folder and renamed accordingly. You need to do it in order to use the turret. Otherwise OT will give up an error message freezing the vehicle.

Ok got myself to try to integrate the gear/transmission script  that Hrrrr and Giucam did last summer with the Tank script that Cameni did for Murkz tank's. I actually choose Hrrrr's version but i could have worked with Giucam as well. So the goal was to integrate the V12 sound set from sonory. I actually edit Hrrrr  sound test car to use the V12 instead of the V8 and it sound great as long as the engine stay within 0 and 3000rpm.

Not knowing much about java script, i thought i wouldn't go very far at trying to merge the tiger2 script with Hrrrr's sound test. It actually went better than expected, the tank move  8), it could turn if i give a major boost on the engine but then the engine turns at 10000 RPM. There's a whole lot of stuff that dont work as it should (like the turret doesn't turn) but if anybody think they have the knowlege to tweak the script,  you could install that buggy version of the Tiger2 and see what you can do. Probably you will have to backup the original version cause it will probably overwrite it.

https://drive.google.com/file/d/0B96RrTcNJsI2M21seXNvenlGTE0/edit?usp=sharing

...and then we could try to make the  turret turn at varying  speed depending on the engine rpm ;)
Title: Re: Tiger2
Post by: M7 on December 08, 2013, 06:35:41 pm
Oh and it sound terrible. Acceleration sounds are too loud and decelaration sounds too weak, couldn't find what to tweak in the script.
Title: Re: Tiger2
Post by: PytonPago on December 09, 2013, 03:22:52 am
For the turret turning, maybe its a problem i had whyte my grad ...

http://forum.outerra.com/index.php?topic=1671.50 (http://forum.outerra.com/index.php?topic=1671.50)

See the debate i had whyte cameni about the switch function - you can look too at the posted grad model script to speculate a little whyte it. I did a lot of cornering myself in scripting as i lost quite often the sight of dependencies and function redefinitions along it. Have to say that im glad to see the Tiger going on after a while ...