============================================================================================
 				       Von Croy and His AI
	!!THIS PROJECT IS A COPY OF VIVI's and i asked him on msn and he said PLEASE UPDATE!!
============================================================================================

Setup...

LOOK IN THE PROJECT FOR MORE PERSPECTIVE!
This exe is TREP compatible.
and the normal exe might work

SOURCE FOLDER CONTAINS SCRIPTS TREP CODES AND TUT1 TARGA FILE
						AND THE PROJECT
					USE ANGKOR.WAD but add objects
					from the SOURCE\\WAD folder

Because this is only a prj showing you what to do, all you have to do to set it up is move it to the angkor>maps directory, and then open it in the editor. When you output it, output the Angkor file, not the tut1 file as used in the textures. I have not modified any of the textures, sounds, or wads so you can use your existing ones.

Introduction...

Hello! Sorry its been a while since i updated! but Jack Powell has taken over updating Voncroy
Ive left the old manual with QUOTE or ANSWER under some parts hope it helps!

The Basics...

Firstly I will go over the basics of the AI system, used for all of the 
enemies. In order to bring life to, and get Von Croy 
to move about levels, the AI_FOLLOW nullmeshes are used. These direct 
Von Croy or whoever may be following these nullmeshes. 
I will only be concentrating on the AI_FOLLOW, as it is the only one I 
have used, and see the point in using with Von Croy. 
This is also the only one in the manual that is not very well 
explained, and has led to many headaches over how to use it. 

Level design here is important!! You don't want Von Croy to go over his 
own steps if you can help it, or if he does he must 
do it in a logical order. Usually you want Lara to trigger the 
flipeffect just in front of, or the square Von Croy is on 
(more about this in a minute). Because flipeffects are 'special 
triggers', you cannot overlap them - so you can't place more 
than one on the same square. Also if say you wanted Von Croy to run 
around a room, then from the point he started jump to 
the middle of the room, Lara could run in the opposite direction to Von 
Croy, and Trigger a later flipeffect for a AI_FOLLOW 
later in the room...triggering Von Croy too soon. So it is a good idea 
to think about the design of your level before placing 
him and his AI. Like in the Tomb of Seth, the guide starts at one end, 
and finishes at another - only at the end when he 
disappears does he go over his own steps. This is also true to the AI 
for Von Croy in Angkor Wat (well what the little part 
of the AI the actually works in it), but even if you look through the 
rest of the level in the editor or in TR4, he still doesn't.


Now to the AI...

The first AI_FOLLOW nullmesh has to be placed on the same square as Von 
Croy. This tells Von Croy that he will be following 
the AI. If you open the OCB window (by pressing 'O',) the default 
number in this box is 0, and for this first nullmesh must 
be that. Then a second nullmesh is needed to tell Von Croy where to go 
next. This also needs to have the OCB number of 0. 
These are the only two nullmeshes that should have a duplicated number, 
if any other two do, it will cause problems for Von 
Croy. This will need to be changed for each AI_FOLLOW nullmesh placed 
on the level, with, of course, exception of the first 
two.


Now you will have Von Croy running from A to B, so what about C?

