Commit Graph
230 Commits
Author SHA1 Message Date
Crash Cringleandteejusb 6d6dc86211 Ensure Group offset is always applied 2025-03-25 23:28:08 -07:00
Crash Cringleandteejusb 0270cda54d Add additional NULL checks just in case 2025-03-22 12:02:04 -07:00
Crash Cringleandteejusb 7d5a62a537 Add Group() for USB songs 2025-03-22 12:02:04 -07:00
Michael Votawandteejusb 81bc4067c7 Increment FILE_CACHE_VERSION 2025-03-19 23:19:00 -07:00
Crash Cringleandteejusb 4f0febb57c Rename DefaultSyncBias --> DefaultSyncOffset 2025-03-18 07:28:50 -07:00
Crash Cringleandteejusb 6b50f9a90c Rename MachineSyncBias --> DefaultSyncBias 2025-03-16 15:42:41 -07:00
Crash Cringleandteejusb 9529bfd142 Change MachineSyncBias prefs to an enum SyncBias, Changing this song triggers a reload of songs, added new option effect for reloading songs 2025-03-16 15:42:41 -07:00
sukibabyandteejusb 9787e01acf Add braces to Song::ReloadFromSongDir
The LOG->Warn line is being executed unconditionally due to the the lack of braces. The indentation is misleading as a result. This adds braces to ensure the intended behavior is performed.
2025-03-11 21:34:22 -07:00
Crash Cringleandteejusb c6ad4685a7 Add null checks for all ->GetGroup->getsomething calls 2025-03-09 10:05:01 -07:00
Crash Cringleandteejusb 8f6d5b44b9 Move sync offset application to song load (as early as possible) 2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb 53a26f2fa4 Add some nullptr handling 2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb ac767b3ce8 Move GetGroup to SONGMAN, rename variables consistently, move "pack.ini" to constant var, flip sync bias sign 2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb 835ca35065 Ensure the Group Offset is applied when Reloading a Song from Disk 2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb 5abaf5318a Move group into its own class, add Credit and AuthorsNotes fields, Begin exposing methods to lua 2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb 1aa44cacb6 Rename Pack -> Group for consistency. Remove leftover logging and extra lines from debugging.
Misc patches via PR review.
2025-03-03 23:25:32 -08:00
Crash Cringleandteejusb 5e6f3378a8 Thrown together Initial working implementation of pack.ini
# Conflicts:
#	src/MusicWheel.cpp
2025-03-03 23:25:32 -08:00
Michael Votawandteejusb fd790eb83e Replace #MEASUREINFO with two separate tags, #NPSPERMEASURE and #NOTESPERMEASURE. Stop storing MeasureInfo objects on Steps, and just directly store NpsPerMeasure, NotesPerMeasure, and peakNPS. 2025-03-03 21:24:17 -08:00
Michael Votawandteejusb ea35af311e Reset FILE_CACHE_VERSION to 228 2025-02-11 19:39:03 -08:00
Michael Votawandteejusb 905e44330a Added methods to load/write tech counts to cache. 2025-02-11 19:39:03 -08:00
Michael Votawandteejusb bd897b676a Replacing use of CalculateRadarValues with CalculateStepStats, and ReCalculateRadarValuesAndLastSecond with ReCalculateStepStatsAndLastSecond 2025-02-11 19:39:03 -08:00
sukibabyandteejusb e0b254968d std::size_t -> size_t
Removing std prefix from all size_t.
2024-10-01 01:46:26 -07:00
sukibabyandteejusb abf89ec2b1 Replace SAFE_DELETE / SAFE_DELETE_ARRAY macros
SAFE_DELETE -> RageUtil::SafeDelete
SAFE_DELETE_ARRAY -> RageUtil::SafeDeleteArray

Update JsonUtil.h to include RageUtil.h - MSVC doesn't need it included for some reason, but GCC and XCode does.
2024-09-30 15:13:32 -07:00
Michael Votawandteejusb be87de401a Added additional criteria to StepsCriteria and SongCriteria
Added new m_sSongName property to Song class
Slight refactor in Song::LoadSongFromDir() to set m_sSongName
Implemented the basics of #SONGSELECT course parameter
2024-03-06 01:45:26 -08:00
Martin Natano bacecae1f7 Decouple <vector> 2023-04-21 22:13:41 +02:00
Martin Natano 78fb2e9fc3 Decouple <cstddef> 2023-04-20 11:21:29 +02:00
Martin Natano b68ca517e6 Clean up math functions
- Remove checking for standard functions from the build system
- Prefix all invocations with std::
- Replace suffixed functions with unprefixed versions
- Include <cmath> in all files that use it and remove the global include

