Junkers Ju-52/3m

...an AA artifact.

Hello Ivan again,
I´ve tracked down the origin of this mysterious and meaningless Jump
instruction: It was not generated by AF99 at all! It isn´t in the
un-animated code. It´s an Aircraft Animator "artifact"!

After your comments on machine generated code, or "spaghetti code",
(I love to write spaghetti code in QBasic...), this Jump would fall into a
category where the compiler (AF99) did indeed know what it was doing,
but we KNOW that the AA compiler is clearly wrong. Am I right? :devilish:

In consequence, as the plane works perfectly, the meaningless Jump lines
could probably best be deleted. For the moment, I just marked them out with ";".

It´s an interesting artifact though...:adoration:, and the question still remains:
Why did AA do this? The strange lines are not in the code of the other two
models.

Maybe it´s because of some AF99 quirk in this particular model that triggered
the artifact in AA...


Cheers,
Aleatorylamp
 
Of ailerons and guns

Hello Smilo, Hello Ivan,
I had an extra problem through my own fault. The aileron
animation went in the opposite direction, and it was happening
on all three models, but I discovered how to correct it with SCASM,
so now all´s well again after four and a half hours.
:banghead: That´s what
happens if one doesn´t pay attention! I suppose completely re-SCASMing
the three models would have taken even longer.
:dizzy:

A thought about CFS1 guns: :tommygun2:
I was thinking...I doubt whether the armed version of the Ju-52
will be of any
use to anyone in CFS1 without swivelling guns, so
what´s the point? That´s why Smilo is really only interested in
unarmed transport / paratrooper versions.

With one trainable dorsal MG and one trainable frontal 20 mm
Cannon, one would
at least stand a chance... I think Hubbabubba
mentioned once that there was a
CFS1 Plug-in that could do that,
but it only works under Windows 98.


Cheers,
Aleatorylamp
 
Last edited:
actually, the main reason,
"Smilo is really only interested in unarmed transport / paratrooper versions"
is because he was not aware of the the armed versions.
i only knew about the ju52 used as cargo transports,
paratroop carriers and, especially,
the shiny version used to carry the fuhrer.

yes, you are correct, there is a cfs addon
enabling the firing back from bombers...lots o fun.
it's called Tailgunner or, TG2.
using it properly is an acquired skill
and i must say, hubbabubba was deadly.
you can find it on the FreeFlightSite utilities page.
scroll down to Tailgunner;
http://www.thefreeflightsite.com/Utilities.htm

i may be mistaken, but, as i recall,
there might be some DP file modifications required.
if you're interested, maybe i can help.
 
Hello Smilo,
I see. Thanks for your clarification!
If TG2 works with Windows XP, I´d be really interested.
I´ll get it and see if it installs. If it works on Win XP, it
would be great to have on the Ju-52.

On the model, I could even try to add two lateral firing guns
from the back
windows. Now THAT would be a great thing
for the Ju-52!
They say the 4 guns were good to protect
the paratroopers
before they had to jump.

Also, the night-flier camo-colours are coming along quite well,
even if slowly (almost line by line), so it would probably be a
pity not to make an upload with them.

Anyway - have you thought about whether you´d also like
paratroopers´silhouettes on the Spanish version?

On the armed version, as it´s going to be a transport and a bomber,
I suppose those silhouettes will not apply.

OK, then! More, later.

Update: OK! I got it and installed OK on Win XP, but I
can´t see any extra
TG2 options to try and test it in
Quick Combat or Freeflight Mode.

I suppose I´ll have to do something in Multiplayer to try
it out, but
I´ve never ever done anything there.

Cheers,
Aleatorylamp
 
yes...tg2 works with xp, so, give it a go.

as for the Spanish version with silhouettes.
i would say, they are so subtle,
no one would be the wiser if they were there.
if that makes any sense.

hey, why not put this guy in one? :a1310:
just kidding, sorry.
 
Hello Smilo,
...or this one: :kilroy:

OK for silhouettes on the Spanish version then!

