2024-04-13 13:18:57 -07:00
|
|
|
|
#define GEN_DEFINE_LIBRARY_CODE_CONSTANTS
|
|
|
|
|
#define GEN_ENFORCE_STRONG_CODE_TYPES
|
|
|
|
|
#define GEN_EXPOSE_BACKEND
|
|
|
|
|
// #define GEN_DEFINE_ATTRIBUTE_TOKENS
|
|
|
|
|
#define GEN_IMPLEMENTATION
|
2024-10-25 02:04:11 -07:00
|
|
|
|
#include "gen.dep.cpp"
|
2024-04-13 13:18:57 -07:00
|
|
|
|
#include "gen.cpp"
|
|
|
|
|
#include "gen.builder.cpp"
|
2024-04-21 06:51:51 -07:00
|
|
|
|
// #include "gen.scanner.hpp"
|
2024-04-13 13:18:57 -07:00
|
|
|
|
using namespace gen;
|
|
|
|
|
|
2024-04-21 06:51:51 -07:00
|
|
|
|
#ifdef GEN_SYSTEM_WINDOWS
|
|
|
|
|
#include <process.h>
|
|
|
|
|
#endif
|
|
|
|
|
|
2024-04-14 18:51:14 -07:00
|
|
|
|
#include "GasaGenCommon.cpp"
|
2024-04-16 02:02:58 -07:00
|
|
|
|
#include "GasaGen_ue_parse_testing.cpp"
|
2024-04-14 18:51:14 -07:00
|
|
|
|
#include "GasaGen_UGasaAttributeSet.cpp"
|
2024-04-17 09:16:22 -07:00
|
|
|
|
#include "GasaGen_ChangeBPActionMenu.cpp"
|
2024-04-21 06:51:51 -07:00
|
|
|
|
#include "GasaGen_DevOptionsCache.cpp"
|
2024-04-21 21:30:29 -07:00
|
|
|
|
#include "GasaGen_HostWidgetController.cpp"
|
2024-04-22 22:10:02 -07:00
|
|
|
|
#include "GasaGen_NetSlime.cpp"
|
2024-04-21 21:30:29 -07:00
|
|
|
|
|
2024-04-13 13:18:57 -07:00
|
|
|
|
int gen_main()
|
|
|
|
|
{
|
2024-12-14 05:46:22 -08:00
|
|
|
|
ctx = {};
|
|
|
|
|
gen::init(& ctx);
|
2024-04-21 06:51:51 -07:00
|
|
|
|
log_fmt("Generating code for the Gasa module\n");
|
2024-04-13 13:18:57 -07:00
|
|
|
|
|
2024-04-14 18:51:14 -07:00
|
|
|
|
// Initialize Globals
|
2024-04-21 06:51:51 -07:00
|
|
|
|
{
|
|
|
|
|
UHT_UCLASS = code_str( UCLASS() );
|
|
|
|
|
UHT_UPROPERTY = code_str( UPROPERTY() );
|
|
|
|
|
UHT_USTRUCT = code_str( USTRUCT() );
|
|
|
|
|
UHT_GENERATED_BODY = code_str( GENERATED_BODY()\n );
|
|
|
|
|
UModule_GASA_API = code_str( GASA_API );
|
|
|
|
|
}
|
2024-04-15 20:09:46 -07:00
|
|
|
|
|
2024-04-21 06:51:51 -07:00
|
|
|
|
// Populate Defines
|
2024-12-15 11:13:44 -08:00
|
|
|
|
register_macros( args(
|
|
|
|
|
(Macro { str_DECLARE_CLASS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DELEGATE_RetVal_OneParam, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DELEGATE_RetVal_ThreeParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DELEGATE_SixParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_FiveParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_FourParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_NineParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_OneParam, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_SevenParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_DYNAMIC_MULTICAST_SPARSE_DELEGATE_TwoParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_EVENT_ThreeParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_EVENT_TwoParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_FUNCTION, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_LOG_CATEGORY_EXTERN, MT_Statement, MF_Functional | MF_Allow_As_Definition }),
|
|
|
|
|
(Macro { str_DECLARE_MULTICAST_DELEGATE_OneParam, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_MULTICAST_DELEGATE_ThreeParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_MULTICAST_DELEGATE_TwoParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_TS_MULTICAST_DELEGATE_OneParam, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_TS_MULTICAST_DELEGATE_TwoParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DECLARE_TS_MULTICAST_DELEGATE_ThreeParams, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DEFINE_ACTORDESC_TYPE, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_DEFINE_DEFAULT_OBJECT_INITIALIZER_CONSTRUCTOR_CALL, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_ENUM_CLASS_FLAGS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GENERATED_BODY, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GENERATED_UCLASS_BODY, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GENERATED_USTRUCT_BODY, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_PRAGMA_DISABLE_DEPRECATION_WARNINGS, MT_Statement, MF_Null | MF_Allow_As_Attribute }),
|
|
|
|
|
(Macro { str_PRAGMA_ENABLE_DEPRECATION_WARNINGS, MT_Statement, MF_Null | MF_Allow_As_Attribute }),
|
|
|
|
|
(Macro { str_PROPERTY_BINDING_IMPLEMENTATION, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_RESULT_DECL, MT_Expression, MF_Functional }),
|
|
|
|
|
(Macro { str_SLATE_BEGIN_ARGS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_SLATE_END_ARGS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_TEXT, MT_Expression, MF_Functional }),
|
|
|
|
|
(Macro { str_UCLASS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_UENUM, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_UFUNCTION, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_UMETA, MT_Expression, MF_Functional }),
|
|
|
|
|
(Macro { str_UPARAM, MT_Expression, MF_Functional }),
|
|
|
|
|
(Macro { str_UPROPERTY, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_USTRUCT, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_UE_REQUIRES, MT_Expression, MF_Functional }),
|
|
|
|
|
(Macro { str_UE_DEPRECATED, MT_Statement, MF_Functional | MF_Allow_As_Attribute }),
|
|
|
|
|
(Macro { str_ACTOR_HAS_LABELS, MT_Expression, MF_Null }),
|
|
|
|
|
(Macro { str_HIDE_ACTOR_TRANSFORM_FUNCTIONS, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_SCENECOMPONENT_QUAT_TOLERANCE, MT_Expression, MF_Null }),
|
|
|
|
|
(Macro { str_SCENECOMPONENT_ROTATOR_TOLERANCE, MT_Expression, MF_Null }),
|
|
|
|
|
(Macro { str_GAMEPLAYATTRIBUTE_REPNOTIFY, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GAMEPLAYATTRIBUTE_PROPERTY_GETTER, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GAMEPLAYATTRIBUTE_VALUE_GETTER, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GAMEPLAYATTRIBUTE_VALUE_SETTER, MT_Statement, MF_Functional }),
|
|
|
|
|
(Macro { str_GAMEPLAYATTRIBUTE_VALUE_INITTER, MT_Statement, MF_Functional })
|
|
|
|
|
));
|
2024-04-14 18:51:14 -07:00
|
|
|
|
|
2024-10-25 02:04:11 -07:00
|
|
|
|
// gen_UGasaAttributeSet();
|
|
|
|
|
// gen_FGasaDevOptionsCache();
|
|
|
|
|
// gen_UHostWidgetController();
|
2024-04-22 22:10:02 -07:00
|
|
|
|
// gen_netslime_interfaces();
|
2024-04-21 06:51:51 -07:00
|
|
|
|
|
|
|
|
|
// One offs
|
2024-10-25 02:04:11 -07:00
|
|
|
|
if (1)
|
2024-04-21 06:51:51 -07:00
|
|
|
|
{
|
2024-10-25 02:04:11 -07:00
|
|
|
|
ue_parse_testing();
|
|
|
|
|
//swap_SBlueprintActionMenu_Construct();
|
2024-04-21 06:51:51 -07:00
|
|
|
|
}
|
2024-04-13 13:18:57 -07:00
|
|
|
|
return 0;
|
|
|
|
|
}
|