Add Base Item Class for Inventory
This commit is contained in:
parent
280644da78
commit
9362f478aa
@ -10,7 +10,8 @@
|
|||||||
"LoadingPhase": "Default",
|
"LoadingPhase": "Default",
|
||||||
"AdditionalDependencies": [
|
"AdditionalDependencies": [
|
||||||
"Engine",
|
"Engine",
|
||||||
"AIModule"
|
"AIModule",
|
||||||
|
"CoreUObject"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -0,0 +1,5 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
|
||||||
|
#include "BaseItem.h"
|
||||||
|
|
42
EndlessVendetta/Source/EndlessVendetta/Inventory/BaseItem.h
Normal file
42
EndlessVendetta/Source/EndlessVendetta/Inventory/BaseItem.h
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
// Fill out your copyright notice in the Description page of Project Settings.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "CoreMinimal.h"
|
||||||
|
#include "UObject/NoExportTypes.h"
|
||||||
|
#include "BaseItem.generated.h"
|
||||||
|
|
||||||
|
USTRUCT()
|
||||||
|
struct FItemSize
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
int x;
|
||||||
|
int y;
|
||||||
|
|
||||||
|
FItemSize(int _x, int _y)
|
||||||
|
{
|
||||||
|
x = _x;
|
||||||
|
y = _y;
|
||||||
|
}
|
||||||
|
FItemSize()
|
||||||
|
{
|
||||||
|
x = 1;
|
||||||
|
y = 1;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
UCLASS()
|
||||||
|
class ENDLESSVENDETTA_API UBaseItem : public UObject
|
||||||
|
{
|
||||||
|
GENERATED_BODY()
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
const FName ItemName;
|
||||||
|
const FText Description;
|
||||||
|
const FItemSize ItemSize = FItemSize(1, 1);
|
||||||
|
};
|
Loading…
Reference in New Issue
Block a user