Square "surface" platfrom effect by IKRA#2825

This code is over 6 months old. The code may have expired and might no longer function.

If you ever want to create a flat surface like wall, or platform you could start with this.
Easy to understand the math, all rules described inside.
This one could be used for creating horizontal surfaces on which you are floating above.
Example is above the first bridge near attackers spawn (red team) on Rialto.
If you left the borders of square effect would stop.
You could use "jump" and platform would imitate jump.

You need to know 4 coordinates to use it.

  • Platfrom made by: Ikra#2825
  • Also contains "simple ruller" that was made by: blaking707
  • So you could know coordinates. But if you want to use this you should disable platform. Idk why. Kinda bug.
  • You could create any flat surface based on this while it in 2d space.

How does it works?

  • It creates a zone based on XYZ coordinations of A1,A2,A4,A3. Y should be same in every used point.
  • Player have a loop that update variable by his position.
  • Player have a loop that that send his XZ coordinates from Player variable and vector for comparing calculation.
  • It divides 4 points zone on 4 triangles and using only 2 of them (GVS1,2) to calculate the area of zone.
  • It compare XZ position of player to 4 points of the zone. Based on triangulation. And made 4 areas (PVS1,2,3,4).
  • If player enters the zone Summ of Flat platform triangles GVS1+GVS2 or GVS3+GVS4 == PVS1+PVS2+PVS3+PVS4
  • It checks that Y position of player some above height of platform and not below it.
  • And effect starts.

Formula of area triangle for those who don't remember:

  • S=Square root(p(p-a)(p-b)(p-c))
  • p=(a+b+c)/2
  • where a,b,c are sides of triangle.

Archival Notice

This post was originally hosted on workshop.elohell.gg, a site which is no longer online. If this was originally your post, you may click the button below to transfer this post to your Workshop.codes account or delete this post entirely.

Archive Actions
Players | 1 - 12
Categories: Practice Mode
Heroes: D.va, Junker Queen, Orisa, Reinhardt, Roadhog, and 29 more...
Created at:
Last updated:
Current version: 1.0.2

Similar Codes

Elo Hell Logo_H-M-Dark
Join the Elo Hell Workshops Discord