lachablock
0405b3922c
Do not let nonspin characters enter sectors they could not enter if standing at full height
2021-03-23 15:09:04 +11:00
SMS Alfredo
4430835a71
This might be dumb, but whatever
2021-02-14 20:49:03 -06:00
LJ Sonic
70850b0836
Deprecate P_AproxDistance for Lua scripts
2021-02-13 18:04:27 +01:00
LJ Sonic
758de501da
Use R_PointToDist2 for the Lua versions of P_AproxDistance and FixedHypot
2021-02-13 18:04:12 +01:00
LJ Sonic
a58df577fe
Revert "Use FixedHypot over P_AproxDistance"
...
This reverts commit c5474436af
.
2021-02-13 17:46:29 +01:00
LJ Sonic
83947d4428
Merge branch 'redundant-hypot' into 'next'
...
Replace P_AproxDistance with FixedHypot, and replace FixedHypot's algorithm with R_PointToDist2's
See merge request STJr/SRB2!1320
2021-01-25 18:08:25 -05:00
Nev3r
b642682dde
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into lua-tag-iterator
...
# Conflicts:
# src/doomtype.h
2020-12-16 17:27:44 +01:00
Sally Coolatta
c5474436af
Use FixedHypot over P_AproxDistance
...
Not convinced that the small speed benefit from P_AproxDistance is worth the "aproximate"[sic] results it gives. Let's instead try a define to replace it with FixedHypot. In Lua, the function gives a deprecated warning.
Inspired by the hyperwall fix for vanilla, except for everything. From little testing, actively improves waypoint checks, bumping, speed checks, wall collisions, Jawz targetting, Lightning Shield attacks, so on.
The only way I see this as a potential downgrade is A_Look (and related functions) getting slower, which are barely used in Kart.
2020-12-12 14:49:25 -08:00
James R
8dd964e3a7
Lua: taglist.add and taglist.remove for sector tag lists
2020-12-05 02:02:06 -08:00
James R
314fd2783a
Lua tag lists
...
Index and take length of tag lists like a table, 1-indexed. There are three
methods which may be used on tag lists:
list:iterate() - returns an iterator over the tags in the list
list:has(tag) - returns a boolean whether the tag is in the list
list.shares(list2) - returns whether two lists share a tag
"find" is also an alias to "has". Each method may be accessed from the global
taglist library too, e.g. taglist.iterate(list)
Tag lists may be compared with an equality operator too. This will tell you if
the two lists are composed of identical tags.
Accessible from sector.taglist, line.taglist and mapthing.taglist.
2020-12-04 13:53:27 -08:00
Steel Titanium
7d45a7c91a
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into lua-skinsprites
2020-12-03 17:29:08 -05:00
Jaime Ita Passos
5e890ee6f8
Merge branch 'next' into spritestuff2
2020-11-19 00:52:43 -03:00
James R
50e15840fb
Merge branch 'udmf-multitag' into 'next'
...
UDMF: Multitag support
See merge request STJr/SRB2!1097
2020-11-14 19:18:14 -05:00
Nev3r
fb9432ae57
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into udmf-multitag
2020-11-10 11:46:53 +01:00
Steel Titanium
050a22f1ce
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into lua-musicfuncs
2020-11-08 21:20:07 -05:00
Louis-Antoine
9f851dc285
Return explicitly when failing to register a metatable
2020-11-09 00:16:40 +01:00
Louis-Antoine
e52cb7f6fa
Throw an error if too many metatables are registered
2020-11-08 17:20:25 +01:00
Steel Titanium
1320f10839
Allow access to skin.sprites[]
...
Only numframes so far though, as there's already a function for what spriteframe provides.
2020-11-07 23:55:37 -05:00
Jaime Passos
36550725f3
P_DeleteFloorSpriteSlope -> P_RemoveFloorSpriteSlope
2020-11-05 00:42:14 -03:00
Steel Titanium
ac7781a3b3
Expose more music functions to Lua
2020-10-31 21:15:41 -04:00
Louis-Antoine
1155d875d5
Use the same names as userdataType() for userdataMetatable()
2020-10-30 15:00:13 +01:00
Louis-Antoine
f943f247af
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2.git into register-metatables
2020-10-30 14:46:04 +01:00
Nev3r
c62ef355ef
Merge branch 'next' of https://git.do.srb2.org/STJr/SRB2 into udmf-multitag
...
# Conflicts:
# src/lua_baselib.c
# src/lua_maplib.c
2020-10-27 20:48:25 +01:00
James R
bd9fda8ceb
Merge branch 'lua-polyobjects' into 'next'
...
Lua polyobjects
Closes #19
See merge request STJr/SRB2!1140
2020-10-15 19:08:54 -04:00
Jaime Passos
e63efdac13
Only create floor sprite slopes when needed, instead of always allocating them.
...
Has to be done manually in Lua. Use P_CreateFloorSpriteSlope, and P_DeleteFloorSpriteSlope when done with it.
2020-10-14 13:07:02 -03:00
James R
9538ca696a
Merge branch 'ceilingz' into 'next'
...
Add P_CeilingzAtPos function
See merge request STJr/SRB2!1164
2020-10-12 17:44:51 -04:00
James R
ddb6823fe5
Merge branch 'fix-theoretical-lua-exposure-crashes' into 'next'
...
Fix some theoretical crashes when using the P_*XYMovement, P_*ZMovement, and P_RailThinker functions in Lua.
See merge request STJr/SRB2!1173
2020-10-08 22:01:02 -04:00
James R
c3c34c489b
Merge branch 'lua-sectorsounds' into 'next'
...
Support sectors as sound origins in Lua
See merge request STJr/SRB2!1144
2020-10-08 21:05:01 -04:00
GoldenTails
2ae5c02050
Fix some theoretical crashes when using the P_*XYMovement, P_*ZMovement, and P_RailThinker functions.
2020-10-03 13:24:47 -05:00
Louis-Antoine
e49032eaf7
Let Lua scripts access userdata metatables
2020-10-03 18:40:37 +02:00
Louis-Antoine
121c7da809
Let Lua scripts relink tables to their metatables when unarchiving
...
This is done through the new "registermetatable" function,
in a somewhat similar fashion to "freeslot" but for metatables:
it must be called at script load to tell SRB2 your metatable
can be automatically relinked during the unarchiving process.
2020-10-03 16:31:04 +02:00
Snu
82ceddb2be
god damnit
2020-09-30 08:10:28 +01:00
Snu
feb011ee52
Expose function to Lua
2020-09-30 07:58:41 +01:00
Tatsuru
013714a26f
Encapsulate userdata checks
2020-09-14 17:33:26 -03:00
Tatsuru
454682df70
Use the sector's actual soundorg (how did it even work)
2020-09-13 13:54:43 -03:00
Tatsuru
782e559adf
Check for sector_t userdata as well
2020-09-13 12:33:18 -03:00
Monster Iestyn
097986b1d9
added polyobj_t to userdataType list
...
(also added slope_t, vector2_t and vector3_t since they were all missing from here)
2020-09-09 21:24:07 +01:00
Zachary McAlpin
e5b6d19f57
Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2 into playercmd-kart-port
2020-07-30 15:37:41 -05:00
Nev3r
c914ac99b4
Bring back P_FindSpecialLineFromTag() for backwards compatibility reasons; emulate the old taglist behavior for this function.
2020-07-29 17:26:43 +02:00
Nev3r
c65ada7dd7
Merge branch 'next' into udmf-multitag
...
# Conflicts:
# src/hardware/hw_main.c
2020-07-29 13:55:14 +02:00
Nev3r
6dfe236602
Merge branch 'udmf-next' into 'next'
...
Merge udmf-next into next
See merge request STJr/SRB2!1075
2020-07-28 14:03:59 -04:00
Zachary McAlpin
117943012a
Merge branch 'next' of https://git.magicalgirl.moe/STJr/SRB2 into playercmd-kart-port
2020-07-25 20:06:12 -05:00
James R
6fd9e25b11
Merge remote-tracking branch 'origin/next' into g_findmap-lua
2020-07-24 02:14:03 -07:00
lachwright
cea3f64c88
Fix default NiGHTS skin brightness for non-super characters
2020-07-20 22:24:16 +08:00
Zachary McAlpin
d26c7654ff
Ported Lat's PlayerCmd hook to vanilla SRB2
2020-07-17 00:08:38 -05:00
James R
34bd0d9fe7
Merge branch 'various-color-fixes' into 'next'
...
Various color fixes
See merge request STJr/SRB2!1060
2020-07-13 18:24:55 -04:00
GoldenTails
ada06910dc
Expose P_MovePlayer to Lua.
2020-07-12 18:02:50 -05:00
GoldenTails
4b3d6f04f8
Expose P_PlayerZMovement to Lua.
...
Finishing off these changes; how a player moves vertically.
2020-07-12 18:02:50 -05:00
GoldenTails
df1fd0c456
Expose P_SceneryZMovement to Lua.
...
Still more complex than P_RingZMovement.
2020-07-12 18:02:50 -05:00
GoldenTails
4710e4f07c
Expose P_RingZMovement to Lua.
...
Ever wanted to move like a ring vertically?
2020-07-12 18:02:50 -05:00