Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
ScreenGuide.cs
Go to the documentation of this file.
1using UnityEngine;
2
3public class ScreenGuide : EMono
4{
6
8
10
12
13 public LineRenderer lr;
14
15 public bool isActive = true;
16
17 public void DrawLine(Vector3 from, Vector3 to)
18 {
19 lr.positionCount = 2;
20 from.z = (to.z = -300f);
21 lr.SetPosition(0, from);
22 lr.SetPosition(1, to);
23 }
24
25 public void DrawFloor(Point pos, int tile)
26 {
27 }
28
29 public void DrawBlock(Point pos, int tile)
30 {
31 }
32
33 public void OnDrawPass()
34 {
35 }
36
37 public void OnEndOfFrame()
38 {
39 lr.positionCount = 0;
40 }
41
42 public void DrawWall(Point point, int color, bool useMarkerPass = false, float offsetZ = 0f)
43 {
44 int num = -1;
45 if (num != -1)
46 {
47 Vector3 vector = point.Position();
48 EMono.screen.guide.passGuideFloor.Add(vector.x, vector.y, vector.z - 0.01f);
49 }
50 SourceBlock.Row sourceBlock = point.sourceBlock;
51 RenderParam renderParam = sourceBlock.GetRenderParam(point.matBlock, point.cell.blockDir, point, num);
52 renderParam.matColor = color;
53 renderParam.z -= 0.01f;
54 if (useMarkerPass)
55 {
56 renderParam.x += sourceBlock.renderData.offset.x;
57 renderParam.y += sourceBlock.renderData.offset.y;
58 renderParam.z += sourceBlock.renderData.offset.z + offsetZ;
59 passBlockMarker.Add(renderParam);
60 }
61 else
62 {
63 sourceBlock.renderData.Draw(renderParam);
64 }
65 if (point.cell.blockDir == 2)
66 {
67 renderParam.tile *= -1f;
68 if (useMarkerPass)
69 {
70 passBlockMarker.Add(renderParam);
71 }
72 else
73 {
74 sourceBlock.renderData.Draw(renderParam);
75 }
76 }
77 }
78}
ScreenGuide guide
int blockDir
Definition: Cell.cs:898
Definition: EMono.cs:4
static BaseGameScreen screen
Definition: EMono.cs:29
void Add(Point point, float tile=0f, float color=0f)
Definition: MeshPass.cs:122
Definition: Point.cs:9
SourceMaterial.Row matBlock
Definition: Point.cs:55
SourceBlock.Row sourceBlock
Definition: Point.cs:63
ref Vector3 Position(int height)
Definition: Point.cs:524
Cell cell
Definition: Point.cs:51
void Draw(RenderParam p, int tile)
Definition: RenderData.cs:128
Vector3 offset
Definition: RenderData.cs:18
RenderData renderData
Definition: RenderRow.cs:71
bool isActive
Definition: ScreenGuide.cs:15
void DrawWall(Point point, int color, bool useMarkerPass=false, float offsetZ=0f)
Definition: ScreenGuide.cs:42
void OnEndOfFrame()
Definition: ScreenGuide.cs:37
MeshPass passBlockMarker
Definition: ScreenGuide.cs:11
void DrawFloor(Point pos, int tile)
Definition: ScreenGuide.cs:25
MeshPass passArea
Definition: ScreenGuide.cs:9
void DrawBlock(Point pos, int tile)
Definition: ScreenGuide.cs:29
void OnDrawPass()
Definition: ScreenGuide.cs:33
MeshPass passGuideBlock
Definition: ScreenGuide.cs:5
MeshPass passGuideFloor
Definition: ScreenGuide.cs:7
void DrawLine(Vector3 from, Vector3 to)
Definition: ScreenGuide.cs:17
LineRenderer lr
Definition: ScreenGuide.cs:13
override RenderParam GetRenderParam(SourceMaterial.Row mat, int dir, Point point=null, int bridgeHeight=-1)
Definition: SourceBlock.cs:53