diff options
author | orwell96 <orwell@bleipb.de> | 2018-05-28 20:05:19 +0200 |
---|---|---|
committer | orwell96 <orwell@bleipb.de> | 2018-06-14 17:39:42 +0200 |
commit | 254c32e304a4f279bf99e460727daf1b78050c47 (patch) | |
tree | 106c2b6853adb39674886c3c32da0568c3405a27 /advtrains/wagons.lua | |
parent | 24b0639c5f057ccb0fccc3c65be923bee1b571db (diff) | |
download | advtrains-254c32e304a4f279bf99e460727daf1b78050c47.tar.gz advtrains-254c32e304a4f279bf99e460727daf1b78050c47.tar.bz2 advtrains-254c32e304a4f279bf99e460727daf1b78050c47.zip |
Fix yaw calculations, track placement orientation and speed up direction lookup functions
Diffstat (limited to 'advtrains/wagons.lua')
-rw-r--r-- | advtrains/wagons.lua | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/advtrains/wagons.lua b/advtrains/wagons.lua index 254e6a8..9ee44b2 100644 --- a/advtrains/wagons.lua +++ b/advtrains/wagons.lua @@ -10,8 +10,6 @@ advtrains.wagons = {}
advtrains.wagon_prototypes = {}
--- TODO: That yaw thing is still not fixed. seems like minetest itself obeys the counterclockwise system...
-
--
function advtrains.create_wagon(wtype, owner)
local new_id=advtrains.random_id()
@@ -1092,7 +1090,7 @@ function advtrains.register_wagon(sysname_p, prototype, desc, inv_img, nincreati return itemstack
end
local tconns=advtrains.get_track_connections(node.name, node.param2)
- local yaw = placer:get_look_horizontal() + (math.pi/2)
+ local yaw = placer:get_look_horizontal()
local plconnid = advtrains.yawToClosestConn(yaw, tconns)
local prevpos = advtrains.get_adjacent_rail(pointed_thing.under, tconns, plconnid, prototype.drives_on)
|