mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-25 14:08:31 +01:00
- Fixed bots runtiming.
- Removed 50 lights from the map. Please do not overuse the lights when mapping. If you are trying to light a small room please use the smaller light bulbs, as they will be less laggy. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5633 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -225,6 +225,8 @@ text("<A href='?src=\ref[src];operation=oddbutton'>[src.oddbutton ? "Yes" : "No"
|
||||
next_dest_loc = closest_loc
|
||||
if (next_dest_loc)
|
||||
src.patrol_path = AStar(src.loc, next_dest_loc, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 120, id=botcard, exclude=null)
|
||||
if(!patrol_path)
|
||||
patrol_path = list()
|
||||
else
|
||||
patrol_move()
|
||||
|
||||
@@ -234,6 +236,8 @@ text("<A href='?src=\ref[src];operation=oddbutton'>[src.oddbutton ? "Yes" : "No"
|
||||
spawn(0)
|
||||
if(!src || !target) return
|
||||
src.path = AStar(src.loc, src.target.loc, /turf/proc/AdjacentTurfs, /turf/proc/Distance, 0, 30)
|
||||
if(!src.path)
|
||||
src.path = list()
|
||||
if(src.path.len == 0)
|
||||
src.oldtarget = src.target
|
||||
src.target = null
|
||||
|
||||
@@ -615,6 +615,8 @@ Auto Patrol: []"},
|
||||
// given an optional turf to avoid
|
||||
/obj/machinery/bot/ed209/proc/calc_path(var/turf/avoid = null)
|
||||
src.path = AStar(src.loc, patrol_target, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 120, id=botcard, exclude=avoid)
|
||||
if(!src.path)
|
||||
src.path = list()
|
||||
|
||||
|
||||
// look for a criminal in view of the bot
|
||||
|
||||
@@ -244,6 +244,8 @@
|
||||
src.path = AStar(src.loc, src.target.loc, /turf/proc/AdjacentTurfsSpace, /turf/proc/Distance, 0, 30)
|
||||
else
|
||||
src.path = AStar(src.loc, src.target, /turf/proc/AdjacentTurfsSpace, /turf/proc/Distance, 0, 30)
|
||||
if(!src.path)
|
||||
src.path = list()
|
||||
if(src.path.len == 0)
|
||||
src.oldtarget = src.target
|
||||
src.target = null
|
||||
|
||||
@@ -706,6 +706,8 @@
|
||||
// given an optional turf to avoid
|
||||
/obj/machinery/bot/mulebot/proc/calc_path(var/turf/avoid = null)
|
||||
src.path = AStar(src.loc, src.target, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 250, id=botcard, exclude=avoid)
|
||||
if(!src.path)
|
||||
src.path = list()
|
||||
|
||||
|
||||
// sets the current destination
|
||||
|
||||
@@ -553,6 +553,8 @@ Auto Patrol: []"},
|
||||
// given an optional turf to avoid
|
||||
/obj/machinery/bot/secbot/proc/calc_path(var/turf/avoid = null)
|
||||
src.path = AStar(src.loc, patrol_target, /turf/proc/CardinalTurfsWithAccess, /turf/proc/Distance, 0, 120, id=botcard, exclude=avoid)
|
||||
if(!src.path)
|
||||
src.path = list()
|
||||
|
||||
|
||||
// look for a criminal in view of the bot
|
||||
|
||||
+8092
-8106
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user