Do you think the Silhouettes are OK as they are, or
maybe they are too subtle and would be better more
pronounced - i.e. a little darker?

About TG2: I understand that to test it,
the only way would be in Multiplayer Mode?

Cheers,
Aleatorylamp
 
actually, no. you can go into quick combat
and let them come after you.
aim with your mouse...be sure to lead the target.
you will know it's working
if the tracers follow your mouse movements.

please, pardon the shameless self promotion,
but, do you have my ar196?
if so, check it out after you've installed tg2.
i know it works with tg2.
btw, it also has a copy of tg2 in the package.

good luck, please, let me know how it goes.
 
Hello Smilo,
OK, thanks! I wasn´t aiming with my mouse...
So, it should shoot at the opponent with everything I´ve got!

Update: OK! I shot down my first opponent! It works! It´s much more logical.
Now, it will take some thinking as to how to get the side and rear views
from the cockpit to get the guys by shooting sideways and backwards.

OF COURSE I have your Arado. Fine, I´ll check it out too!
Maybe that will answer my question in the updated paragraph.

More, tomorrow then... I´m off to sleep now. Good night!
Have a nice afternoon and evening!
Cheers,
Aleatorylamp
 
that's great...glad it works for you.

now, we get to test my memory.
as i recall, when you pull the trigger,
ALL guns fire, but, the only guns aimed
will be those in the selected view.
for example, in rear view,
only aft facing guns are aimed.
right side view, only right side guns are aimed,
and so on and so forth.
i hope this makes sense.
 
Hello Smilo,
OK! Thanks again!
The problem at the moment is that the rear gun is still firing
forwards. I have to check how I got it to fire backwards and/or
sideways on the 1917 Staakens and Gothas. There is the swivel
option in Dp that I must figure out better.


Is that the reason for the enemy dot in the box on the upper left
sometimes being red and sometimes being yellow?
(I only have one enemy defined for now).

I was also reading your Arado texts (they are much nicer to people
than mine!), and I will try the hud-view.

Interesting, this TG2 business! I hadn´t tried it out before because
of
misleading comments on a few sites about TG2 being incompatible
with all OS later than Win98.

New toys are always nice!
Cheers,
Aleatorylamp
 
i've never heard of tg2 os incompatibility issues.
although, it's possible with the early releases.
back in the multi-player days, i ran multiple machines
with different operating systems and had no tg2 problems.
that's as far as i'll go with it, just personal experience.

in quick combat, choose two or more enemies.
as i recall, you can cycle through targets,
but, i can't remember the keystrokes to do it.
yellow dots are aircraft within tactical display range.
notice the red dot in the tactical display
will change to the selected target.
also, when track target is selected or locked,
your vc view follows that target.

thank goodness for auto pilot.
 
AF99 & AA Limitations

Hello Aleatorylamp, Smilo,

From my own experience, generally with a Parts count below about 1175 of 1200, things are pretty reliable.
Past that, AF99's chances of barfing are increased. Sometimes you can cram in more Parts, sometimes you can't.
It isn't entirely predictable though the complexity of pieces of the model seem to have an influence.

Many times, there is a weirdness in the model that may not be visible in all views as was seen in my FW 190A.
The exterior view looked fine but I seem to remember a polygon extending to infinity from an internal view.

With your quoted percentages of Parts used, I believe you are operating way too close to the limit of reliability for AF99,
but as I mentioned before, it varies from project to project.

AF99 also has its broken stuff such as Templates as shown in my P-38 Lightning Projects.

Aircraft Animator seems to have even more broken stuff. I have never gotten some of the angles to work correctly.
The animation of deployed Flaps is never retained and must be redone every time.
The Propeller Arcs will accept 0.01 meter specifications but will only retain accuracy to 0.1 meter.

There is probably more that I do not see.
One of these days, I should probably check out what a "polygon extending to infinity" actually looks like in SCASM.

