Search results for query: *

  1. Zipper

    SRB2 Add-ons, and GPL-compliance.

    The linux kernel has a line that specifically excludes system calls from being part of the GPL license. I don't have any strong opinions on this matter as I don't see GPL mattering outside of genuine legal issues, but it's worth pointing out.
  2. Zipper

    Uninspired mods nowadays?

    Seeing a character mod with a full set of sprites (that is over 170 by the way), alongside unique gameplay mechanics ESPECIALLY in Takis' case, playing them, and then calling it "lazy character making" sure is...a take. I'll try to interpret your message as generously as possible and assume you...
  3. Zipper

    How does "end" work in lua?

    There is no end with the bracket. You might be thinking of the time when you put an entire function in an addHook. addHook("ThinkFrame", function() print("test") end) This is a scenario where a bracket might follow an "end". The bracket is part of the function, not the code block itself...
  4. Zipper

    How does "end" work in lua?

    it's used to "close" every block you start. --end closes "if" blocks if (something) then end --end closes "if-else" blocks if (something2) then else end --end closes function blocks local function test() print("henlo stinky") end --end closes for-loops for val in pairs(sometable) do...
  5. Zipper

    I don't know how to create particles

    https://wiki.srb2.org/wiki/Custom_Object_tutorial Shows you how to create an object. It's in SOC, but you just need to know the overall knowledge. https://wiki.srb2.org/wiki/Lua/Freeslots_and_Object_resources Shows you how to do that same thing but in Lua code. Since SOCs are loaded after...
  6. Zipper

    A Lua Glossary For Starters

    Wanted to build a site that focuses on teaching the basics of SRB2 Lua in a concise and accessible manner, while giving examples that could also be used in an actual mod, so that they don't feel superfluous and actually teach the readers something. It's currently sort of barebones due to me...
  7. Zipper

    how to remove rings

    Rings haven't been tied to player.mo.health for a long time. Deduct from player.rings instead.
  8. Zipper

    Official Level Design Collab 2023: Round 2

    Okay I'm geriatric and can't figure out how to add inline media without uploading them to another site first, so I'll just attach all points of interest I could find on a repeat playthrough. Mostly my issue with the decor is "things that seem helpful but aren't" (first two screenshots) or "is...
  9. Zipper

    Official Level Design Collab 2023: Round 2

    Sheesh, 31 levels. I don't even remember if I was around for an OLDC this big. Great work to everyone involved, though! I can tell all of these levels were created with intent to impress. Gonna leave my thoughts on each level as a few bullet points if any of you are looking for feedback...
  10. Zipper

    the visual´s lua problem

    Well, you can simply ignore the button press check if the player's already in the S_PLAY_FALL state. Though if you're looking for a more general purpose solution, I've provided an answer to a similar problem here https://mb.srb2.org/threads/lua-help-button-wise.40736/post-629429 It involves...
  11. Zipper

    How to make an upwards thrust

    local function ThrustUp(player) P_SetObjectMomZ(player.mo, 12*FRACUNIT, false) return true end addHook("AbilitySpecial", ThrustUp) Don't bother with SOC actions when Lua already has a function that does (approximately) the same thing. P_SetObjectMomZ makes the player launch up at a...
  12. Zipper

    Lua help (button wise)

    If you get an error about an "unexpected symbol", it usually means you wrote something wrong: bad variable name, unclosed brackets, unclosed "if" statements etc. Protip : Whenever you write an "if" statement, ALWAYS put the "end" to close it before you start writing the middle. It's like...
  13. Zipper

    Lua help (button wise)

    There is no direct way to check if a button is simply being pressed instead of held. You can, however, increase a counter whenever the button is held, and reset it when released. local function Test(p) if not (p.counter) then p.counter = 0 end if (p.cmd.buttons & BT_CUSTOM1) then...
  14. Zipper

    Help with Spinning Movement

    Okay, THAT part I can't explain. I've tried playing with thrustfactor/acceleration as well and it did not affect forward speed at all. If someone more knowledgeable with the source comes up I'd love to hear it.
  15. Zipper

    Help with Spinning Movement

    The game does not disable forwards movement. However, it DOES significantly gimp thrustfactor / acceleration so that gaining speed is essentially impossible. You can sort of circumvent it by copying the 3D Movement function in the source and removing restrictions on it. addHook("PlayerThink"...
  16. Zipper

    How to use a shield's ability without the shield part in Lua

    I don't believe there is a way to play those effects directly without re-writing them yourself. You could try to store the player's current shield, force them to press spin in the PreThinkFrame and restore their shield after the ability activates, but that would be EXTREMELY easy to mess up...
  17. Zipper

    Midair Dash LUA Fix Needed

    Please indent your code. //Hammer Leap addHook("AbilitySpecial", function(player) if player.mo.skin == "foof" if player.pflags & PF_THOKKED return false end local actionspeed = FixedMul(player.mo.scale, 12*FRACUNIT) if player.mo.eflags &...
  18. Zipper

    Problem with toggling transparency on sprite objects

    To check if the frame has FF_TRANS70, use "mobj.frame & FF_TRANS70" instead of "mobj.frame == FF_TRANS70" (Similarly, add a "not" to the start to see if it DOESN'T have it). As it is, I'm assuming the equality check only works for the first frame, since A|FF_TRANS70 is the same thing as FF_TRANS70.
  19. Zipper

    How does ThrustFactor work in the air?

    https://git.do.srb2.org/STJr/SRB2/-/blob/next/src/p_user.c#L6007 You might want to examine the 3D movement code in p_user.c, linked above. From what I can deduce, the amount of "push" you can provide is divided by a constant regardless of your thrustfactor, depending on if you're in the air...
Back
Top