Companion won't enter stealth

Post » Tue Dec 06, 2011 4:09 pm

I'm trying to make a companion, but he won't enter stealth when I do. I'm using version the 1.4 versions of both the game and the G.E.C.K.

1. I've set the companion's faction to the DontTazeMeBro.
2. Where you can hire the companion, I'm using this in the results:

Set JacGarrickRef.Waiting to 0Set JacGarrickREF.IsFollowingDefault to 1Set JacGarrickREF.CombatStyleRanged to 1SetPlayerTeammate 1SetIgnoreFriendlyHits 1JacGarrickREF.AddToFaction FollowerFaction 1JacGarrickREF.SetFactionRank TeammateFaction 1ResetAI


3. The companion's script is very simple right now for testing purposes:

scn JacGarrickScriptshort 	HasBeenHiredshort	WeaponOutshort	CombatStyleRangedshort	CombatStyleMeleeshort	IsFollowingDefaultshort	IsFollowingShortshort	IsFollowingLongshort FollowerSwitchAggressive			; 0 = Passive (wait for player), 1 = Aggressive (attack when see enemy)short	Waiting


Any insight would be much appreciated. Thanks. :cookie:
User avatar
Big mike
 
Posts: 3423
Joined: Fri Sep 21, 2007 6:38 pm

Post » Tue Dec 06, 2011 7:43 am

You mean 'sneak when player sneaks' ? They need to be in a 'follow' type package. If you are using guard packages then you need to use the SetForceSneak, GetForceSneak, Player.IsSneaking in the NPC's object script.
User avatar
latrina
 
Posts: 3440
Joined: Mon Aug 20, 2007 4:31 pm

Post » Tue Dec 06, 2011 5:14 pm

I'm not sure what it was, but it started working for some reason. :shrug: I did want to check for when the player was sneaking, but for some reason, that check wasn't happening. If it's if Player.IsSneaking, I'll try it again. Speaking of which, should I add that check to the NPC's script or to his quest dialog? I want to set it so that whenever you talk to the companion while sneaking, he'll stay sneaking instead of standing up like a huge target. I was able to do that in FO3, but not in NV so far. Thanks.
User avatar
Austin Suggs
 
Posts: 3358
Joined: Sun Oct 07, 2007 5:35 pm

Post » Tue Dec 06, 2011 6:46 am

I use a script package to make them stay sneaking. It bypasses the wheel, btw. For my Wendy companion I had my own menu pop up when sneaking, so you could talk or get the wheel. But here's basically what I did on the NPC script:

BEGIN OnActivate	if (IsActionRef player)		if (Player.IsSneaking)			AddScriptPackage MyNPCSneakGreetingPKG		;force dialog package 'GREETING' Topic with 'always sneak' selected		else			Activate		endif	endif		END

User avatar
Kim Bradley
 
Posts: 3427
Joined: Sat Aug 18, 2007 6:00 am

Post » Tue Dec 06, 2011 9:59 am

Ah, thanks. I'll have to try that.
User avatar
Yama Pi
 
Posts: 3384
Joined: Wed Apr 18, 2007 3:51 am


Return to Fallout: New Vegas