MS VC - Microsoft Visual C / C++ is just the compiler I am using for building Gauges.
The problem is that mouse functions do not work even with the SDK sample gauges when I used my MS VC compiler so I need to figure out why that is the case.
This is the big hold up with building more interesting gauges such as an Autopilot and some custom Engine Controls and Fuel Selectors. Even Mouse-Over stuff does not work.
If I can get the mouse functions to work in compiled Gauges, then there are a lot more possibilities instead of just indicator gauges.

- Ivan.
 
Hello Smilo,
Thanks for your additional tips!
TG2 seems to be doing fine, and I´m working on the Dp gun options to maximize
effectiveness.
Incidentally, DP Editor won´t work on the Virtualized Windows XP I have on the
Win 8.1 laptop, but no matter, because I don´t often use it, except today that it´s
a bit cold at the tower under the stairs!!

You´re right about the autopilot. I did notice that flying, aiming and firing is a bit much.
Progress with the lettering and the camo on the e4g armed version is slow but sure...

Hello Ivan,
Thank you for your counsel. I wasn´t clear about the benefits of leaving a 3% safety margin.

Question: Are there any specific things to look for on finished models to be sure that there no are hidden

flaws due to extreme compilation too close to the limit?

One strange thing that did happen on the version with the strange Jump, was that one of the times I saved the
AF99 model, it was empty and gave an error message when I wanted to load it load it again, and I had to rename
the file and then it reloaded. Apart from the strange jump in the SCASM listing there was also a section of 17 return
instructions piled up near the end, that I deleted, of course. Wierd stuff, but the model seems to be OK.

For the moment, the models are operating fine. Maybe I should attach the three models for a check?

Good luck with the mouse and the C/C++ compiler! The projected gauges sound very good!

Cheers,
Aleatorylamp.
 
What Glue looks like in SCASM

Hello Ivan, hello Smilo,
I thought it was interesting to illustrate how SCASM implements Glue.

Just using a rear fuselage section with 2 lateral firing machine guns
glued to each side (poking out of side windows, as it were), uses
the following AF99 sequence:

- Fuselage Structure
- Right Glue template
- Right MG Structure
- Left Glue template
- Left MG Structure

With this, we obtain the SCASM-generated code displayed below.

The two glue templates cause 2 successive conditional sentences to
be generated, involving the display order of the 3 elements involved.
I have simplified the actual display of the three elements into one line instead of printing out
the complete code of all the vectorpoints and shaded polygons involved.

Incidentally, the code is reminiscent of what has to be written by hand in Ad2K!

;*** Start of Main Aircraft Code ***

;Calls aft fuselage and lateral guns.
;-----------------------------------
:L00140E
Call( :L001414 )
Return

;Depending on view point, decides whether to call left gun
;or not, and do so before or after calling aft fuselage.
;-----------------------------------------------------------
:L001414
VectorJump( :L00142C m -32767 0 0 415.000000 )
Call( :L001436 ) ;
Call( :L001572 ) ; calls left gun
Return
:L00142C
Call( :L001572 ) ; calls left gun
Call( :L001436 ) ;
Return

;Depending on point of view, decides whether
;to call aft fuselage before or after right gun.
;----------------------------------------------
:L001436
VectorJump( :L00144E m 32767 0 0 415.000000 )
Call( :L00168C ) ; calls aft fuselage
Call( :L001458 ) ; calls right gun
Return
:L00144E
Call( :L001458 ) ; calls right gun
Call( :L00168C ) ; calls aft fuselage
Return

; Right side gun code
; -------------------
:L001458
VecPoints (8) + Shaded Color + ShadedPoly´s + Dummyjump + Return

; Left side gun code
; ------------------
:L001572
VecPoints (8) + Shaded Color + ShadedPoly´s + Dummyjump + Return

; Aft Fuselage Code
; ------------------
:L00168C
VecPoints (15) + Shaded Color + ShadedPoly´s + Dummyjump + Return

:L00196A
EndA
;;;End of Latitude Range

I thought it was interesting to show how SCASM does it! These would be the steps to
include 2 lateral machine-guns into the e4g armed transport/bomber version of the JU52.

