public void OnGetDirections() { const string sourceAddress = "221B Baker Street, London, Great Britain"; const string destAddress = "Manchester, Great Britain"; IGMaps.GetDirections(destAddress, sourceAddress, IGMaps.TransportType.ByCar, IGMaps.MapViewType.Hybrid); }
public void OnOpenMapsLocation() { const float latitude = 52.3781019f; const float longitude = 4.8983588f; var amsterdamCentralStation = new IGMaps.Location(latitude, longitude); IGMaps.OpenMapLocation(amsterdamCentralStation, "Label-X", IGMaps.MapViewType.Satellite); }
public void OnSearchWithLocation() { const float latitude = 50.894967f; const float longitude = 4.341626f; var atomiumLocation = new IGMaps.Location(latitude, longitude); const int zoom = 5; IGMaps.PerformSearch("Fish restaurant", atomiumLocation, zoom, IGMaps.MapViewType.Standard); }
void Awake() { st = this ; //Rect r =new Rect(); _stepMoveDistince = 0.166667f/16.0f ; _minDistince = _stepMoveDistince * 2; Vector3 _down = transform.TransformDirection( Vector3.down ) ; Vector3 _up = transform.TransformDirection( Vector3.up ) ; Vector3 _left = transform.TransformDirection( Vector3.left ) ; Vector3 _right = transform.TransformDirection( Vector3.right ) ; //Vector3 _down = transform.TransformDirection( Vector3.down ) ; //Vector3 _up = transform.TransformDirection( Vector3.up ) ; _up_down = new Vector3[2]; _up_down [0] = _up; _up_down [1] = _up; Vector3Direction vdown = new Vector3Direction(_down, 0.166667f + _minDistince ); Vector3Direction vup = new Vector3Direction(_up, 0.166667f + _minDistince ); Vector3Direction vleft = new Vector3Direction( _left , _minDistince ); Vector3Direction vright = new Vector3Direction( _right , _minDistince ); _listDirection.Add(vdown) ; _listDirection.Add(vright) ; //_listDirection.Add(_up) ; _listDirection.Add(vleft) ; _isGameOver = false ; _isEditing = false ; _status = PlayingStatus.Normal ; _gridWidth =( Screen.width /1024.0f) * _gridWidth; _layerFlashMask = 1 << LayerMask.NameToLayer("flash") ; _layerFlash = LayerMask.NameToLayer("flash") ; _layerNormal = LayerMask.NameToLayer("normal") ; float _width = _gridWidth ; // x 21 y 100 _Maps = new IGMaps[16,108]; for(int i = 0 ;i <16 ; i++ ) { //_Maps[i] = new ObjectsMap[100] ; for(int j = 0 ; j < 108 ; j++ ) { _Maps[i,j] = new IGMaps() ; _Maps[i,j].x = i ; _Maps[i,j].y = j ; //_gameMaps[i][j].ObjectPoint = new Vector2( _width * i + _width/2 ,_width*j + _width/2 ) ; _Maps[i,j].position = Camera.main.ScreenToWorldPoint ( new Vector3( _width * i + _width/2 , _screenHeigh - (_width*j+_width/2) ,2.0f ) ) ; Vector3 v3= Camera.main.ScreenToWorldPoint ( new Vector3( _width * i , _screenHeigh - ( _width*j ) ,2.0f ) ) ; _Maps[i,j].rect = new Rect(v3.x,v3.y,0.1666667f,0.1666667f); //Camera.main.WorldToScreenPoint //_gameMaps[i][j]. // _gameMaps[i][j].ObjectPosition = Camera.main.ScreenToWorldPoint ( new Vector3( _width * i + _width/2 , 768 - (_width*j+_width/2) ,2.0f ) ) ; } } /* for(int j = 0 ; j < 100 ; j++ ) { Vector3 v3 = Camera.main.ScreenToWorldPoint ( new Vector3( 0 , 0 - (_width*j+_width/2) ,2.0f ) ) ; Rect r =new Rect(0,0,0.166667f,0.166667f); Ylist.Add( j ,v3.y ); print( v3.y ) ; } */ // x=-1.166667,y=-0.8333333 // 64x=-1.166667,64y=0.1666667,0x=-1.333333,0y=0,1024x=1.333333,768y=2 Vector3 v64 = Camera.main.ScreenToWorldPoint ( new Vector3( 64.0f , 64.0f ,2.0f ) ) ; Vector3 v0 = Camera.main.ScreenToWorldPoint ( new Vector3( 0f , 0f ,2.0f ) ) ; Vector3 v1024 = Camera.main.ScreenToWorldPoint ( new Vector3( 1024f , 768f ,2.0f ) ) ; print( string.Format( "64x={0},64y={1},0x={2},0y={3},1024x={4},768y={5}",v64.x ,v64.y ,v0.x , v0.y ,v1024.x ,v1024.y ) ) ; StartCoroutine(FlashingOffset()); // GameObject _object = (GameObject)Instantiate(_Prefab); // _object.transform.position = _gameMaps[3][8].ObjectPosion ; }
public void OnSimpleMapSearch() { const string searchQuery = "Eiffel tower, Paris"; IGMaps.PerformSearch(searchQuery); }
public void OnOpenMapsAddress() { const string address = "1,Infinite Loop,Cupertino,California"; IGMaps.OpenMapAddress(address, "Label-Y", IGMaps.MapViewType.Hybrid); }
public GMapsAppService(IGMaps gMapsClient, IMapper mapper) { _gMapsClient = gMapsClient; _mapper = mapper; }