e.g. floorf(x) -> std::floor(x)
2023-04-19 19:31:40 +02:00
Michael SundqvistandMartin Natano 0cba3579de Remove global "using namespace std;" declarations, use "std::" prefixes on all std elements
Fix whitespace changes
2022-07-31 22:14:38 +02:00
teejusb 7e3789b131 Integrate C++11 branch into 5_1-new 2019-06-22 12:35:38 -07:00
Alexander GriffinandMrThatKid c0981c42ec Changing BannerCache into ImageCache to support more imagetypes (#1532) 2017-09-19 14:49:42 -07:00
KyzentunandColby Klein 2aee27a276 Backport custom song support. Prefs are CustomSongsEnable, CustomSongsMaxCount, CustomSongsLoadTimeout, CustomSongsMaxSeconds, CustomSongsMaxMegabytes. Metrics are NumProfileSongGroupColors and the colors with it. Profile custom load function is passed PlayerNumber now. Stepmania must run as root to save USB profile scores. (#1470) 2017-06-06 05:30:06 -07:00
Nickito12andColby Klein 6225e114ad Online protocol improvements (#1393)
* Chartkey generation

* Simfile filehash generation

* Read filehash on NSCRSG. Add FLU packets and friendlist vectors. Add
getserverversion method. Send chartkey, filehash and rate on start request.

* Use filehash to find the selected song if it is not empty.

* Friendlist update broadcast.

* Send note row size if it's bigger than 1

* Used for chartkey generation

* Define the ReportScore function with numNotes when WITHOUT_NETWORKING is defined
2017-02-10 04:57:59 -08:00
Kyzentun Keeslala 2a2007b9c8 Trim chart name, description, and credit after loading them from the simfile. 2016-06-29 19:33:36 -06:00
Kyzentun Keeslala bd3da6a46d Added GetMainTitle to Song to bypass ShowNativeLanguage pref. 2015-10-26 13:38:23 -06:00
Kyzentun Keeslala 337297f4b6 Changed blank music file check in Song::LoadFromSongDir to allow a blank music file if the song uses keysounds. The intent is to prevent bms files from triggering the condition, so they don't have to hit the song folder every time during loading. 2015-10-11 13:54:13 -06:00
Kyzentun Keeslala 2d64694f14 Changed Song and ScreenEdit to not save a .sm file when split timing is used. 2015-10-02 16:26:59 -06:00
Joe d3e866db26 Setting sample length for songs with preview file to 0 uses length of preview file 2015-05-15 15:46:20 +01:00
Kyzentun 2d9ea44d12 Song::TidyUpData now clears graphics fields that point to files that don't exist. 2015-04-27 07:48:50 -06:00
Kyzentun cf3c967a51 Allow songs with invalid characters such as # in the title to work by calling TidyUpData after loading. 2015-04-10 22:40:49 -06:00
Kyzentun 84b57e7ca4 Song::TidyUpData needs to happen after edits in the song folder are loaded so that their radar stuff will be calculated. Bumped cache version. 2015-04-07 12:47:51 -06:00
Kyzentun 5852067f47 Added RadarCategory_Notes. Rewrote NoteDataWithScoring stuff to only traverse the NoteData once, and match the radar code in NoteDataUtil. Fixed hand and lift counting in NoteDataUtil::CalculateRadarValues. Removed cap from RadarValues so that Stream, Voltage, Air, Freeze, and Chaos can be over 1.0. Fixed Stream and Voltage to not count hold heads twice. Changed SetRadarValues in NotesLoaderSSC to not require the stepfile version number. 2015-04-06 18:45:23 -06:00
Kyzentun 2b4cabfb57 Added keybinding for reloading songs on SSM, and lua function for doing it from lua. Added NeverCacheList preference for WIP groups that should never be cached. Rewrote TimingData::CopyRange in preparation for using it to copy/paste timing data from the selected area in edit mode. 2015-03-31 15:20:37 -06:00
Kyzentun 8b09da8e64 Various changes to speed up start up time:
Added delay_save_cache to SongCacheIndex so that it doesn't write the entire cache index file after every song is loaded when loading songs.
Added m_SongsByDir to SongManager so that GetSongFromDir doesn't have to walk the entire list of songs.
Minor changes to when LoadEnabledSongsFromPref occurs and how SanityCheckGroupDir works to speed up loading.
Song::ReloadFromSongDir removes cache file to force an actual reload from the song dir instead of reloading from the cache.  ReloadFromSongDir exposed to lua.
Reordered Actor::LoadFromNode to put Command first because that case is more common.
Course::GetTrailUnsorted reserves entries before starting to save time reallocating.
join in RageUtil calculates the final size of the concatenated strings reserves it to save time reallocating.
Added time log file to RageLog for profiling.
2015-03-30 17:45:52 -06:00
Kyzentun 31ce1c7b39 Moved more things to happen only when a song isn't cached. Song::TidyUpData now only fetches a list files in the song dir once, instead of several times. 2015-03-24 12:05:41 -06:00
Kyzentun a2798e16f4 More aggressive caching. In general, this makes Stepmania avoid looking in the song directory at all if the song is in the cache, in order to load songs faster. All the RadarValue calculations were also rolled into one to reduce the time needed to build the cache. 2015-03-23 11:35:30 -06:00
Kyzentun 3140c4f30f Changed preview length setting to occur when the special preview file is set in edit mode. 2015-03-11 18:55:06 -06:00
Kyzentun ddb1683bb7 Autosave completed but not tested. 2015-03-09 19:47:44 -06:00
Kyzentun 064aead73c Added autosave to edit mode. 2015-03-09 19:47:43 -06:00
Kyzentun fa0478affa Merged per-chart music. Updated changelog. 2015-03-09 19:06:57 -06:00
Kyzentun ebb79d0ea6 Use cached song length instead of hitting the disk to read the music file. 2015-03-04 18:54:57 -07:00
Kyzentun 46d215aed3 Added preview tag to NotesLoaderBMS. Changed Song to check the preview file for sample length instead of the simfile if the preview file is set. 2015-03-04 13:10:51 -07:00