Curation round 18: tears and four weapons, passive item and trinket sweeps, pills and most cards, alt path and main path enemies, Hush and the Blue Womb, Mega Satan, the Void, Tainted ???, Forgotten, Lilith and Eden, wisps
This commit is contained in:
1 parent
024cb12016
commit
9dfc09518c
157 files changed
+24212
-6106
No files matched your search
+38
-9
@@ -1,4 +1,5 @@
|
||||
#include "entity.h"
|
||||
#include "capsule.h"
|
||||
#include "entity_effect.h"
|
||||
#include "entity_familiar.h"
|
||||
#include "entity_list.h"
|
||||
@@ -1250,10 +1251,44 @@ void* Entity::GetDebugShape(bool)
|
||||
reconstruction_missing("Entity::GetDebugShape 006b5f10");
|
||||
}
|
||||
|
||||
// 006b6c20
|
||||
void Entity::GetNullCapsule(Capsule&, std::string_view)
|
||||
// 006b6c20 The capsule its sprite's null layer covers: placed and turned like GetNullOffset, four times the null's
|
||||
// scale wide and tall, or a point at its position while the null is hidden or missing.
|
||||
void Entity::GetNullCapsule(Capsule& outCapsule, std::string_view nullLayerName)
|
||||
{
|
||||
reconstruction_missing("Entity::GetNullCapsule 006b6c20");
|
||||
constexpr float NULL_CAPSULE_SIZE = 4;
|
||||
const NullFrame* frame = sprite.animState.animData ? sprite.animState.GetNullFrame(nullLayerName) : nullptr;
|
||||
if (!frame || !frame->isVisible)
|
||||
{
|
||||
outCapsule = Capsule(pos, Vector{}, 0, 0);
|
||||
return;
|
||||
}
|
||||
|
||||
Vector offset = vector_make(frame->pos.x / ROOM_SCREEN_SCALE * sprite.scale.x, frame->pos.y / ROOM_SCREEN_SCALE * sprite.scale.y);
|
||||
Vector size = vector_make(frame->scale.x * NULL_CAPSULE_SIZE / ROOM_SCREEN_SCALE * sprite.scale.x,
|
||||
frame->scale.y * NULL_CAPSULE_SIZE / ROOM_SCREEN_SCALE * sprite.scale.y);
|
||||
float rotation = frame->rotation;
|
||||
if (sprite.isFlipX) size.x = -size.x;
|
||||
if (sprite.isFlipY) size.y = -size.y;
|
||||
if (size.x < 0)
|
||||
{
|
||||
size.x = -size.x;
|
||||
rotation = 180 - rotation;
|
||||
offset.x = -offset.x;
|
||||
}
|
||||
if (size.y < 0)
|
||||
{
|
||||
size.y = -size.y;
|
||||
offset.y = -offset.y;
|
||||
rotation = -rotation;
|
||||
}
|
||||
if (sprite.rotation != 0)
|
||||
{
|
||||
float angle = sprite.rotation * DEGREES_TO_RADIANS;
|
||||
rotation += sprite.rotation;
|
||||
offset = vector_make(std::cos(angle) * offset.x - std::sin(angle) * offset.y,
|
||||
std::cos(angle) * offset.y + std::sin(angle) * offset.x);
|
||||
}
|
||||
outCapsule = Capsule(vector_add(offset, pos), size, rotation, 1);
|
||||
}
|
||||
|
||||
// 007079c0
|
||||
@@ -1262,12 +1297,6 @@ void Entity::RemoveWithPoof(Entity*)
|
||||
reconstruction_missing("Entity::RemoveWithPoof 007079c0");
|
||||
}
|
||||
|
||||
// 0070c000
|
||||
void Entity::DestroyRockGridAt(const Vector&, GridEntityDesc*, Entity*, int)
|
||||
{
|
||||
reconstruction_missing("Entity::DestroyRockGridAt 0070c000");
|
||||
}
|
||||
|
||||
// 0085e680
|
||||
int Entity::IsVulnerableEnemy_lua(lua_State*)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user