Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
SRB2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
STJr
SRB2
Commits
2bd794c0
Commit
2bd794c0
authored
6 years ago
by
Marco Z
Browse files
Options
Downloads
Patches
Plain Diff
Remove S_MusicExists lua
parent
e2e34598
Branches
Branches containing commit
Tags
Tags containing commit
2 merge requests
!488
Merge in next and don't billboard papersprites in GL
,
!447
MusicPlus core: Song length, positioning, and fading features with Linedef Exec and Lua support
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/lua_baselib.c
+0
-37
0 additions, 37 deletions
src/lua_baselib.c
with
0 additions
and
37 deletions
src/lua_baselib.c
+
0
−
37
View file @
2bd794c0
...
@@ -1899,42 +1899,6 @@ static int lib_sSpeedMusic(lua_State *L)
...
@@ -1899,42 +1899,6 @@ static int lib_sSpeedMusic(lua_State *L)
return
0
;
return
0
;
}
}
static
int
lib_sMusicExists
(
lua_State
*
L
)
{
boolean
checkMIDI
=
lua_opttrueboolean
(
L
,
2
);
boolean
checkDigi
=
lua_opttrueboolean
(
L
,
3
);
#ifdef MUSICSLOT_COMPATIBILITY
const
char
*
music_name
;
UINT32
music_num
;
char
music_compat_name
[
7
];
UINT16
music_flags
=
0
;
NOHUD
if
(
lua_isnumber
(
L
,
1
))
{
music_num
=
(
UINT32
)
luaL_checkinteger
(
L
,
1
);
music_flags
=
(
UINT16
)(
music_num
&
0x0000FFFF
);
if
(
music_flags
&&
music_flags
<=
1035
)
snprintf
(
music_compat_name
,
7
,
"%sM"
,
G_BuildMapName
((
INT32
)
music_flags
));
else
if
(
music_flags
&&
music_flags
<=
1050
)
strncpy
(
music_compat_name
,
compat_special_music_slots
[
music_flags
-
1036
],
7
);
else
music_compat_name
[
0
]
=
0
;
// becomes empty string
music_compat_name
[
6
]
=
0
;
music_name
=
(
const
char
*
)
&
music_compat_name
;
}
else
{
music_num
=
0
;
music_name
=
luaL_checkstring
(
L
,
1
);
}
#else
const
char
*
music_name
=
luaL_checkstring
(
L
,
1
);
#endif
NOHUD
lua_pushboolean
(
L
,
S_MusicExists
(
music_name
,
checkMIDI
,
checkDigi
));
return
1
;
}
static
int
lib_sStopMusic
(
lua_State
*
L
)
static
int
lib_sStopMusic
(
lua_State
*
L
)
{
{
player_t
*
player
=
NULL
;
player_t
*
player
=
NULL
;
...
@@ -2405,7 +2369,6 @@ static luaL_Reg lib[] = {
...
@@ -2405,7 +2369,6 @@ static luaL_Reg lib[] = {
{
"S_StopSound"
,
lib_sStopSound
},
{
"S_StopSound"
,
lib_sStopSound
},
{
"S_ChangeMusic"
,
lib_sChangeMusic
},
{
"S_ChangeMusic"
,
lib_sChangeMusic
},
{
"S_SpeedMusic"
,
lib_sSpeedMusic
},
{
"S_SpeedMusic"
,
lib_sSpeedMusic
},
{
"S_MusicExists"
,
lib_sMusicExists
},
{
"S_StopMusic"
,
lib_sStopMusic
},
{
"S_StopMusic"
,
lib_sStopMusic
},
{
"S_SetInternalMusicVolume"
,
lib_sSetInternalMusicVolume
},
{
"S_SetInternalMusicVolume"
,
lib_sSetInternalMusicVolume
},
{
"S_StopFadingMusic"
,
lib_sStopFadingMusic
},
{
"S_StopFadingMusic"
,
lib_sStopFadingMusic
},
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment