2 REGISTER_NET_LINKED(ENT_CLIENT_CORNER)
5 bool corner_send(entity this, entity to, int sf)
7 WriteHeader(MSG_ENTITY, ENT_CLIENT_CORNER);
9 WriteString(MSG_ENTITY, this.platmovetype);
11 WriteCoord(MSG_ENTITY, this.origin_x);
12 WriteCoord(MSG_ENTITY, this.origin_y);
13 WriteCoord(MSG_ENTITY, this.origin_z);
15 WriteString(MSG_ENTITY, this.target);
16 WriteString(MSG_ENTITY, this.target2);
17 WriteString(MSG_ENTITY, this.target3);
18 WriteString(MSG_ENTITY, this.target4);
19 WriteString(MSG_ENTITY, this.targetname);
20 WriteByte(MSG_ENTITY, this.target_random);
22 WriteByte(MSG_ENTITY, this.wait);
27 void corner_link(entity this)
29 //Net_LinkEntity(this, false, 0, corner_send);
32 spawnfunc(path_corner)
34 // setup values for overriding train movement
35 // if a second value does not exist, both start and end speeds are the single value specified
36 set_platmovetype(this, this.platmovetype);
42 void corner_remove(entity this)
44 if(this.target) { strunzone(this.target); }
45 this.target = string_null;
47 if(this.target2) { strunzone(this.target2); }
48 this.target2 = string_null;
50 if(this.target3) { strunzone(this.target3); }
51 this.target3 = string_null;
53 if(this.target4) { strunzone(this.target4); }
54 this.target4 = string_null;
56 if(this.targetname) { strunzone(this.targetname); }
57 this.targetname = string_null;
59 if(this.platmovetype) { strunzone(this.platmovetype); }
60 this.platmovetype = string_null;
63 NET_HANDLE(ENT_CLIENT_CORNER, bool isnew)
65 this.platmovetype = strzone(ReadString());
67 this.origin_x = ReadCoord();
68 this.origin_y = ReadCoord();
69 this.origin_z = ReadCoord();
70 setorigin(this, this.origin);
72 this.target = strzone(ReadString());
73 this.target2 = strzone(ReadString());
74 this.target3 = strzone(ReadString());
75 this.target4 = strzone(ReadString());
76 this.targetname = strzone(ReadString());
77 this.target_random = ReadByte();
79 this.wait = ReadByte();
83 this.classname = "path_corner";
84 this.drawmask = MASK_NORMAL;
85 this.entremove = corner_remove;
87 set_platmovetype(this, this.platmovetype);