Resolves issue 977 - randomised supply packs are randomised at the time of purchase

Clicking cancel when prompted for a reason for an order will cancel the order rather than using a default reason.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4779 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
elly1989@rocketmail.com
2012-09-30 14:40:48 +00:00
parent e064bd15bd
commit b932099768
2 changed files with 17 additions and 13 deletions
+3 -10
View File
@@ -8,7 +8,7 @@
/datum/supply_packs
var/name = null
var/list/contains = list()
var/manifest
var/manifest = ""
var/amount = null
var/cost = null
var/containertype = null
@@ -18,7 +18,7 @@
var/contraband = 0
/datum/supply_packs/New()
manifest = "<ul>"
manifest += "<ul>"
for(var/path in contains)
if(!path) continue
var/atom/movable/AM = new path()
@@ -574,12 +574,8 @@
/obj/item/clothing/head/collectable/thunderdome,
/obj/item/clothing/head/collectable/swat,
/obj/item/clothing/head/collectable/metroid,
/obj/item/clothing/head/collectable/metroid,
/obj/item/clothing/head/collectable/police,
/obj/item/clothing/head/collectable/police,
/obj/item/clothing/head/collectable/slime,
/obj/item/clothing/head/collectable/slime,
/obj/item/clothing/head/collectable/xenom,
/obj/item/clothing/head/collectable/xenom,
/obj/item/clothing/head/collectable/petehat)
name = "Collectable hat crate!"
@@ -588,10 +584,7 @@
containername = "Collectable hats crate! Brought to you by Bass.inc!"
/datum/supply_packs/randomised/New()
var/list/tempContains = list()
for(var/i = 0,i<num_contained,i++)
tempContains += pick(contains)
contains = tempContains
manifest += "Contains any [num_contained] of:"
..()