Here is when it starts to become a bit trickier, and my main problems 
started. The next AI_FOLLOW has to be placed in the 
next point you wish him to go, the only limit here is the illegal 
slopes, but anywhere else is fine. Bring up the OCB, and 
type in the box the number '1' and make sure you press enter! Not doing 
so will not save the number you have just typed. 
This tells Von Croy that this is the next place to run to is from 0 to 0 and then to 1. Simple. (Note: It is always a good idea to check to 
OCB of any new nullmeshes you may place. I have many times forgotten to 
push enter before okaying it, and it then not working 
when I go to play it in the game.) Now you can either make Von Croy 
wait between this new point and the old one, or just let 
him run to it without stopping. If you want him to stop you will need to 
place a flipeffect trigger. These with Lara are what determine where 
Von Croy stops, and where he begins to walk again. To 
place a flipeffect click on the trigger text box (the box with writing 
beside the pink trigger button) and in the top left 
hand corner select 'flipeffect' from the list. The number 30 is needed in 
the box in the top right hand corner next to the 
word flipeffect (this just says which flipeffect you are doing). The 
type you will probably want to leave as trigger. This 
can be changed to any other type, but the flipeffect trigger could be 
missed, which you don't want Lara to be able to do -- if she does Von Croy won't follow/lead like he is supposed to. Now the bottom box is the one that they don't explain in the 
manual...the timer. This is not actually used as a timer, but 
actually to tell Von Croy what AI point he is running to next. So in 
the example above you will want the number '1' to 
indicate that the point he will run to when triggered is AI point 1. 
then okay the box, and select the square(s) that you 
wish it to be triggered on (and as with the trigger type, you don't want 
Lara to miss it, so place it in a place(s) that she 
can't). Also you can set the actual point Von Croy is running from as 
the flipeffect, this means Lara will have to be on 
the same square as Von Croy to trigger it (See filpeffect 5/AI point 4 in the prj file). To make Von Croy run through more than one AI point (ie you have AI points 1 through 10 you could make Von Croy run from point one to point 10 without waiting for Lara.) Simply place a flipeffect with the timer set as 10...you don't need 1 to 9, and this will make Von Croy run to point 10. Also You can have a mixture of long runs and waits by (in the example above) place a flipeffect with the number 5 in the timer, and then Von Croy would wait at point 5. At this point another flipeffect could be placed to make Von Croy then run on to 10. If you don't quite understand what I have said in the above, refer to the prj file, and press O to bring up the OBC on any of my AI points.

To add more follow AI points in, place another nullmesh where you want 
to be the next stop, and remember to set the OCB 
number one higher than the last AI point, this is the same with the 
flipeffects...that is if you want Von Croy to wait at 
every point...

The OCB Buttons...

I have used every combination of buttons (I think), to see what they all 
do. If you wish to use any of these, you must press 
the OCB buttons down on the AI_Follow point(s) (this is also where he 
will carry out the action, and will carry it out 
before waiting to move to the next point if you have set him to do 
that, (ie OCB 2 is the short platform action, when he reaches the AI point with this OCB, he will carry out this action -then- wait to go to the next AI point (see room 6 in the prj file (and also read the tips section near the end of the guide) for an example of where you have to place more than one AI point because of this))) rather than on Von Croy himself (because of this there are no OCB that can be put with the buttons to change what they do, as the number defines what AI point it is). Below the list of all the combinations, and what they all do:

1: This causes Von Croy to get into the 'shimmy' position. The only 
trouble with this (as with the Angkor Wat PRJ files) 
when he does this, he does little else; I can't get him to shimmy 
across left of right, and even when I have changed the 
positions of the AI Nullmeshes for the next point for him to get to. If 
anyone can figure out how to make him shimmy along 
and pull himself up please mail me back 
(viviornitier_theblackmage@hotmail.com) and tell me so that I can edit 
this, and 
re-post it.

Note: Von Croy jumps to the height of 6 clicks; so don't make your shimmy gaps higher than that! Also the AI nullmesh directs Von 
Croy as to which way to jump. You want the point of this nullmesh to 
point away from the wall you wish him to climb.

2: Makes Von Croy use the 'Jump down from a short platform' action, 
This can be used on a ledge to make Von Croy jump from 
higher than he normally would with just the follow AI nullmesh (usually 
he will only climb up or down four clicks just 
following one AI_FOLLOW nullmesh to another); it can be placed on a 
high block (e.g. One that is 8 clicks high,) and Von 
Croy will jump off the side. This nullmesh point must be placed in the 
opposite direction of which you wish him to jump 
(i.e. If you want him to jump right, place the nullmesh pointing left).

(See 'Tips' below for more info)


3: Von Croy feels around on the wall (as he does in the first part of 
Angkor Wat,) this is used with heavy trigger placed 
under the AI_FOLLOW nullmesh to open a door, or trigger a trap (or 
anything else you may wish to trigger). The nullmesh point 
has to be facing away from the wall you wish to make Von Croy touch.

(See 'Tips' below for more info)

4: Makes Von Croy stop; he won't obey any further flipeffects, and 
stands still.

5: This stops voncroy from waving his hand and so he dont wait for lara
    Also he will attack any WILD_BOAR object in the next room

1+2: Von Croy uses his attacking action; like when he is killing a boar 
(including the blood) - Not much use (?)

1+3: Von Croy looks at the ground until the next flipeffect is 
triggered. I have not been able to use this with a heavy 
trigger (so that when he looks it triggers something).

1+4: See 4

1+5: This makes Von Croy hold his dagger out in front of him, but doing 
this also stops his breathing animations, and he is 
not able to move to any other point, even when another flipeffect is 
triggered.

2+3: See 5

2+4: See 4

2+5: Von Croy looks at his hand, as if he is reading something. He 
repeats this until the next flipeffect is triggered.

Thank playerjck530 for this descovery:
And flipeffect45 timer 1 causes a meshswap to meshswap1 change (a book)

3+4: See 4

3+5: Causes Von Croy to do a long running jump. This needs to be set up 
so that the AI nullmesh is in the middle of 3 
squares; the nullmesh in the middle, a run up platform behind, and a 
launch pad in front. The square Von Croy is jumping to 
needs to be a 3 square gap, and has also got to be at the same height 
as the pad he is jumping from. Without these things, 
he will not jump right, and then will just run about the rest of the 
level strangely.

4+5: See 4

1+2+3: See 4

1+2+4: See 4

1+2+5: See 4

1+3+4: See 4

1+3+5: See 4

1+4+5: See 4

2+3+4: See 4

2+3+5: See 4

2+4+5: See 4

3+4+5: See 4

1+2+3+4: See 4

1+2+3+5: See 4

1+2+4+5: See 4

1+3+4+5: See 4

2+3+4+5: See 4

1+2+3+4+5: See 4

As you can see a lot of the combinations don't actually do anything, 
but mess up the AI of von Croy. 
(If you can think of any combinations that I have missed please mail me 
and say; at the above address (also at the end of 
this guide).


More moves and his limits? (All room numbers written in brackets are where examples can be found in the prj)


The Monkey Swing (Room 1)

The monkey swing is another of Von Croy's good animations, although he 
won't do it on his own - he won't just start monkey 
swinging from point A to B if the AI points aren't set as below, even 
if it is the most direct and quickest route between 
two AI_FOLLOW nullmeshes. To set up the monkey swing, the ceiling must 
be 6 clicks higher than the ground that Von Croy is 
standing on. At the beginning of the monkey swing must be an AI point 
and another one must be placed at the other end. No 
OCB buttons or code is needed to make Von Croy jump to the monkey bars 
above (as long as they are actually monkey bars,) 
because of where the AI has been placed.


Climbing (Room 1 (1 Click Step), 3 (4 Clicks), 6 (1 Click Slope)

The maximum height for a block that Von Croy can climb is 4 clicks 
high. He can also pull himself up onto blocks 3 clicks 
high and 2 clicks, and he can walk up 1 click.


Jumping (Room 1)

Von Croy can easily jump a gap of one square where the starting height 
and the ending height of the blocks are the same. He will do this jump running from point A to B , even where they are not either sides of the jump. Von Croy is able to do a three-square jump, but I would recommend using the OCB for it (as shown above) because without it sometimes messes up.

Note: Von Croy will always take the quickest, or safest route. If there 
are two blocks each 4 clicks high two squares away 
from each other Von Croy will always jump down...walk along the floor, 
and then climb up the second block, rather than 
jumping them.

The 2 Square jump is not as simple, as there is no set way of making him do it. If there are two AI points either side of the jump Von Croy will -not- just jump the gap and wait where he is supposed to. Instead he will get to the AI point before the jump, and then follow Lara around...the strange thing about this is as soon as Lara has jumped it Von Croy will too, and return to normal. I don't know if this effects anything later on in the level, like OCB codes and the AI points. Strange.


Heavy Triggering (Rooms 1, 3 and 4)

Always place heavy triggers under AI nullmeshes rather than somewhere 
you think he may pass over, as this can change, and 
also have a tendency not to work.


Switching

I have not had much luck with this, and I know a lot of people really 
want to know if he can. Does Von croy actually ever 
switch a lever_switch in the game? Cos' I don't ever remember seeing 
him, but I could be wrong. However I am still working 
at trying to get Von Croy to flip one...after all there has gotta be a 
purpose to the heavyswitch trigger...? Anyone? - Manual "HEAVY SWITCH - A switch designated to be activated by someone/thing other than Lara." -- but there are only 3 types of 'switch' though isn't there? The lever switch (which I have tried loads of things on to try and get him to switch (this is also the only one used in the same wad file as Von Croy...so I don't think it would be one of the others...(but I haven't used TRWest to make a new wad to try it), the Jump Switch (from the cleopal wad or the city wad) and the Furniture 0 (from The tomb Of Seth wad)...anyways like I said Im still working at it. Only that little bit of testing left to do.

ANSWER: Cant be done!

Didn't he just...?! (Room 3)

Yerp. I just said you can't get Von Croy to flip a switch...but in the 
PRJ file I gave you he does?! To the player, it will 
always look like Von Croy has actually flipped the switch, but if you 
look carefully, do you actually ever see him flip it?! 
Notice how he is always out of sight; door shuts on the way in...opens 
when he has finished...but all the time he is in 
there you never can see him. This is something I thought about only a 
little while ago. The switch is always the wrong way, 
as Von Croy goes around the corner with the switch, a heavy switch is 
flipped, and so it appears he has flipped it. Because 
the switch is against the wall, Lara can never switch it back to see 
that actually it never does anything. Something you 
might want to add it, as it has fooled everyone I have tested it on...

QUOTE: If you want to trigger a switch use an animating i made one but voncroy wont do any animations
 	and its a wast of time realy :( too bad its not possible,

Starting (Room 1)

Not really a limit, or a move, but I have put it here anyway. The 
direction Von Croy first runs when triggered is set by the 
point of the AI_FOLLOW nullmesh on the square of Von Croy. Also, unlike 
the guide (from the Tomb of Seth), Von Croy will not 
move to his first AI point until he is told to...meaning you have to 
set at least one flipeffect, however few AI points you have.

The great TT (Rooms 2 and 6)

Again another thing that isn't really a limit, or a move...the trigger triggerer. This is very useful as you can actually use it to trigger Filpeffects. This also solves the problem I said earlier on in the guide...about Lara running into a Flipeffect too soon. It's also very useful to use on lever switches...because when triggering a door and a flippeffect...the timer number in the flipeffect acts as a timer to the door. Which can mess up what you wanted the switch to do. 

Bugs!

Erk...okay there are a couple...

The first is actually in the design of the level, and is when Von Croy get's locked in, and opens two doors. If you trigger the flipeffect just in the doorway...and then run out, when Von Croy gets there, and you go back to the spot where the flipeffect trigger is, he won't open the door...see below for why he does this.

The second is something within my level, I think, and that is that when you die, re-load, exit to title or finish the level, it will fall out to windows. I have tried taking everything out of my level...one by one...and I can't seem to fix it. In the end I have put it down to the fact I was using the Tut1 wad and textures, and then I loaded the Angkor ones (I was gonna make it in the test room ... because there is no texturing to do, but in the end I made it without using it anyway). I know it shouldn't do it, but it does...and if someone knows how please tell me!

QUOTE: "Jack Powell fixed the second bug with his new EXE"

Tips And My Thoughts

Okay this section is just for a couple of things that I have found out about VC and the AI.

The first of these is the number 3 OCB button. In order for Von Croy to do it, Lara must be standing beside him. In room 1 of the prj, there is a gate which Von Croy must open in order to move to the next stage of the level. (This has been placed to slow Lara down, because some parts (ie jumping) Lara can do quikcer than Von Croy, and she was able to move to the next part (the monkey bars) and flip the switch which opens the door for Von Croy and get in there before Von Croy could reach the other side...showing that he hadn't flipped the switch.) Von Croy will not use the 'fiddle on the wall' action until Lara is standing beside him (for some reason (I don't know why) even if you beat Von Croy to the door trigger it amd run off (which should stop him from doing the action because you are not standing there) when you go back, and he is there, he will do the action again -- unlike the second time he has to open one, where if you hit the trigger and run off, and then back again when he is there, it won't trigger twice, and will stop Lara and Von Croy from moving on to the next stage in the level.

The second thing is flipeffect 45. This flipeffect was dicovered by Jack Powell and probily Titak as it is used in Coyote Creek, it is complex and can only be used so many times (once per trigger X timer) comfusing realy look at the project but you must make sure lara dont miss it and YOU CANT USE ANY OTHER TIMER ARGUMENTS OTHER THAN WHAT JACK USED!
Anything else causes other bugs ....... Due to the fact that lara had to pickup 8 golden skulls to finish differntly.


Mail Me!

I think I have covered everything you will need to know about Von Croy 
in this guide, and I hope it is of at least some help 
to those of you who are reading it. If there is anything further you 
wish to ask about, something I have written that is 
wrong or a little too confusing, or just that little something I have 
not covered please mail me to say, and I will update 
this guide, and mention you. Also mail me if you are having 
difficultly, or a problem with something, and I will try to be 
of some use to you as whilst writing this I have experienced so many 
problems, and had to change things all because of Von 
Croy and his AI. 

Even if you think this is good or bad, could you please mail me back 
and give me your comments about it.

Vivi Ornitier is not interested he said in msn
but talk to Jack Powell insted :)
I taken over the von croy development!
 (Viviornitier_theblackmage@hotmail.com)
 (trle_jack@hotmail.com)
 (jacks.mini.net@gmail.com)

