LeviLamina
Loading...
Searching...
No Matches
ScriptPotions.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/scripting/lifetime_registry/StrongTypedObjectHandle.h"
7#include "mc/deps/scripting/runtime/Result.h"
8#include "mc/world/item/alchemy/Potion.h"
9
10// auto generated forward declare list
11// clang-format off
12class HashedString;
13class Potion;
14namespace ScriptModuleMinecraft { class ScriptItemStack; }
15namespace ScriptModuleMinecraft { class ScriptPotionDeliveryType; }
16namespace ScriptModuleMinecraft { class ScriptPotionEffectType; }
17namespace ScriptModuleMinecraft { struct ScriptInvalidPotionDeliveryTypeError; }
18namespace ScriptModuleMinecraft { struct ScriptInvalidPotionEffectTypeError; }
19namespace Scripting { class WeakLifetimeScope; }
20namespace Scripting { struct ClassBinding; }
21namespace Scripting { struct EngineError; }
22// clang-format on
23
24namespace ScriptModuleMinecraft {
25
26class ScriptPotions {
27public:
28 // ScriptPotions inner types define
29 using Key = ::HashedString;
30
31public:
32 // member variables
33 // NOLINTBEGIN
34 ::ll::TypedStorage<
35 8,
36 64,
37 ::std::unordered_map<
38 ::Potion::PotionType,
40 mPotionDeliveryTypeHandles;
41 ::ll::TypedStorage<
42 8,
43 64,
44 ::std::unordered_map<
45 ::std::string,
47 mPotionEffectTypeHandles;
48 // NOLINTEND
49
50public:
51 // prevent constructor by default
52 ScriptPotions& operator=(ScriptPotions const&);
53
54public:
55 // member functions
56 // NOLINTBEGIN
57 MCAPI ScriptPotions();
58
59 MCAPI ScriptPotions(::ScriptModuleMinecraft::ScriptPotions&&);
60
61 MCAPI ScriptPotions(::ScriptModuleMinecraft::ScriptPotions const&);
62
63 MCAPI ::ScriptModuleMinecraft::ScriptPotions& operator=(::ScriptModuleMinecraft::ScriptPotions&&);
64 // NOLINTEND
65
66public:
67 // static functions
68 // NOLINTBEGIN
69 MCAPI static ::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotions>
70 _getHandle(::Scripting::WeakLifetimeScope& scope);
71
72 MCAPI static ::Scripting::ClassBinding bind();
73
74 MCAPI static ::std::vector<::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotionDeliveryType>>
75 getDeliveryTypes(::Scripting::WeakLifetimeScope scope);
76
77 MCAPI static ::std::vector<::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotionEffectType>>
78 getEffectTypes(::Scripting::WeakLifetimeScope scope);
79
80 MCAPI static ::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotionDeliveryType>
81 getOrCreatePotionDeliveryType(::Potion::PotionType potionType, ::Scripting::WeakLifetimeScope scope);
82
83 MCAPI static ::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotionEffectType>
84 getOrCreatePotionEffectType(
85 ::gsl::not_null<::std::shared_ptr<::Potion const>> potion,
87 );
88
89 MCAPI static ::std::optional<
91 getPotionDeliveryType(::Scripting::WeakLifetimeScope scope, ::std::string const& potionTypeId);
92
93 MCAPI static ::std::optional<::Scripting::StrongTypedObjectHandle<::ScriptModuleMinecraft::ScriptPotionEffectType>>
94 getPotionEffectType(::Scripting::WeakLifetimeScope scope, ::std::string const& potionTypeId);
95
96 MCAPI static ::Scripting::Result<
101 resolve(
103 ::std::variant<
104 ::std::string,
106 ::std::variant<
107 ::std::string,
109 );
110 // NOLINTEND
111
112public:
113 // constructor thunks
114 // NOLINTBEGIN
115 MCAPI void* $ctor();
116
117 MCAPI void* $ctor(::ScriptModuleMinecraft::ScriptPotions&&);
118
119 MCAPI void* $ctor(::ScriptModuleMinecraft::ScriptPotions const&);
120 // NOLINTEND
121};
122
123} // namespace ScriptModuleMinecraft
Definition HashedString.h:5
Definition Potion.h:14
Definition ScriptItemStack.h:35
Definition ScriptPotionDeliveryType.h:15
Definition ScriptPotionEffectType.h:17
Definition ScriptPotions.h:26
Definition StrongTypedObjectHandle.h:8
Definition WeakLifetimeScope.h:7
Definition ScriptInvalidPotionDeliveryTypeError.h:15
Definition ScriptInvalidPotionEffectTypeError.h:15
Definition ClassBinding.h:19
Definition EngineError.h:15