Hopefully should fix some crashing for NTSL.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3413 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
vageyenaman@gmail.com
2012-04-08 18:34:56 +00:00
parent 45efc957a8
commit f9c472c4ee

View File

@@ -255,7 +255,12 @@
var/list/textList = new()
var/searchPosition = 1
var/findPosition = 1
var/loops = 0
while(1)
if(loops >= 1000)
break
loops++
findPosition = findtext(text, separator, searchPosition, 0)
var/buggyText = copytext(text, searchPosition, findPosition)
if(!withinList || (buggyText in withinList)) textList += "[buggyText]"