mirror of
https://github.com/RandomityGuy/MBHaxe.git
synced 2026-02-20 13:11:02 +00:00
29 lines
832 B
Haxe
29 lines
832 B
Haxe
package shapes;
|
|
|
|
import mis.MissionElement.MissionElementStaticShape;
|
|
import src.DtsObject;
|
|
|
|
class SignPlain extends DtsObject {
|
|
public function new(element:MissionElementStaticShape) {
|
|
super();
|
|
|
|
this.dtsPath = "data/shapes/signs/plainsign.dts";
|
|
this.isCollideable = true;
|
|
this.useInstancing = true;
|
|
|
|
// Determine the direction to show
|
|
var direction = element.datablock.substring("SignPlain".length).toLowerCase();
|
|
switch (direction) {
|
|
case "right":
|
|
this.matNameOverride.set("base.plainsign", "right.plainsign");
|
|
case "left":
|
|
this.matNameOverride.set("base.plainsign", "left.plainsign");
|
|
case "up":
|
|
this.matNameOverride.set("base.plainsign", "up.plainsign");
|
|
case "down":
|
|
this.matNameOverride.set("base.plainsign", "down.plainsign");
|
|
}
|
|
|
|
this.identifier = "SignPlain" + direction;
|
|
}
|
|
}
|