Esempio n. 1
0
 public T this[string internalName, ModInfo mod]
 {
     get
     {
         return(byObjRef(new ObjectRef(internalName, mod), ModData.ModFromAssembly(Assembly.GetCallingAssembly())));
     }
 }
Esempio n. 2
0
 public T this[ObjectRef objRef]
 {
     get
     {
         return(byObjRef(objRef, ModData.ModFromAssembly(Assembly.GetCallingAssembly())));
     }
 }
Esempio n. 3
0
        protected EntityRef(ObjectRef objRef, Assembly calling)
            : this(() => objRef.Name)
        {
            resName = new Lazy <string>(() => objRef.Name);

            ModName = objRef.ModName;

            Requesting = ModData.ModFromAssembly(calling);
        }
Esempio n. 4
0
        public ObjectRef(string name, string modName = null)
        {
            if (String.IsNullOrEmpty(name))
            {
                throw new ArgumentNullException("name");
            }

            this.name    = name;
            this.modName = modName ?? String.Empty;

            requesting = ModData.ModFromAssembly(Assembly.GetCallingAssembly());
        }