Exemplo n.º 1
0
        internal static SecurityToken GetUseKeySecurityToken(UseKey useKey, string requestKeyType)
        {
            if ((useKey == null) || (useKey.Token == null))
            {
                throw new NotSupportedException("UseKey is null");
            }

            return(useKey.Token);
        }
Exemplo n.º 2
0
    public override Interaction GetInteractionFor(LaraCroft user)
    {
        if (IsUsed)
        {
            return(null);
        }

        var hasKey      = user.Inventory.Items.Find(KeyName) != null;
        var interaction = (Interaction)null;

        if (hasKey)
        {
            interaction = new UseKey(user, this);
        }
        else
        {
            interaction = new MissingItem(user, this);
        }

        return(interaction);
    }
        internal static SecurityToken GetUseKeySecurityToken(UseKey useKey, string requestKeyType)
        {
            if ((useKey == null) || (useKey.Token == null))
            {
                throw new NotSupportedException("UseKey is null");
            }

            return useKey.Token;
        }
Exemplo n.º 4
0
 // Use this for initialization
 void Start()
 {
     currentUseKey = UseKey.None;
 }