The next step would be to enable the extra machine-guns to fire at + or - 90 degrees in
the Dp Editor. The rear gunner already exists, with his - or + 180 degree definition in the
swivel guns, if I am not mistaken. It is a bit difficult to see if it works properly only using
the Quick combat mode, but in theory it should be correct.

This version of the real Ju-52/3m had an improved bomb-sight, that did away with the need
for the cumbersome ventral "stew-pot" bomb aimer´s position, and the model had a provision
for carrying 1100 lb of bombs which was used for "specific purposes.".

Update: The only problem of putting in the two lateral guns on the model, is that the units recovered from the Norwegian lake, which is the ones that this model takes after, is that they didn´t have any lateral guns, although there was provision on the model. But then, those units at that moment, weren´t bombers either, but transports, but had provision to be such though!
So it´s reminiscent of Hamlet´s dilema... to put or not to put (the guns in), that is the question.

Cheers,
Aleatorylamp
 
Last edited:
Hello Aleatorylamp,

I am glad you are noticing that the AF99 Glue code generation is very reminiscent of AD2000.
It SHOULD be because it is doing pretty much the same thing..... to an extent.

AD2000 and SCASM are powerful enough to allow you to specify the EXACT sequence you want.
AF99 because of the linear arrangement of its Assembly sequence is a pretty serious limitation.

The parameters for the VectorJump call are what I have been working on recently....
The problem I am still having is in determining which direction the normal to the viewing plane should face.
It isn't a hard problem but there are other things going on that I need to work on also.

By the way, your understanding about how VectorJumps work in place of Glue is correct for within a Group.
It is not correct in terms of how the Groups are combined into the complete Assembly.
You are describing how it SHOULD work and not how it really works.
Try putting just one piece into each Group and recompile. The results may shock you.

So far I am having no success with mouse effects on gauges.
This is not a surprise because I really have no idea what I am looking for.

My Ki 61-Id flight model is in the process of yet another minor update.
The AF99 model could also use an update but still need a reliable machine.
We shall see how it goes.

- Ivan.
 
Now only one part glued

Hello Ivan,
Thank you for commenting!
As you say, the trial applied to a simple group of elements, a
central element having 2 others glued to it, 1 left and 1 right.

It was a bit difficult to explain in the short commented lines,
and I didn´t mention that the display of one gun cancels out
the display of the other, but the fuselage is always displayed.


I realize it illustrates AF99´s limited sequencing capacity - i.e.
a single left/right gluing branch-out from a central element, and
that with SCASM it is possible to have additional branchouts after
each branch.

I suppose that the way to write such a sequence would be to include
further VectorJump routines within an existing VectorJump routines.

Your suggested trial for only one gun glued, in this case to the right
side, has a much simpler sequence with only one condition,
i.e. a single
VectorJump routine. Here, depending on the viewing
point, either the
fuselage or the gun is displayed first.


;*** Start of Main Aircraft Code ***

:L00140E
Call( :L001414 )
Return

Depending on the point of view decides whether
to call the machine-gun or the aft fuselage first.
------------------------------------------------
:L001414
VectorJump( :L00142C m 32767 0 0 415.000000 )

Call( :L001550 )
Call( :L001436 )
Return
:L00142C
Call( :L001436 )
Call( :L001550 )
Return

Machine gun code
----------------
:L001436
VecPoints(8) + ShadedColor+ Shadedpoly´s + Return

Aft Fuselage code
-----------------
:L001550
VecPoints(15) + ShadedColor+ Textured poly´s + Return

:L00182E
EndA
;;;End of Latitude Range

Note: If the gun were to be glued to the left side, there would be
a
minus signin front of the first of the VectorJump parameters:
VectorJump( :L00142C m -32767 0 0 415.000000 ).

An interesting exercise!
It is easier to understand in small chunks, so this would be Step 1
of a possible tutorial, and the previous post would have been Step 2!

Further good luck with your mousable gauge manufacture!
Cheers,
Aleatorylamp
 
