Commit graph

285 commits

Author SHA1 Message Date
Sunk
9acb632b8e
Fix HOOK_ALLOW_HAZARD_SURFACE and expose SURFACE_IS_* macros (#865)
* Fix HOOK_ALLOW_HAZARD_SURFACE

* Peachy's suggestions

* Exposed `surface_is_*` macros
2025-06-24 22:15:27 +02:00
Isaac0-dev
8f1830b079 cleanup old gfx symbol management code 2025-06-14 14:58:55 +10:00
PeachyPeach
c79d59d8ec
Fix vec3f bugs (#837) 2025-06-05 19:44:09 +10:00
PeachyPeach
69e129805e
More math improvements (#820)
* More math improvements

* more math functions

* stack check

* added error message when trying to modify read-only table; fix gSmluaConstants printed to console
2025-05-29 02:52:31 +02:00
PeachyPeach
bbabaa3c79
Fix hand/foot pos and get any Mario part position (#816)
Some checks are pending
Build coop / build-linux (push) Waiting to run
Build coop / build-steamos (push) Waiting to run
Build coop / build-windows-opengl (push) Waiting to run
Build coop / build-windows-directx (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
* Fix hand/foot pos and get any Mario part position
2025-05-21 23:52:04 +02:00
PeachyPeach
8db6356754
Improving math functions (#813)
* Improving math functions

* Isaac review
2025-05-21 23:50:49 +02:00
Prince Frizzy
02c9a4146b
More Optimizations (#792)
* Initial work on optimizations.

* Requested Changes Part 1

* Requested Changes Part 2

* Requested Changes Part 3

* Requested Changes Part 4

* Requested Changes Part 5

* Requested Changes Part 6

* Update deprecated.lua

---------

Co-authored-by: PeachyPeach <72323920+PeachyPeachSM64@users.noreply.github.com>
2025-05-16 20:27:49 -04:00
Isaac0-dev
5cb2296710 make extract_display_lists.py consistent across platforms
Some checks failed
Build coop / build-linux (push) Has been cancelled
Build coop / build-steamos (push) Has been cancelled
Build coop / build-windows-opengl (push) Has been cancelled
Build coop / build-windows-directx (push) Has been cancelled
Build coop / build-macos-arm (push) Has been cancelled
Build coop / build-macos-intel (push) Has been cancelled
2025-05-10 13:30:06 +10:00
Agent X
8ef8712237 Add gsSPLoadGeometryMode to DynOS
Some checks are pending
Build coop / build-ubuntu (push) Waiting to run
Build coop / build-windows (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
2025-05-03 18:09:42 -04:00
jayden
af6e0afbcf
change misleading switch case field label (#781) 2025-05-02 13:33:36 +02:00
PeachyPeach
507e6f6102
Fix autogen documentation (#769)
* Fix autogen documentation

* verbose
2025-04-27 17:24:29 -04:00
Prince Frizzy
15d6f6ae07
Add some sanity checks to prevent bugs and exploits. (#767)
* Add some sanity checks to prevent bugs and exploits.

* Improve sanity check for Koopa Shell Riding.

* Sort and optimize MarioState structure.
2025-04-27 17:02:15 -04:00
Agent X
bf85d9f9d5 Lay some groundwork for more documentation, fix compilation error, put backgrounds into enum 2025-04-26 23:29:21 -04:00
ManIsCat2
29f9e7cfcb
Add G_PACKED_NORMALS Geo Mode from F3DEX3 (#768)
Some checks are pending
Build coop / build-ubuntu (push) Waiting to run
Build coop / build-windows (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
* Add new geometry mode

* Fix lua vertex colors not working
2025-04-25 15:07:31 -04:00
Agent X
0cb0b41c07 Add some level commands to make porting HackerSM64 levels easier
Some checks are pending
Build coop / build-ubuntu (push) Waiting to run
Build coop / build-windows (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
2025-04-14 19:25:05 -04:00
PeachyPeach
467b22e939
Gfx set command: v2 + Gfx/Vtx dynamic alloc (#718)
Some checks failed
Build coop / build-ubuntu (push) Has been cancelled
Build coop / build-windows (push) Has been cancelled
Build coop / build-macos-arm (push) Has been cancelled
Build coop / build-macos-intel (push) Has been cancelled
* set_gfx_command part 2

* part 3

* get gfx/vtx from name; copy gfx/vtx

* gfx/vtx dynamic allocation lua

* gfx/vtx_new: don't take level/model/vanilla names

* Clean up gbi constants

* update example

* Isaac review; add gfx_get_next_command and vtx_get_next_vertex

* make all commands length 1; missing NULL checks
2025-04-12 18:19:14 -04:00
Agent X
e1c0d87ea8 Add some missing gfx symbols to DynOS
Some checks are pending
Build coop / build-ubuntu (push) Waiting to run
Build coop / build-windows (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
2025-04-08 17:30:00 -04:00
Isaac0-dev
56577a4a20 fix some read only display lists missing from display_lists.inl
Some checks are pending
Build coop / build-ubuntu (push) Waiting to run
Build coop / build-windows (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
2025-04-08 12:54:08 +10:00
PeachyPeach
b190ee09fb
Gfx Vtx vanilla only duplicates (#733)
Some changes for gfx vtx duplication:
- Only vanilla (read-only) stuff is duplicated
- Stuff is duplicated only once, and uses a map rom->ram for next iterations
- Stuff is restored to original values on network shutdown

also fixes incorrect types in some extern declarations
2025-04-08 10:20:50 +10:00
Agent X
0ee8d5f81e Fix/optimize/improve lighting engine 2025-03-28 23:06:48 -04:00
Agent X
3e540790a3
Basic Vertex Point Lighting Engine (#716)
* CONCEPT: Basic vertex lighting engine

Set the geometry mode on your model to G_LIGHTING_ENGINE_EXT, spawn a `bhvAmbientLight`, spawn some `bhvPointLight`s, and then you got yourself a mighty interesting scene.

* Fixes

* How did I miss this

* Make light set home pos
2025-03-27 16:36:02 -04:00
Baconator2558
c26e968076
Allow wind to be ignored with HOOK_ALLOW_HAZARD_SURFACE (#721)
* Update constants.md

* Update constants.lua

* Update smlua_constants_autogen.c

* Update surface_terrains.h

* Update hooks.md

* Add files via upload
2025-03-27 14:48:36 -04:00
Agent X
3792f0aebb Raise custom object fields limit from 16 to 64 2025-03-13 22:09:46 -04:00
Isaac0-dev
d6e243c4a7 add obj_get_model_id_extended, remember regular model ids 2025-03-04 15:09:09 +10:00
Isaac0-dev
f238b3d0f5
allow Lua to manipulate displaylists and vertices (#675)
Co-authored-by: ManIsCat2 <137772623+ManIsCat2@users.noreply.github.com>
2025-02-27 14:27:55 +10:00
Isaac0-dev
75b71e9b4d fix nametags and collisions with mirror mario 2025-01-19 13:46:28 +10:00
Isaac0-dev
9ddc7311f1 cleaner fix for headPos bug nametags 2025-01-07 07:56:19 +10:00
PeachyPeach
96932f5bf1
Custom geo function and switch nodes with Lua callback (#593) 2024-12-31 10:23:13 +10:00
jayden
1291350bed
Add hooks to graph node processing (#587)
* geo process hooking

* autogen update!
2024-12-27 22:07:31 -05:00
Agent X
66e23c0cbf Document behavior headers (54.07%) 2024-12-08 18:12:04 -05:00
Sunk
947ce9f080
Rework PvP Balance (#357)
* PvP Rework

This rearranges the damages of last PR. The underused attacks should still see some buffs.

* Adjust how punches apply invincibility

Also increase punch invincibility timer to 12

* EmeraldLoc's easy suggestions

* Rework punching pvp

Punching no longer reduces invincibility frames. Instead, punches can ignore knockback invincibility and the full punch punch kick combo can be done.

* Adjust numbers

Breakdances should not deal 3 damage

* Potential fix for more common tripping

"Trip" here refers to 1 damage kicks

* Add temporary invincibility to rollouts

This is a test to see how different pvp feels with this change. Suggestion by sausrelics.

* Fix invincibility

* Prevent low damage/low knockback kicks altogether

* Update ignored attack list

* Allow dives to be attacked by most actions

A lot of people don't want dives to be entirely invincible and some suggested to make dives be able to only pierce through jump kicks

* Slightly nerf kick knockback

Suggestion by emily

* Rework dive piercing

Instead of all actions being able to hit dives other than jumpkicks, now only slidekicks (and ground pounds) can hit dives.

* Mild kick knockback increase from nerf

* Change direct equality to checking flag

* Decrease dive and punch knockback

* Prevent trades against dives with slidekicks

* Revert "Prevent trades against dives with slidekicks"

This reverts commit 2a2c3266a7.

* Allow ground pounds to always hit a sliding player

* Add server setting to change pvp

* Add pvp settings to config

* Add selection to menu

* Fix issues + autogen

* Rewrite goto statement to not use goto
2024-11-25 20:48:40 +10:00
Drahnokks
636b385e48
add controller.buttonReleased (#379) 2024-10-20 09:25:08 +10:00
Agent X
81c4180a06 Remove Waluigi anims 2024-07-01 18:32:27 -04:00
Agent X
c144ff6780 Remove unused Waluigi animation 2024-06-30 17:46:18 -04:00
Agent X
f629f2ab21 Fix cut off Luigi line 2024-06-27 16:54:20 -04:00
Agent X
8831360153 Fix let's a go & okie dokie character sounds 2024-06-27 11:09:28 -04:00
Isaac0-dev
eaeaeb0f7f
add a way for mods to get dynamic surfaces that belong to specific objects (#59)
Adding this for collision minimap, but I'm sure it'd be useful for many other mods that deal with collision in this kind of way

exposes a function, obj_get_surface_from_index. pass in an object, and the index of the surface you want. numSurfaces is also added to know when to stop iterating through surfaces

Thanks to peachy for coming up with the better method of doing this

Co-authored-by: PeachyPeach <72323920+PeachyPeachSM64@users.noreply.github.com>
2024-06-06 17:24:28 +10:00
Agent X
ceb7aa4649 Palette system overhaul and preset rewrite 2024-05-21 17:09:59 -04:00
Isaac0-dev
6995b1a07c
revert texture coordinates as ints instead of shorts (#46)
This reverts commit f994ffbe8c.
2024-05-15 21:30:52 +10:00
Isaac0-dev
eaa1a59996
fixed some mario cutscene action related bugs (#43)
- fixed a bug where remote players would show mario's head repeatedly twitching up and down while reading automatic dialog
- fixed a bug where remote mario's would sometimes not update while unlocking a star door, resulting in the previous animation playing during that action
- fixed a bug where players exiting a warp door could get stuck for a few extra frames due to other players opening that same door.

- added dialogId to MarioState, which is synced for remote players the dialog id that player has active. this can be used by Lua mods - don't access the local player's dialog id because that isn't updated as that is unnecessary
2024-05-14 09:45:33 +10:00
PeachyPeach
14cbb673fc
Proper custom object fields (#39) 2024-05-14 08:52:56 +10:00
Isaac0-dev
1e4e1f8e75
fix bugs caused by interpolating the frame an object spawns (#36) 2024-05-11 08:28:20 +10:00
Agent X
a6b938df75 Shorten include paths by removing unnecessary "src/" 2024-04-17 17:28:38 -04:00
Agent X
f994ffbe8c Make texture coordinates use ints instead of shorts 2024-04-16 19:33:23 -04:00
Agent X
fd96946962 Remove DirectX 12 2024-03-30 23:57:18 -04:00
Isaac0-dev
974577f678
djui player menu custom camera cutscene (#2) 2024-03-28 18:53:46 -04:00
PeachyPeach
2a36b14dcd Remove OMM Rebirth temporary fixes (#542) 2024-03-25 18:35:25 -04:00
Isaac0-dev
4473bfffe9
removed bass, replaced with miniaudio (#8) 2024-03-23 16:14:53 -04:00
Isaac0-dev
663e4549d8
extract assets from rom at runtime (#4)
* Proof of concept for loading rom assets at runtime

* Added skybox textures

* Adjusted format

* Load all texture assets from rom

* Adjusted rom asset loading

* Load all Vtx lists from rom

* clean up toad, wario and his cap conflicts

* Load sound samples from rom

* fix toad sounds

* Loaded sequences from rom

* Load collisions from rom

* Object animations are now loaded from the rom

* Load player animations from rom

* Load goddard anims from rom

* whoops

* fix some compile errors

* drag and drop rom checker, everything works now.

* fix errors due to merge conflicts

* fix compile errors on windows, switch to md5

* fix vertex colors during load

Co-Authored-By: Agent X <44549182+agent-11@users.noreply.github.com>

* Load dialogs from rom

* Loaded course/act names from rom

* Loaded ingame text from rom

* rerun autogen & blacklist smlua_text_utils_init

* fix ttc_seg7_vertex_0700B238 colors

---------

Co-authored-by: MysterD <myster@d>
Co-authored-by: Agent X <44549182+agent-11@users.noreply.github.com>
2024-03-23 16:11:30 -04:00
Agent X
37cfd9ae04 Tidying up 2024-01-01 14:43:34 -05:00