Author |
Message |
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
How to prevent alerting (or an alternative)
I'm sorry to ask ANOTHER question after so many already, but this will probably be the last or second to last in a while because I am very close to release. My Sweet Dreams mission has skippable intros and outros, which I've been working on recently... Anyways, I rely on switching to an invisible (thanks to Lua tricks) brain for the camera. Although in the intro I could conceal the brain inside a wall, making it not alert players, (it's on the rogue team so it's health doesn't show but that means if it's in the line of sight, players get alarmed by it) but I can't do that in the outro because it's out in the open. The alerted character always looks at the invisible brain no matter what I do, and I can't seem to stop it. Using Actor:SetAimAngle doesn't work because apparently looking at stuff when you're alerted has higher priority or something than that. What do I do? Can I force him to look somewhere else? Could I make him ignore the brain somehow?
|
Mon Aug 23, 2010 12:49 am |
|
|
Grif
REAL AMERICAN HERO
Joined: Sat Jan 27, 2007 10:25 pm Posts: 5655
|
Re: How to prevent alerting (or an alternative)
If you set the...I think it's Awareness .ini variable to 0, he probably won't do anything, though the exclamation point will still appear.
It's located somewhere in the .ini file for the Mother Crab.
|
Mon Aug 23, 2010 12:56 am |
|
|
Petethegoat
Joined: Mon Jun 15, 2009 4:02 pm Posts: 905
|
Re: How to prevent alerting (or an alternative)
Instead of making it rogue, why not just make it's CharHeight something like -240?
|
Mon Aug 23, 2010 1:04 am |
|
|
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
Re: How to prevent alerting (or an alternative)
Petethegoat wrote: Instead of making it rogue, why not just make it's CharHeight something like -240? That didn't work... =(
|
Mon Aug 23, 2010 1:26 am |
|
|
Petethegoat
Joined: Mon Jun 15, 2009 4:02 pm Posts: 905
|
Re: How to prevent alerting (or an alternative)
I assume you've tried an absurdly high positive value? It wouldn't be entirely illogical to disallow negative CharHeight. I'd be more helpful, but I don't have a working copy of CC with me.
|
Mon Aug 23, 2010 2:49 am |
|
|
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
Re: How to prevent alerting (or an alternative)
Petethegoat wrote: I assume you've tried an absurdly high positive value? It wouldn't be entirely illogical to disallow negative CharHeight. I'd be more helpful, but I don't have a working copy of CC with me. Yes, I have. Thanks! Helping at all, CC or not, is still great.
|
Tue Aug 24, 2010 7:23 pm |
|
|
p3lb0x
Forum Moderator
Joined: Fri Feb 02, 2007 3:53 pm Posts: 1896 Location: in my little gay bunker
|
Re: How to prevent alerting (or an alternative)
Alternatively, make it GetsHitByMOs = 0. It should be invisible to actors then
|
Tue Aug 24, 2010 9:05 pm |
|
|
whitty
Joined: Sat Jun 16, 2007 2:31 am Posts: 2982 Location: Texas
|
Re: How to prevent alerting (or an alternative)
p3lb0x wrote: Alternatively, make it GetsHitByMOs = 0. It should be invisible to actors then This. It'll never be looked at unless it fires something with its invisible and non-existent hands. And if that ever happened anyway, it still wouldn't be shot at. The AI would just look there.
|
Wed Aug 25, 2010 12:18 am |
|
|
numgun
Joined: Sat Jan 13, 2007 11:04 pm Posts: 2932
|
Re: How to prevent alerting (or an alternative)
Brains seem to be hardcoded to be noticed even when a normal unit would be.
As an example, try playing any game as a brain bot and try to sneak up on an enemy from behind. You will fail no matter what, he will turn around the moment you get him in your line of sight, even if he is facing the other way.
Use a different camera-centering function (Like CC48's Guided Missile Launcher) or use a non-brain actor for your purposes, its the only way AFAIK.
|
Fri Aug 27, 2010 9:07 am |
|
|
411570N3
Joined: Wed Jan 07, 2009 10:26 am Posts: 4074 Location: That quaint little British colony down south
|
Re: How to prevent alerting (or an alternative)
Try just using a generic actor. There isn't really a reason I can think of to use a brain, and it has the disadvantages listed above.
|
Fri Aug 27, 2010 9:09 am |
|
|
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
Re: How to prevent alerting (or an alternative)
The GetsHitByMOs = 0 worked perfectly. Thanks!
EDIT: I have a new problem, see below. I guarantee you if this gets fixed I'll be done.
Last edited by Awesomeness on Tue Aug 31, 2010 1:34 am, edited 1 time in total.
|
Mon Aug 30, 2010 10:49 pm |
|
|
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
Re: How to prevent alerting (or an alternative)
I am so close to the beta release of my mission. If I can get this problem fixed, I will be ready to go. Somehow I must have avoided this problem before by skipping to the outro when the mission started while developing it, but without skipping it, throughout the outro the character looks up and down periodically like he's on sentry. When the outro tells hims to look somewhere, he'll look there for half a second until the game tells him to look up or down for sentry again. Setting his AI mode to none failed and I don't know what else to do...
|
Tue Aug 31, 2010 1:16 am |
|
|
TheLastBanana
DRL Developer
Joined: Wed Dec 13, 2006 5:27 am Posts: 3138 Location: A little south and a lot west of Moscow
|
Re: How to prevent alerting (or an alternative)
Code: actor:SetAimAngle(0);
|
Tue Aug 31, 2010 1:37 am |
|
|
Awesomeness
Joined: Sat Jun 19, 2010 5:02 pm Posts: 331 Location: Mekkan
|
Re: How to prevent alerting (or an alternative)
TheLastBanana wrote: Code: actor:SetAimAngle(0); Awesomeness wrote: When the outro tells hims to look somewhere, he'll look there for half a second until the game tells him to look up or down for sentry again. Read my post please? By the way, would telling him to look at the desired spot every frame work? EDIT: It worked! I will release the beta before today ends!
|
Tue Aug 31, 2010 1:04 pm |
|
|
411570N3
Joined: Wed Jan 07, 2009 10:26 am Posts: 4074 Location: That quaint little British colony down south
|
Re: How to prevent alerting (or an alternative)
TLB gave you the code to do every frame. Just use maths to find the right angle and you're off. If you don't know the trig then ask.
|
Tue Aug 31, 2010 1:31 pm |
|
|
|