setCameraPanRange() Function Reference

setCameraPanRange(integer x1, integer y1, integer x2, integer y2)

Sets a boundary area that the camera is allowed to be panned within. x1,y1 represents the northern corner tile of the boundary, and x2,y2 represents the southern corner tile.


	local qiso = require "plugin.qisoengine"
	qiso.setAssetsFolder("assets")
	qiso.loadTiledMap("sample-tilemap")

	-- Enable camera panning when the screen is dragged
	qiso.enableCameraPan()

	-- Restrict camera panning
	qiso.setCameraPanRange(10, 10, 40, 40)

	-- Enable the main Qiso loop to render/update our world
	qiso.activate()