Guest User

SADX Event Functions List

a guest
Sep 8th, 2023
1,058
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.07 KB | Gaming | 0 0
  1. These are best viewed alongside the cutscene decomp:
  2. https://github.com/X-Hax/SADX-cutscene-decompilation
  3.  
  4. For basics about what "task" etc. means, see the SADX Modding Guide:
  5. https://github.com/X-Hax/SADXModdingGuide/wiki
  6.  
  7. ///Detect if an event is running with these:
  8. int EV_Check(); //Check if any event is running. Uncommon. Only used in the Chaos 0 map and for the doors after Casinopolis in Tails' story.
  9. int EV_CheckCansel(); //Check if event conditions are running. (No HUD in stages etc.)
  10. int EV_CheckExec(int no); //Check if a specific event is running.
  11.  
  12. ///Script Functions:
  13. void EV_PadOn(); //Enable controls
  14. void EV_PadOff(); //Disable controls
  15. void EV_CanselOn(); //Enable event conditions. (Remove the HUD etc.)
  16. void EV_Msg(char* str); //Open a textbox. Note: Waits 20 Frames.
  17. void EV_MsgClose(); //Close a textbox. Note: Waits 20 Frames.
  18. void EV_MsgCls(); //Close text but don't close the textbox.
  19. task* EV_GetPlayer(int no); //Get Player [no]'s character's object.
  20. void EV_FreeObject(task** tp); //Delete an object.
  21. void EV_SetPos(task* tp, float x, float y, float z); //Set Position of a task.
  22. void EV_SetAng(task* tp, int x, int y, int z); //Set Rotation of a task.
  23. void EV_SetMode(task* tp, int mode); //Set Mode (Action ID) of a task.
  24. void EV_SetShadow(task* tp, float size); //Set shadow size of a task.
  25. void EV_SetColli(task* tp, float size); //Set collision size of a task.
  26. void EV_CreatePlayer(int n, void(* func)(task*), float px, float py, float pz, int ax, int ay, int az); //Create an NPC player character.
  27. void EV_RemovePlayer(int n); //Remove a player character.
  28. void EV_SetAction(task* tp, NJS_ACTION* ap, NJS_TEXLIST* lp, float speed, int mode, int linkframe); //Play an animation.
  29. void EV_SetMotion(task* tp, obj* op, NJS_MOTION* mp, NJS_TEXLIST* lp, float speed, int mode, int linkframe); //Event Library:Play an animation without a premade NJS_ACTION.
  30. void EV_ClrAction(task* tp); //Clear EV_SetAction/Motion commands.
  31. void EV_SetPath(task* tp, EPATHTAG* path, float speed, int mode); //Make an object follow a path.
  32. void EV_ClrPath(task* tp); //Clear EV_SetPath commands.
  33. void EV_LookFree(task* tp); //Clear Look commands.
  34. void EV_LookObject(task* tp, task* target, float x, float y, float z); //Focus a character's head on an object.
  35. void EV_LookPoint(task* tp, float x, float y, float z); //Focus a character's head on a point.
  36. void EV_LookAngle(task* tp, int x, int y, int z); //Rotate a character's head.
  37. void EV_MoveFree(task* tp); //Clear Move
  38. void EV_MovePoint(task* tp, float x, float y, float z); //Move a character to a point at a fixed speed.
  39. void EV_MovePoint2(task* tp, float x, float y, float z, float s, float a); //Move a character to a point at an adjustable speed and acceleration.
  40. void EV_MoveRotation(task* tp, int x, int y, int z); //Rotate a character.
  41. void EV_CameraOn(); //Create Event Camera
  42. void EV_CameraOff(); //Delete Event Camera
  43. void EV_CameraAng(int mode, int time, int x, int y, int z); //Set camera rotation.
  44. void EV_CameraPos(int mode, int time, float x, float y, float z); //Set camera position.
  45. void EV_CameraPosORY(char mode, int time, task* tp, float x, float y, float z); //Set camera position while orbiting an object.
  46. void EV_CameraTargetFree(); //Clear CameraTarget commands.
  47. void EV_CameraTargetPos(int mode, int time, float x, float y, float z, int az); //Make the camera look at a point.
  48. void EV_CameraTargetObj(int mode, int time, task* tp, float x, float y, float z, int az); //Make the camera look at an object from a position.
  49. void EV_CameraChaseFree(); //Clear CameraChase commands.
  50. void EV_CameraChase(task* tp); //Make the camera follow an object.
  51. void EV_CameraChaseRM(int mode, int time, task* tp, float height, int x0, int y0, int z0, float d0, int x1, int y1, int z1, float d1); //Make the camera follow an object while also running an animation (ROTMOVE).
  52. void EV_CameraPerspective(int mode, int time, int ang); //Set FOV.
  53. void EV_CameraPath(cpathtag* path, float speed); //Make the camera follow a path.
  54. void EV_SetFace(task* tp, const char* str); //Play a face animation.
  55. void EV_ClrFace(task* tp); //Reset a character's face.
  56. void EV_SerifStop(); //Stop a voice clip.
  57. void EV_Wait(int time); //Wait [time] Frames.
  58. void EV_MsgW(int time, char* str); //Display a message and wait.
  59. void EV_CreateObject(task** tpp, float px, float py, float pz, int ax, int ay, int az); //Create a generic object.
  60. void EV_CreateObjectFunc(task** tpp, task* (*func)(void), float x, float y, float z, int rx, int ry, int rz); //Create an object that has its own main/display functions.
  61. void EV_InitObject(task* tp); //Clear any existing Action/Path/Move/Face commands from a task.
  62. void EV_InitPlayer(int n); //Cleanup for the player before/after an event.
  63. void EV_WaitAction(task* tp); //Wait for a task to finish an Action command.
  64. void EV_WaitPath(task* tp); //Wait for a task to finish a Path command.
  65. void EV_PlayPad(int no, PADREC_DATA_TAG* tag); //Automated controller input
  66. void EV_WaitMove(task* tp); //Wait for a task to finish a Move command.
  67. void EV_SerifWait(); //Wait for a voice clip to end.
  68. void EV_SerifPlay(int id); //Play a voice clip
Advertisement
Add Comment
Please, Sign In to add comment