Last edited:
Strange AA Artifact eliminated.

Hello Ivan, Hello Smilo,
I managed to clean up the AF99 build of the armed version that had
the strange "artifact", to re-build the SCASMed version without it.

There was a redundant, badly placed glue-glitch left over from a building
change, and as soon it was gone, the resulting AA-caused "artifact" in the
SCASM code was also gone. The model looked clean enough before, but
now I KNOW it´s cleaner!

For the moment, for the sake of accuracy, I´ll leave this night-camo, armed
model just with dorsal machine-gun and frontal cannon, corresponding to
the ones recovered from the Norwegian lake. Also, it will be a transport, like
the ones that were transporting some cannons and supplies to the Norwegian lake
where the Germans were putting up a base, but they
were attacked by suprise
when they landed on the ice-covered lake. Later, when the ice
thawed, the planes
sank.


Then, in order to have a sideways-firing model, I´ll make a separate "gunship"
version, this time with the 830 Hp engines. There´s a photo of one, also in
camo-colouring, which I´m trying to decypher the registration number for.
This model will then be the bomber with 1100 lb bombs.

Cheers,
Aleatorylamp
 
4 guns on Auntie Ju.

Hello Folks,
I managed to put in the two lateral firing guns I wanted for a Ju52/3m e7g "Gunship", as it were.

The two structures go on the fuselage sides between wing trailing edges and tailplane,
but gluing them to the aft-fuselage sides was not a good idea, although SCASM accepted it,
because there were bleeds with the inner-wing and flap when seen from the top.

So, I grouped them in Inner Wing left/right with a glue template between them and the flaps,
which in turn were at the end of a glue sequence with inner-wing and wing-root.

This worked fine, and SCASMed well too. The model looks clean and works well.

However, despite working with a 145.6% parts count (1165 parts) AF99 model, 10 parts
below the "recommended safety margin", there was once again an AA "Artifact", a strange,
two-step Jump, right into the middle of the left wing again, but this time without there being any
reason for it in the AF99 listing. Needless to say, I just scrubbed it, and everything works fine!

Now I´m trying to get Dp Editor to do its job for the side-guns, and I have to see about what
registration number to put on, and perhaps I´ll do beige-green camo textures for it.


Cheers,
Aleatorylamp
 
Hello Aleatorylamp,

As I was saying earlier:
The actual Parts limitation before a project starts to misbehave is not very predictable.
I find with my own projects and building style that 1175 of 1200 Parts generally doesn't cause problems
but sometimes the limit is higher and sometimes it is lower.
Or perhaps the problems are already created and just not apparent yet.

- Ivan.
 
Hello Ivan,
Yes, I agree - that seems to be the case.
This time I haven´t been able to track down a visible cause,
but there are no "damaging" effects on the model, so at least
the model can be used.

As regards how glue sequences are handled, I also understand
that one thing is where an element actually appears in the SCASM
listing, and quite another is how often and where it is called from.

This only possible to understand by tracking the Calls for a given
part, and compare the pattern to how others are called.

Just after the *** Start of Main Aircraft Code *** there is a large
chunk of code over 1000 lines long, that just does Vectorjumps,
Jumps and Calls, before actually drawing anything, and to try to get
a general picture of what is going on is of course impossible without
detailed analysis.

When you think that the way in which this kind of automatically
generated "Z"
Buffer actually works was created by someone,
even if it is not as
perfect as the modern "Z" Buffers contained in
later simulators, it is
still quite an amazing feat. Those guys really had
an extremely high
3D visualization capacity!

Anyway, right now I´m following the built-in Dp Editor instruction lines
to make the lateral guns fire sideways and the rear one backwards,
(with TG2 installed), but it is difficult to see the results, because
apparently they can only do it when there is actually an enemy to
fire at.

Now I´ve got 4 different models together - let´s see if I can get a few
into the dispatch department. The unarmed ones will be quicker to finish
as there are no guns to fire!

Cheers,
Aleatorylamp
 
Back
Top