• Do not use Works in Progress as a way of avoiding the releases system! Works in Progress can be used for sharing early betas and for getting suggestions for improvement. Releases of finished content are not allowed in this forum! If you would like to submit a finished addon, click here for instructions on how to do so.

Chain Spawnpoint / Parameters

Status
Not open for further replies.

sluggard

Formerly "RomioTheBadass"
I was about to implement some swinging chains to my level and realized they don't work the same way they did in 2.1, how does the new Linedef Type 9 work?
 
Code:
****
* Mace point mapthings have been slightly modified.
   - MTF_AMBUSH: bigger luke theory (has no effect on custom mace, different effect on spring mace)
   - MTF_OBJECTFLIP: flips the objects, but nothing else - just so it doesn't look out of place in gravflip sections
   - MTF_OBJECTSPECIAL: keeps it from attempting to play swinging sounds
   - angle: tag of controlling linedef
   - parameter: number of "spokes" minus one - for example, a parameter of 2 results in 3 equidistant maces rotating around the same point.
****
* Mace linedefs have been significantly revamped.
   - line dx: number of chain links
   - line dy: speed (in FU)
   - frontside floor height: Pitch (in degrees; how much it "tilts" over - Yaw influences the axis it's tilting on)
   - frontside ceiling height: Yaw (in degrees; rotation of entire thing on xy plane)
   - frontside x offset: Phase (in degrees; how far it is through the rotation cycle)
   - frontside y offset: "Minimum chainlink distance" setting - if less than zero, the absolute of that many chainlinks will not be spawned from the center outwards, for if you want stuff to not be in a wall. Doesn't affect the head of the chain at all, since otherwise what's the point? :V
   - backside floor height: Pinch (in degrees; 0 if no backside; essentially makes rotation conical instead of wheel-like)
   - backside ceiling height: Roll (in degrees; 0 if no backside; rotates on the axis of the spinning - identical to Phase for spinning maces, but useful for rotating swinging maces as opposed to just offsetting them)
   - backside x offset: Number of "antispokes" (0 if no backside; makes that many spokes not exist so you can put another mace/chain type in there instead; for combo mace/chain instead turns them into chains directly)
   - backside y offset: Width (in number of extra chains per side; 0 if no backside; creates a "skiprope" arrangement)

   - ML_NOCLIMB: for chains and chain-mace combos, allow for player control of yaw through strafe keys
   - ML_EFFECT1: replacing the seperate mapthings, this makes a mace type swing instead of spin.
   - ML_EFFECT2: for all spokes of the mace wheel ending in maces, make the chains out of the mace type (inverted for firebars)
   - ML_EFFECT3: spawn a bonus mace type at the center(s) of rotation
   - ML_EFFECT4: don't clip inside ground
   - ML_EFFECT5: always think/visible (maces without this have a pop-in distance effect)
****
* Mapthing 1104 represents both spinning and swinging maces from prior versions of SRB2.
* Mapthing 1105 has gone from being a swinging mace variant to a combination of chains and maces in a single unit, provided the number of "spokes" is greater than one.
* Mapthing 1105 has gone from being a swinging chain variant to a vertical spring-on-a-ball-on-a-chain. Yellow by default, apply MTF_AMBUSH to turn into a red spring.
* Mapthing 1107 represents both spinning and swinging chains from prior versions of SRB2.
* Mapthing 1108 (hidden sling) is completely untouched except to port over 2.1's functionality to the new backend.
* Mapthing 1109 is a Mario castle-level style firebar. This inverts the functionality of ML_EFFECT2 on the tagged linedef.
* Mapthing 1110 is a free slot should we want to implement another type of base-game mace.
* Mapthing 1111 is a custom mace. Use the linedef's frontside texture slots to identify a macetype mobjtype, then use the backside texture slots to identify a linktype mobjtype (defaults to MT_NULL if no backside).
****


I provided this info to help get the wiki updated, but it turns out it hasn't happened yet. Hope this helps! ^u^
 
from where i can see the x and y distance????????????
While this thread is old, I'll answer it for the sake of being helpful.


The X and Y distance can be measured by calculating relative vertex positions. For example, if you have one vertex of a line at (768, 2048) and another at (784, 2080), the X distance would be 16, and the Y distance would be 32. How do I know this? Simply put, you'll have to find the difference between the two points, which would be ((v2x - v1x), (v2y - v1y)), with v1 being Vertex 1, and v2 being Vertex 2. Plugging in the numbers, 784-768 would be 16, and 2080-2048 would be 32. In the context of chain parameters, this would equal 16 chain links, and 32 fracunits/tic of speed.
 
Last edited:
uh okaaaay, but i already got, it sorry if i haven't mentioned it

i just tried to make control sector lesser and smaller and boom!
the chain wasn't that hyper fast or super long, i realized then that i can adjust control sector on the x axis, and change the amount of chains,
same thing for speed, just adjusting control sector on the y axis, and the speed will change
 
Last edited:
Actually nar, it's easier than that to get the x and y distances. just use the linedef length of the line between vertices 1 and 2. the up and down line would be for Y and the left and right line for X.
 
Status
Not open for further replies.

Who is viewing this thread (Total: 0, Members: 0, Guests: 0)

Back
Top