Enemy Functions

From Danmakufu Wiki
Jump to: navigation, search

GetEnemyBossSceneObjectID

Returns: ID (real)

Gets the boss scene object ID.

When not in a boss scene, returns ID_INVALID.

GetEnemyBossObjectID

Returns: ID (real, array)

Gets the ID of the boss present on the screen, and returns it in an array.

GetAllEnemyID

Returns: ID (real, array)

Gets the ID of every enemy present on the screen, and returns them in an array.

GetIntersectionRegistedEnemyID

Returns: ID (real, array)

Gets the Object ID of all enemies with a registered hitbox to player shots (via ObjEnemy_SetIntersectionCircleToShot()).

GetAllEnemyIntersectionPosition

Returns: 2D array (real)

Gets the the position of all enemies for which collision detection is true (currently intersecting), and returns it in a 2-dimension array ([index][<x-coordinate, y-coordinate>]).

GetEnemyIntersectionPosition

Arguments:
 1) x-coordinate (real)
 2) y-coordinate (real)
 3) highest acquisition value (real)

Returns: 2D array (real)

Gets the enemy intersection position around given position, and returns a 2D array ([index][<x-coordinate, y-coordinate>]).

The first value (index 0) corresponds to the nearest position.

GetEnemyIntersectionPositionByIdA1

Arguments:
 1) enemy object ID (real)

Returns: 2D array (real)

Gets all collision detection positions of the specified enemy, and returns a 2D array ([index][<x-coordinate, y-coordinate>]).

The first value (index 0) corresponds to the nearest position from the enemy (unsure).

GetEnemyIntersectionPositionByIdA2

Arguments:
 1) enemy object ID (real)
 2) x-coordinate (real)
 3) y-coordinate (real)

Returns: 2D array (real)

Gets all collision detection positions of the specified enemy, and returns a 2D array ([index][<x-coordinate, y-coordinate>]).

The first value (index 0) corresponds to the nearest position from the specified position.

LoadEnemyShotData

Arguments:
 1) path of the file (char)

Loads specified shot image file.

missing explanation about calling the function several times (?)

Files with the same name can only be loaded once.

ReloadEnemyShotData

Arguments:
 1) path of the file (char)

Reloads specified shot image file (you can also (re)load a file that has not been loaded by LoadEnemyShotData).

missing explanation about calling the function several times (?)

Unlike LoadEnemyShotData, this function can load the same file several times.