small modification regarding pigscript