Exemple #1
0
 void PositionCamera()
 {
     viewCamera.transform.parent.transform.position = MapBlock.DFtoUnityCoord(
         (connectionState.net_view_info.view_pos_x + (connectionState.net_view_info.view_size_x / 2)),
         (connectionState.net_view_info.view_pos_y + (connectionState.net_view_info.view_size_y / 2)),
         connectionState.net_view_info.view_pos_z + 1);
     viewCamera.viewWidth  = connectionState.net_view_info.view_size_x;
     viewCamera.viewHeight = connectionState.net_view_info.view_size_y;
 }