예제 #1
0
 public Ptr this[string name]
 {
     get
     {
         return(this[HashUtils.Fnv64(Encoding.ASCII.GetBytes(name.ToLower()))]);
     }
 }
 public bool TryAsUIReference()
 {
     if (CanContain(UIReference.SizeOf))
     {
         var uiRef = Read <UIReference>(0x00);
         if (((int)uiRef.x000_Hash == -1 && (int)(uiRef.x000_Hash >> 32) == -1 && uiRef.x008_Name == "None") ||
             HashUtils.Fnv64(Encoding.ASCII.GetBytes(uiRef.x008_Name.ToLower())) == uiRef.x000_Hash)
         {
             FieldType = typeof(UIReference).Name;
             Name      = "UIRef";
             Comment   = uiRef.x008_Name;
             FieldSize = UIReference.SizeOf;
             return(true);
         }
     }
     return(false);
 }