Hiding some ThangTypes from view in level editor.

This commit is contained in:
Nick Winter 2014-11-29 10:34:04 -08:00
parent 306f599673
commit 891b78eb44
3 changed files with 4 additions and 4 deletions
app/views/editor/level/thangs

View file

@ -33,7 +33,7 @@ module.exports = class AddThangsView extends CocoView
models = @supermodel.getModels(ThangType)
thangTypes = _.uniq models, false, (thangType) -> thangType.get('original')
thangTypes = _.reject thangTypes, (thangType) -> thangType.get('kind') in ['Mark', 'Item']
thangTypes = _.reject thangTypes, (thangType) -> thangType.get('kind') in ['Mark', 'Item', undefined]
groupMap = {}
for thangType in thangTypes
kind = thangType.get('kind')

View file

@ -82,7 +82,7 @@ module.exports = class ThangsTabView extends CocoView
return context unless @supermodel.finished()
thangTypes = (thangType.attributes for thangType in @supermodel.getModels(ThangType))
thangTypes = _.uniq thangTypes, false, 'original'
thangTypes = _.reject thangTypes, kind: 'Mark'
thangTypes = _.reject thangTypes, (tt) -> tt.kind in ['Mark', undefined]
groupMap = {}
for thangType in thangTypes
groupMap[thangType.kind] ?= []