Beispiel #1
0
        public ProductBlock(SerializedProperty property, ItemModule module) : base(property, module)
        {
            productInfo = property.FindAutoPropertyRelative("ProductInfo");
            product     = property.FindPropertyRelative("product");
            float lineHeight      = EditorGUIUtility.singleLineHeight;
            float lineHeightSpace = lineHeight + EditorGUIUtility.standardVerticalSpacing;

            list = new DropItemListDrawer(serializedObject, product, lineHeight, lineHeightSpace);
        }
    private void OnEnable()
    {
        lineHeight      = EditorGUIUtility.singleLineHeight;
        lineHeightSpace = lineHeight + 2;

        info = target as ResourceInformation;

        _ID          = serializedObject.FindProperty("_ID");
        _name        = serializedObject.FindProperty("_name");
        gatherType   = serializedObject.FindProperty("gatherType");
        gatherTime   = serializedObject.FindProperty("gatherTime");
        refreshTime  = serializedObject.FindProperty("refreshTime");
        lootPrefab   = serializedObject.FindProperty("lootPrefab");
        productItems = serializedObject.FindProperty("productItems");
        dropList     = new DropItemListDrawer(serializedObject, productItems, lineHeight, lineHeightSpace);

        gathering = Resources.LoadAll <ResourceInformation>("Configuration");
    }
Beispiel #3
0
 private void OnEnable()
 {
     remark     = serializedObject.FindProperty("remark");
     products   = serializedObject.FindProperty("products");
     listDrawer = new DropItemListDrawer(serializedObject, products, EditorGUIUtility.singleLineHeight, EditorGUIUtility.singleLineHeight + 2);
 }