Updated Useful Scripting Specials (markdown)

ghoulslash 2022-07-30 06:39:27 -06:00
parent 37ba7b86d2
commit e0a696d9df
1 changed files with 8 additions and 2 deletions

@ -33,7 +33,7 @@ void GetObjectPosition(void)
if (!useTemplate)
{
/* current position */
const u16 objId = GetObjectEventIdByLocalIdIncludeInactive(localId);
const u16 objId = GetObjectEventIdByLocalId(localId);
const struct ObjectEvent *objEvent = &gObjectEvents[objId];
*x = objEvent->currentCoords.x - 7; // subtract out camera size
*y = objEvent->currentCoords.y - 7;
@ -52,4 +52,10 @@ void GetObjectPosition(void)
3. Finally, add our new special to the specials table in `data/specials.inc`
`def_special GetObjectPosition`
`def_special GetObjectPosition`
## 2. checkobjectat
credits to ghoulslash
Checks in any object is at a given position