- this.pos2 = this.pos1 + this.movedir*(fabs(this.movedir*this.size) - this.lip);
-
- if(autocvar_sv_doors_always_open)
- {
- this.speed = max(750, this.speed);
- }
- else if (!this.speed)
- {
+ vector absmovedir;
+ absmovedir.x = fabs(this.movedir.x);
+ absmovedir.y = fabs(this.movedir.y);
+ absmovedir.z = fabs(this.movedir.z);
+ this.pos2 = this.pos1 + this.movedir * (absmovedir * this.size - this.lip);
+
+ if(autocvar_sv_doors_always_open)
+ {
+ this.speed = max(750, this.speed);
+ }
+ else if (!this.speed)
+ {