Aller au contenu

Photo

Stealth problem, a bug perhaps ?


  • Veuillez vous connecter pour répondre
2 réponses à ce sujet

#1
BioSpirit

BioSpirit
  • Members
  • 261 messages
I was trying to setup an ambush using genlock rogues. They supposed to be in stealth mode until the player walks into a trigger. I am not exactly sure how is this supposed to do but I usually prefer scripting.

a Creature script for the a rogue:

case EVENT_TYPE_SPAWN:
{
       SetGroupId(OBJECT_SELF, GROUP_NEUTRAL);
       SetStealthEnabled(OBJECT_SELF, TRUE);
       break;
}


a Trigger script:

case EVENT_TYPE_ENTER:
{
        if ( IsPartyMember( GetEventCreator(ev) ) )
        {
            UT_TeamGoesHostile(4, TRUE);
            DestroyObject(OBJECT_SELF, 0);
        }
}


As a result the rogues will start attacking the player. But the stealth mode won't go a way. Player's party is geting a damage from the attacks but the patry remains in non-combatant state and won't engage in a battle. The red circles around the hostile creatures are missing. Shouldn't the stealth go a way when engaging in battle ?

I also tried to replace the UT_TeamGoesHostile with my own version of the script that will simply set the status using SetGroupId(xxx, GROUP_HOSTILE); but no change.  It started to work when I removed the stealth by force using SetStealthEnabled(xxx, FALSE); in a trigger script.

Also EVENT_TYPE_COMBAT_INITIATED in creature script isn't called. At first I was trying to remove the stealth using SetStealthEnabled(OBJECT_SELF, FALSE); in that section of the script.
 

Modifié par BioSpirit, 20 décembre 2009 - 01:54 .


#2
BioSpirit

BioSpirit
  • Members
  • 261 messages
There was some typical rogue talents set for the creatures including STEALTH and COMBAT_STEALTH.

Modifié par BioSpirit, 20 décembre 2009 - 02:13 .


#3
BioSpirit

BioSpirit
  • Members
  • 261 messages
Ok, I placed the SetStealthEnabled(FALSE) in EVENT_TYPE_ATTACK_IMPACT and it's working pretty well.