1 Reply Latest reply on Feb 17, 2017 6:36 AM by SuperMerlin

    Stuck trying to read the global light angles (Cannot identify key type)

    Heimdaal Level 1
      // Place the enumeration into the document descriptor
      var document = sTID("document");
      var ordinal = sTID("ordinal");
      var target = sTID("targetEnum");
      
      
      
      
      var ref = new ActionReference(); 
      ref.putEnumerated(sTID("layer"), sTID("ordinal"), sTID("targetEnum")); 
      var desc = executeActionGet(ref);
      
      
      var keyID = desc.getKey(11);
      
      
      alert(typeIDToStringID(keyID));
      

       

      I've tried all sorts of methods on this key and I don't know what to do with it. IE: How do you go into it deeper when you can't even find out what TYPE it is?

       

      desc.getBpolean(keyID); // returns true

      desc.getDouble(keyID); // returns 3

      desc.getInteger(keyID); // returns 3

      desc.getList(keyID); // returns an ActionList -object containing nothing

      desc.getType(keyID); // returns INTEGERTYPE (because duh... the key is a number)

      desc.getUnitDoubleType(keyID); // returns a new keyID for noneType

      desc.getUnitDoubleValue(keyID); // returns 3

       

      TL:DR:

      Where is the global light - altitude angle, stored? How do I retrieve it?