Editing
ObjectPlus
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Standard Shapes == *'''OP_Line''' β creates a floor using two points each with x, y, z, and width values drawn perpendicular to the line created by the two points. This is essentially an angled ''AddFloor''. Also, the function does not use OP_Draw. Syntax: <code>OP_Line(destobject, name, texture, aligntexturemap, x1, y1, z1, w1, x2, y2, z2, w2)</code> ''destobject'' specifies the destination object (floor, external, buildings, landscape, or elevator). name is the name of the object. ''texture'' is the texture of the object. ''aligntexturemap'' currently does nothing. ''x1, y1'', and ''z1'' correspond to the x, y, and z coordinates of the first point. ''w1'' is the width of the floor at the first point. Likewise, ''x2, y2, z2'', and ''w2'' correspond to the x, y, z, and width values at the second point. <!-- Figure 1 --> The width is always drawn to the right 90Β° from the direction of drawing. In other words, when travelling down the line from P<sub>1</sub> to P<sub>2</sub>, the width will always draw to your right. * from βz to the +z direction, width will draw towards the +x direction * from +z to the βz direction, width will draw towards the βx direction * from βx to the +x direction, width will draw towards the βz direction * from +x to the βx direction, width will draw towards the +z direction <!--You may use these non-trigonometric formulas to obtain the other two points of the floor. These were derived using similar triangle properties. x-coordinate of Qnx =Pnx + (w_n*(z2-z1))/β(γ(x2-x1)γ^2+γ(z2-z1)γ^2 ) z-coordinate of Qnz = Pnz β (w_n*(x2-x1))/β(γ(x2-x1)γ^2+γ(z2-z1)γ^2 ) --> '''OP_MultiLine''' β creates a path of connected floors using multiple points. This is useful in making curving 3D objects such as curved railings, roads, or track. Currently, MultiLine is limited to a '''maximum of 7 points'''. Like OP_Line, the function also does not use OP_Draw. Syntax: <code>OP_MultiLine(drawingmethod, destobject, name, texture, tilex, tilez, numberofpoints, x1, y1, z1, w1, x2, y2, z2, w2, x3, y3, z3, w3...)</code> ''drawingmethod'' does nothing. ''destobject'' specifies the destination object (floor, external, buildings, landscape, or elevator). name is the name of the object. ''texture'' is the texture of the object. ''tilex'' and ''tilez'' are the texture tiling values. ''numberofpoints'' specifies the number of points in the multiline (maximum is 7). ''xn, yn'', and ''zn'' correspond to the x, y, and z coordinates of point n. ''wn'' is the width or the line at point n. <!-- Figure 2 --> Similar to Line, the width is always drawn to the right 90Β° from the direction of drawing. In other words, when travelling down the line from P<sub>1</sub> to P<sub>2</sub>, the width will always draw to your right. * from βz to the +z direction, width will draw towards the +x direction * from +z to the βz direction, width will draw towards the βx direction * from βx to the +x direction, width will draw towards the βz direction * from +x to the βx direction, width will draw towards the +z direction MultiLine uses a set of special non-trigonometric formulas to calculate the points Q<sub>n</sub> in the '''Figure 2'''. These were mathematically derived using similar triangle and vector bisector properties. <!-- '''''Endpoints''''' x-coordinate of Qnx = xn + (w_n*(z2-z1))/β(γ(x2-x1)γ^2+γ(z2-z1)γ^2 ) z-coordinate of Qnz = zn β (w_n*(x2-x1))/β(γ(x2-x1)γ^2+γ(z2-z1)γ^2 ) '''''Intermediate Points''''' x-coordinate of Qnx = xn β (d_1*w_n*((x_n-x_(n-1))/(-d_1 )+(x_(n+1)-x_n)/d_2 ))/((x_n-x_(n-1))((z_n-z_(n-1))/(-d_1 )+(z_(n+1)-z_n)/d_2 )-(z_n-z_(n-1))((x_n-x_(n-1))/(-d_1 )+(x_(n+1)-x_n)/d_2 )) z-coordinate of Qnz = zn β (d_1*w_n*((z_n-z_(n-1))/(-d_1 )+(z_(n+1)-z_n)/d_2 ))/((x_n-x_(n-1))((z_n-z_(n-1))/(-d_1 )+(z_(n+1)-z_n)/d_2 )-(z_n-z_(n-1))((x_n-x_(n-1))/(-d_1 )+(x_(n+1)-x_n)/d_2 )) where d1 = β(γ(x_n-x_(n-1))γ^2+γ(z_n-z_(n-1))γ^2 ) and d2 = β(γ(x_(n+1)-x_n)γ^2+γ(z_(n+1)-z_n)γ^2 ) --> '''OP_Polygon''' β creates a regular polygon (equal side lengths) with an arbitrary number of sides. Current restrictions include a '''maximum of 10 sides'''. The polygons are drawn to be inscribed in a circle (see '''Figure 3'''). The function also doesn't use OP_Draw. Syntax: <code>OP_Polygon(drawingmethod, destobject, name, texture, numberofsides, centerx, centerz, radius, altitude)</code> ''drawingmethod'' was created to allow the polygon to be drawn as if it were circumscribed about a circle, however this function was discontinued for OP_AdvPolygon and was only programmed to do inscribed polygons. ''destobject'' specifies the destination object (floor, external, buildings, landscape, or elevator). ''name'' is the name of the polygon object. ''texture'' is the texture of the object. ''numberofsides'' specifies the number of sides the polygon will have (current maximum is 10). ''centerx'' and ''centerz'' are the respective x, and z coordinates of the center of the polygon. radius specifies the distance from the center to the vertices when inscribed or the distance from the center to the midpoint of each side when circumscribed. Currently, the polygon will always draw starting at the +x direction from the center (x = ''centerx'' + ''radius'', z = ''centerz''). A ''rotation'' parameter will be added later to allow rotating the polygon at an arbitrary angle counterclockwise from the +x axis. <!-- Figure 3 -->
Summary:
Please note that all contributions to Skyscraper Wiki are considered to be released under the Creative Commons Attribution-ShareAlike (see
Skyscraper Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
Edit source
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
What links here
Related changes
Special pages
Page information