www.tombraiderforums.com

www.tombraiderforums.com (https://www.tombraiderforums.com/index.php)
-   Next Generation Level Editor (https://www.tombraiderforums.com/forumdisplay.php?f=40)
-   -   AkyVís released plugins (https://www.tombraiderforums.com/showthread.php?t=219148)

AkyV 26-02-18 16:57

Quote:

ExtractFrame field
------------------
See the required animation in WADMerger Animation Editor. You need to identify which is the very first frame when the required shotgun, grenade gun, crossbow weapon leaves perfectly the holsters (or Lara's back). For example, if it is the default extracting animation of the crossbow, then you can see it is probably Frame10. So you need to type 10 now in this field.

If it is pistol, revolver or Uzi, then it is not (!) a frame of this animation. It is a bit complicated to explain. That is why all I say is these are the frames I suggest (for the default animations):

-pistols: 13
-revolver: 15
-Uzis: 13

If you edit the animation, then you should use the "plus/minus one, two, three etc. frames" method to find the proper frame in the "trial and error" way.

The required animations are:

-pistols: PISTOLS_ANIM Animation 2
-revolver: SIXSHOOTER_ANIM Animation 2
-Uzis: UZI_ANIM Animation 2
-shotgun: SHOTGUN_ANIM Animation 1
-grenade gun: GREMADE_GUN_ANIM Animation 0
-crossbow: CROSSBOW_ANIM Animation 1

Type IGNORE here if you check only the holstering moment of the weapon.
Also type IGNORE if you check the whole holstered position, for pistol, revolver, Uzi.

Important note!
Never forget to check this frame in this field, each time when you edit this animation.
What you need is Frame15 instead of Frame1. :D

(Anyway, Frame15 is only one moment, naturally, so the Resumed feature to force it to be activated only at a tick frame is not really useful, it will do it either way. :) )

Titak 26-02-18 17:30

Why do I keep missing such info! :facepalm:

Tried it and made some progress.

Code:

; ---- show pistol in left holster when revolver is drawn
Parameters=      PARAM_WEAPON_HOLSTERS, 1, IGNORE, SIXSHOOTER_ITEM, 15, IGNORE
TriggerGroup=    106, $028000, 1, $A5
TriggerGroup=    108, $2000, 340, $200D, $2000, 355, $1405
GlobalTrigger=  46, IGNORE, GT_ALWAYS, IGNORE, 106, 108, IGNORE

TG108 now also contains a trigger to swap Lara's holster meshes with a holster meshes object in the LARA_DOUBLE_MIP slot.
Because that's the reason I started trying this C165 condition: to have a pistol in the left holster when drawing the sixshooter.
Tried this before with scripting, but that failed. This C165 makes that easier I thought. :D

However:
Lara draws the sixshooter for the first time: the screen flashes and the holsters are those in the LARA_DOUBLE_MIP slot (with a pistol in the left holster).
Lara holsters the sixshooter for the first time: the LARA_HOLSTERS_SIXSHOOTER appear, as it should.
So far so good. :D

But...

Lara draws the sixshooter for the second time: the screen flashes but this time the LARA_HOLSTERS appear.
Lara holsters the sixshooter for the second time: the LARA_HOLSTERS_SIXSHOOTER appear, as it should.

Lara draws the sixshooter for the third time: the screen flashes and the holsters are those in the LARA_DOUBLE_MIP slot (with a pistol in the left holster).
Lara holsters the sixshooter for the third time: the LARA_HOLSTERS_SIXSHOOTER appear, as it should.

Lara draws the sixshooter for the fourth time: the screen flashes but this time the LARA_HOLSTERS appear.

And so on.
So the holsters alternate between the LARA_HOLSTERS version and those in the LARA_DOUBLE_MIP slot. :confused:

And when I draw pistols, the holsters are also those of the LARA_DOUBLE_MIP slot, so with a pistol in the left holster.

So I need a way to somehow reverse the effect and return to the normal holsters in between.
But my mind draws a blank here... :o

AkyV 26-02-18 18:12

This is the general way how swaps work since TRLE. :D
I mean a swap not only a reference to a slot, but even a physical change between slots:

Original:
Slot A: object with X look
Slot B: object with Y look

Swap1:
Slot A: object with Y look
Slot B: object with X look

Swap2:
Slot A: object with X look
Slot B: object with Y look
Etc.

I don't know, perhaps you should swap them back when she is holstering, so the proper meshes (=another swap) will be shown up when extracting the next time. :ponder:

Titak 26-02-18 18:28

Can't use that F340 trigger again, because I can't pick the LARA_HOLSTERS from the list to swap to.

This one doesn't seem to work either, at least not so far with my current setup:
Code:

; Set Trigger Type - FLIPEFFECT 100
; Exporting: TRIGGER(3088:0) for FLIPEFFECT(100) {Tomb_NextGeneration}
; <#> : Lara. (Mesh) Set single <&>Lara mesh with mesh got from (E)slot
; <&> :  Objects in the Holsters
; (E) : SLOT  13  LARA_HOLSTERS
; Values to add in script command: $2000, 100, $C10

Don't know when to activate this either, to be honest. :ponder:

Actually, I've reached the same point as back then with my variables scripting setup. :vlol:
It's the alternating meshswap issue that stopped me from trying this any further.
Couldn't figure out how to swap back to the holsters then either.


On the other hand, what if I do manage to get it to work?
How would that look when having uzi's selected before drawing the sixshooter?
Lara would then have a pistol in the left holster instead of a uzi... :ponder:

Perhaps I should just leave it at this.
At least I can confirm that C165 is working. :D

AkyV 26-02-18 18:38

Quote:

Originally Posted by Titak (Post 7826398)
Can't use that F340 trigger again, because I can't pick the LARA_HOLSTERS from the list to swap to.

You don't need to choose another one.
I mean this trigger swaps, and the second activation swaps back etc:

Quote:

; Set Trigger Type - FLIPEFFECT 340
; Exporting: TRIGGER(8205:0) for FLIPEFFECT(340) {Tomb_NextGeneration}
; <#> : Lara. (Mesh) Swap Mesh of <&>Extra Lara Slots with that of (E)Slot
; <&> : SLOT 13 LARA_HOLSTERS
; (E) : SLOT 105 LARA_DOUBLE_MIP
; Values to add in script command: $2000, 340, $200D
Quote:

Couldn't figure out how to swap back to the holsters then either.
If you use PARAM_WEAPON_HOLSTERS to swap when extracting, then you can also use another Parameters like that to swap when holstering. :)
Anyway, I am not sure you need to keep swapping. I mean, after you swapped the proper object to the proper slot, then you will leave it there. It will be changed the next time only when you need the regular holsters again for the revolver.

Quote:

At least I can confirm that C165 is working. :D
Oh, yeah. :tmb:

matrix54 28-02-18 11:27

Titak, you could check a variable to check if Lara has swapped holsters before she draws them?

Titak 28-02-18 11:38

Hhm... I don't understand how that would help, because that would still leave the meshswap system that AkyV mentioned intact.

Quote:

Original:
Slot A: object with X look
Slot B: object with Y look

Swap1:
Slot A: object with Y look
Slot B: object with X look

Swap2:
Slot A: object with X look
Slot B: object with Y look
Etc.
So what would checking that variable have to do in this case? :ponder:

matrix54 28-02-18 11:47

It was in regressís to it happening every other time. With a variable, the game will stop checking every other draw.

If the variable is 0 or you donít have a bit set (whatever you prefer), when she draws a revolver, change the holster and set the bit to one/set the bit. So, every time she draws a holster, it wonít swap.

Again, when she draws the pistols, you do the opposite - check if the variable is
1, of if a bit has been set, then change the holster back, and reset the variable.

Titak 28-02-18 12:28

Hmm... I can look into that.
I was hoping I wouldn't have to use a variable anymore because I tend to use quite a few of them in my levels these days.
But it might work.

I'll come back asking questions if I can't figure it out. :p

LGG_PRODUCTION 08-03-18 16:05

I have two questions about the weapons:

Is it possible to have a crossbow with included and not detatchable lasersight?
Is it possible to have a shotgun with a single ammo pack available?


All times are GMT. The time now is 12:28.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, vBulletin Solutions Inc.