mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-08-01 02:16:15 -04:00
@@ -128,6 +128,10 @@ def run(core, actor, target, commandString):
|
||||
|
||||
if inventory:
|
||||
inventory.add(object)
|
||||
|
||||
elif command == 'spawnobj':
|
||||
pos = actor.getPosition()
|
||||
core.staticService.spawnObject(arg1, actor.getPlanet().getName(), 0, pos.x, pos.y, pos.z, 0, 0)
|
||||
|
||||
elif command == 'unknownAbilityPacket' and arg1:
|
||||
packet = UnknownAbilityPacket(arg1)
|
||||
|
||||
@@ -23,12 +23,17 @@ def run(core, actor, target, commandString):
|
||||
|
||||
if target.getTemplate() == 'object/tangible/item/shared_loot_cash.iff':
|
||||
core.lootService.handleCreditPickUp(actor,target)
|
||||
if target.getGrandparent().getInventoryItemCount()==1:
|
||||
core.lootService.setLooted(actor,target.getGrandparent())
|
||||
core.objectService.destroyObject(target)
|
||||
return
|
||||
|
||||
if target.isLootItem():
|
||||
target.setLootItem(0)
|
||||
actor.sendSystemMessage('You looted ' + target.getObjectName().getStfValue() + ' from corpse.', 0)
|
||||
#actor.sendSystemMessage('container.getInventoryItemCount() %s' % target.getGrandparent().getInventoryItemCount(), 0)
|
||||
if target.getGrandparent().getInventoryItemCount()==1:
|
||||
core.lootService.setLooted(actor,target.getGrandparent())
|
||||
|
||||
if actorContainer != None and (container.getTemplate() == "object/cell/shared_cell.iff") & core.housingService.getPermissions(actor, actorContainer):
|
||||
target.getContainer().transferTo(actor, container, target)
|
||||
|
||||
@@ -3,5 +3,5 @@ def itemTemplate():
|
||||
# Doesn't work because of https://github.com/projectswg/engine/blob/master/src/engine/resources/objects/Baseline.java#L446
|
||||
#return ['object/draft_schematic/furniture/shared_furniture_hide_rack_s01.iff']
|
||||
# just returning a dummy template for now
|
||||
return ['object/tangible/bug_jar/shared_craftable_bug_habitat.iff']
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff']
|
||||
|
||||
|
||||
@@ -3,5 +3,5 @@ def itemTemplate():
|
||||
# Doesn't work because of https://github.com/projectswg/engine/blob/master/src/engine/resources/objects/Baseline.java#L446
|
||||
#return ['object/draft_schematic/furniture/shared_furniture_hide_rack_s02.iff']
|
||||
# just returning a dummy template for now
|
||||
return ['object/tangible/bug_jar/shared_craftable_bug_habitat.iff']
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff']
|
||||
|
||||
|
||||
@@ -3,5 +3,5 @@ def itemTemplate():
|
||||
# Doesn't work because of https://github.com/projectswg/engine/blob/master/src/engine/resources/objects/Baseline.java#L446
|
||||
#return ['object/draft_schematic/furniture/shared_furniture_hide_rack_s03.iff']
|
||||
# just returning a dummy template for now
|
||||
return ['object/tangible/bug_jar/shared_craftable_bug_habitat.iff']
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff']
|
||||
|
||||
|
||||
@@ -3,5 +3,5 @@ def itemTemplate():
|
||||
# Doesn't work because of https://github.com/projectswg/engine/blob/master/src/engine/resources/objects/Baseline.java#L446
|
||||
#return ['object/draft_schematic/furniture/shared_furniture_hide_rack_s04.iff']
|
||||
# just returning a dummy template for now
|
||||
return ['object/tangible/bug_jar/shared_craftable_bug_habitat.iff']
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff']
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs verification
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs verification
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs verification
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs verification
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/draft_schematic/furniture/shared_must_furniture_jedi_statue.iff'] # needs verification
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs verification
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/tangible/furniture/decorative/object/shared_hoverlifter_speeder_crafted.iff'] # needs correct iff still
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs correct iff still
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/tangible/event_perk/shared_fruit_stand.iff'] # needs correct iff still
|
||||
return ['object/tangible/loot/loot_schematic/shared_generic_limited_use.iff'] # needs correct iff still
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/tangible/item/ep3/shared_poi_kash_mystic_tree_healthy.iff'] # needs correct iff still
|
||||
return ['object/tangible/furniture/lifeday/shared_lifeday_mini_tree.iff'] # needs correct iff still
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/mobile/shared_target_dummy_blacksun.iff']
|
||||
return ['object/tangible/tcg/series3/shared_target_dummy_deed.iff']
|
||||
|
||||
def customItemName():
|
||||
|
||||
return "Blacksun Target Dummy Terminal"
|
||||
@@ -1,4 +1,8 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/mobile/shared_target_dummy_rebel_trooper.iff']
|
||||
return ['object/tangible/tcg/series3/shared_target_dummy_deed.iff']
|
||||
|
||||
def customItemName():
|
||||
|
||||
return "Rebel Target Dummy Terminal"
|
||||
@@ -1,4 +1,8 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/mobile/shared_target_dummy_stormtrooper.iff']
|
||||
return ['object/tangible/tcg/series3/shared_target_dummy_deed.iff']
|
||||
|
||||
def customItemName():
|
||||
|
||||
return "Stormtrooper Target Dummy Terminal"
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
def itemTemplate():
|
||||
|
||||
return ['object/tangible/furniture/decorative/object/tangible/beta/shared_beta_terminal_warp.iff'] # needs correct iff still
|
||||
return ['object/tangible/terminal/shared_terminal_gcw_publish_gift.iff'] # needs correct iff still
|
||||
|
||||
@@ -19,10 +19,12 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(3)
|
||||
mobileTemplate.setStalker(False)
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
templates.add('object/mobile/shared_moncal_male.iff')
|
||||
templates.add('object/mobile/shared_moncal_female.iff')
|
||||
mobileTemplate.setTemplates(templates)
|
||||
|
||||
weaponTemplates = Vector()
|
||||
|
||||
@@ -19,7 +19,7 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(5)
|
||||
mobileTemplate.setStalker(False)
|
||||
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
|
||||
@@ -19,7 +19,7 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(5)
|
||||
mobileTemplate.setStalker(False)
|
||||
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
|
||||
@@ -19,7 +19,7 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(0)
|
||||
mobileTemplate.setStalker(False)
|
||||
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
|
||||
@@ -19,7 +19,7 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(3)
|
||||
mobileTemplate.setStalker(False)
|
||||
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
|
||||
@@ -19,10 +19,11 @@ def addTemplate(core):
|
||||
mobileTemplate.setSocialGroup("whitethranta")
|
||||
mobileTemplate.setAssistRange(0)
|
||||
mobileTemplate.setStalker(False)
|
||||
|
||||
mobileTemplate.setOptionsBitmask(192)
|
||||
|
||||
templates = Vector()
|
||||
templates.add('object/mobile/shared_dressed_tatooine_opening_wh_guard.iff')
|
||||
templates.add('object/mobile/shared_warren_scientist_s01.iff')
|
||||
templates.add('object/mobile/shared_warren_scientist_s01.iff')
|
||||
mobileTemplate.setTemplates(templates)
|
||||
|
||||
weaponTemplates = Vector()
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_bicep_l_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_bicep_l_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_bicep_r_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_bicep_r_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_boots_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_boots_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_bracer_l_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_bracer_l_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_bracer_r_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_bicep_r_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_chest_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_chest_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_gloves_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_gloves_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_helmet_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_helmet_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,17 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('armor_medic_roadmap_leggings_02_01')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('armor_medic_roadmap_leggings_02_01')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setStringAttribute('armor_category', 'Reconnaissance')
|
||||
object.setIntAttribute('cat_armor_standard_protection.kinetic', 640)
|
||||
object.setIntAttribute('cat_armor_standard_protection.energy', 2640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_heat', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_cold', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_acid', 1640)
|
||||
object.setIntAttribute('cat_armor_special_protection.special_protection_type_electricity', 1640)
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_roadmap_belt_entertainer_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_roadmap_belt_entertainer_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 15)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 20)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 15)
|
||||
object.setStringAttribute('class_required', 'Entertainer')
|
||||
object.setIntAttribute('required_combat_level', 90)
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_roadmap_belt_medic_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_roadmap_belt_medic_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 15)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 20)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 15)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setIntAttribute('required_combat_level', 90)
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_roadmap_belt_officer_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_roadmap_belt_officer_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 15)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 20)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 15)
|
||||
object.setStringAttribute('class_required', 'Officer')
|
||||
object.setIntAttribute('required_combat_level', 90)
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_roadmap_belt_smuggler_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_roadmap_belt_smuggler_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 15)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 20)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 15)
|
||||
object.setStringAttribute('class_required', 'Smuggler')
|
||||
object.setIntAttribute('required_combat_level', 90)
|
||||
return
|
||||
@@ -10,4 +10,4 @@ def setup(core, object):
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 15)
|
||||
object.setStringAttribute('class_required', 'Trader')
|
||||
object.setIntAttribute('required_combat_level', 90)
|
||||
return
|
||||
return
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_entertainer_pendant_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_entertainer_pendant_01_02')
|
||||
object.setIntAttribute('cat_skill_mod_bonus.@stat_n:dance_prop_assembly', 5)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:stamina_modified', 3)
|
||||
object.setStringAttribute('class_required', 'Entertainer')
|
||||
return
|
||||
@@ -0,0 +1,11 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_medic_pendant_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_medic_pendant_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 12)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 12)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
return
|
||||
@@ -0,0 +1,11 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_officer_pendant_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_officer_pendant_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 12)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 12)
|
||||
object.setStringAttribute('class_required', 'Officer')
|
||||
return
|
||||
@@ -0,0 +1,11 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_smuggler_pendant_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_smuggler_pendant_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 12)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 12)
|
||||
object.setStringAttribute('class_required', 'Smuggler')
|
||||
return
|
||||
@@ -6,6 +6,6 @@ def setup(core, object):
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_trader_pendant_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:general_assembly', 5)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:hiring', 3)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:hiring', 2)
|
||||
object.setStringAttribute('class_required', 'Trader')
|
||||
return
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setAttachment('objType', 'ring')
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_entertainer_ring_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_entertainer_ring_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 6)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 6)
|
||||
object.setStringAttribute('class_required', 'Entertainer')
|
||||
object.setAttachment('radial_filename', 'ring/unity')
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setAttachment('objType', 'ring')
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_medic_ring_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_medic_ring_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 6)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 6)
|
||||
object.setStringAttribute('class_required', 'Medic')
|
||||
object.setAttachment('radial_filename', 'ring/unity')
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setAttachment('objType', 'ring')
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_officer_ring_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_officer_ring_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 6)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 6)
|
||||
object.setStringAttribute('class_required', 'Officer')
|
||||
object.setAttachment('radial_filename', 'ring/unity')
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setAttachment('objType', 'ring')
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_smuggler_ring_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_smuggler_ring_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 6)
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 6)
|
||||
object.setStringAttribute('class_required', 'Smuggler')
|
||||
object.setAttachment('radial_filename', 'ring/unity')
|
||||
return
|
||||
@@ -0,0 +1,13 @@
|
||||
import sys
|
||||
|
||||
def setup(core, object):
|
||||
object.setAttachment('objType', 'ring')
|
||||
object.setStfFilename('static_item_n')
|
||||
object.setStfName('item_trader_ring_01_02')
|
||||
object.setDetailFilename('static_item_d')
|
||||
object.setDetailName('item_trader_ring_01_02')
|
||||
object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 6)
|
||||
object.setIntAttribute('cat_skill_mod_bonus.@stat_n:artisian_assembly', 6)
|
||||
object.setStringAttribute('class_required', 'Trader')
|
||||
object.setAttachment('radial_filename', 'ring/unity')
|
||||
return
|
||||
@@ -5,7 +5,7 @@ import sys
|
||||
# Do not make ANY changes to this script without direct approval from Levarris!
|
||||
|
||||
from resources.datatables import Options
|
||||
from resources.datatables import StateStatus
|
||||
from resources.datatables import State
|
||||
|
||||
def addPlanetSpawns(core, planet):
|
||||
|
||||
@@ -13,15 +13,17 @@ def addPlanetSpawns(core, planet):
|
||||
stcSvc = core.staticService
|
||||
objSvc = core.objectService
|
||||
#Dark Temple Area
|
||||
#Structures
|
||||
stcSvc.spawnObject('object/building/military/shared_military_base_police_station_imperial_lok_otto.iff', 'kaas', long(0), float(-5117.8), float(80.0), float(-2314.1), float(0), float(0))
|
||||
stcSvc.spawnObject('object/building/player/shared_player_house_corellia_medium_style_01.iff', 'kaas', long(0), float(-5078.6), float(80.0), float(-2302.5), float(0), float(0))
|
||||
stcSvc.spawnObject('object/building/general/shared_bunker_imperial_weapons_research_facility_01.iff', 'kaas', long(0), float(-5159.5), float(80.0), float(-2298.7), float(0), float(0))
|
||||
stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5163.9), float(79.0), float(-2369.6), float(0.71), float(0.71))
|
||||
stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5163.9), float(79.0), float(-2351.6), float(0.71), float(0.71))
|
||||
stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5072.1), float(79.0), float(-2369.6), float(-0.71), float(0.71))
|
||||
stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5072.1), float(79.0), float(-2351.6), float(-0.71), float(0.71))
|
||||
stcSvc.spawnObject('object/building/military/shared_outpost_cloning_facility_s02.iff', 'kaas', long(0), float(-5072.1), float(80.0), float(-2279.5), float(0.71), float(0), float(-0.71), float(0))
|
||||
#Structures #TODO: Ascertain why the core is not spawning the child cells.
|
||||
|
||||
#building = stcSvc.spawnObject('object/building/military/shared_military_base_police_station_imperial_lok_otto.iff', 'kaas', long(0), float(-5117.8), float(80.0), float(-2314.1), float(0), float(0))
|
||||
#print building.getCells().size()
|
||||
#stcSvc.spawnObject('object/building/player/shared_player_house_corellia_medium_style_01.iff', 'kaas', long(0), float(-5078.6), float(80.0), float(-2302.5), float(0), float(0))
|
||||
#stcSvc.spawnObject('object/building/general/shared_bunker_imperial_weapons_research_facility_01.iff', 'kaas', long(0), float(-5159.5), float(80.0), float(-2298.7), float(0), float(0))
|
||||
#stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5163.9), float(79.0), float(-2369.6), float(0.71), float(0.71))
|
||||
#stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5163.9), float(79.0), float(-2351.6), float(0.71), float(0.71))
|
||||
#stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5072.1), float(79.0), float(-2369.6), float(-0.71), float(0.71))
|
||||
#stcSvc.spawnObject('object/building/content/aurilia/shared_aurilia_pyramid_hut.iff', 'kaas', long(0), float(-5072.1), float(79.0), float(-2351.6), float(-0.71), float(0.71))
|
||||
#stcSvc.spawnObject('object/building/military/shared_outpost_cloning_facility_s02.iff', 'kaas', long(0), float(-5072.1), float(80.0), float(-2279.5), float(0.71), float(0), float(-0.71), float(0))
|
||||
|
||||
#Terminals
|
||||
stcSvc.spawnObject('object/tangible/terminal/shared_terminal_bank.iff', 'kaas', long(0), float(-5080.8), float(80.0), float(-2275.7), float(-0.71), float(0.71))
|
||||
@@ -54,7 +56,6 @@ def addPlanetSpawns(core, planet):
|
||||
|
||||
|
||||
#Dark Temple Interior
|
||||
stcSvc.spawnObject('object/static/structure/content/shared_exar_kun_torch_01.iff', 'kaas', long(468319), float(0.0), float(-1.3), float(20.8), float(0), float(0))
|
||||
|
||||
|
||||
#Village of the Descendants Area
|
||||
|
||||
@@ -15,13 +15,12 @@ def addPlanetSpawns(core, planet):
|
||||
|
||||
building = core.objectService.getObject(long(-466404040703346823))
|
||||
|
||||
# TODO Check all NPCs for personalized scripting, change format.
|
||||
|
||||
# TODO Verify proper cell IDs once Jabba's Palace is spawning properly again.
|
||||
|
||||
#reelo baruk
|
||||
stcSvc.spawnObject('object/mobile/shared_reelo_baruk.iff', 'tatooine', building.getCellByCellNumber(1), float(-3.5), float(0.2), float(113.5), float(0), float(0), float(0), float(0))
|
||||
|
||||
#Entry Ambient Sounds #TODO: Fix object/soundobject spawning
|
||||
#stcSvc.spawnObject('object/soundobject/shared_soundobject_jabba_palace_entrance.iff', 'tatooine', building.getCellByCellNumber(1), float(-3.5), float(0.2), float(113.5), float(0), float(0), float(0), float(0))
|
||||
|
||||
#ree yees
|
||||
stcSvc.spawnObject('object/mobile/shared_dressed_gran_thug_male_01.iff', 'tatooine', building.getCellByCellNumber(1), float(5.8), float(0.2), float(115.7), float(-0.71), float(0), float(0.7), float(0))
|
||||
|
||||
@@ -43,6 +42,9 @@ def addPlanetSpawns(core, planet):
|
||||
#oola
|
||||
stcSvc.spawnObject('object/mobile/shared_oola.iff', 'tatooine', building.getCellByCellNumber(22), float(-10.3), float(2.0), float(43.9), float(-0.71), float(0), float(0.70), float(0))
|
||||
|
||||
#Ambient Sound
|
||||
#stcSvc.spawnObject('object/soundobject/shared_soundobject_jabba_audience_chamber.iff', 'tatooine', building.getCellByCellNumber(22), float(-10.3), float(2.0), float(43.9), float(-0.9), float(0), float(0.42), float(0))
|
||||
|
||||
#Boba Fett
|
||||
stcSvc.spawnObject('object/mobile/shared_boba_fett.iff', 'tatooine', building.getCellByCellNumber(22), float(-1.0), float(3.0), float(33.1), float(0), float(0), float(0), float(0))
|
||||
|
||||
@@ -58,6 +60,9 @@ def addPlanetSpawns(core, planet):
|
||||
#Max Rebo
|
||||
stcSvc.spawnObject('object/mobile/shared_max_rebo.iff', 'tatooine', building.getCellByCellNumber(22), float(-1.4), float(3.0), float(26.9), float(-0.9), float(0), float(0.42), float(0))
|
||||
|
||||
#Music
|
||||
#stcSvc.spawnObject('object/soundobject/shared_soundobject_jabba_max_rebo_band.iff', 'tatooine', building.getCellByCellNumber(22), float(-1.4), float(3.0), float(26.9), float(-0.9), float(0), float(0.42), float(0))
|
||||
|
||||
#Droopy Mccool
|
||||
stcSvc.spawnObject('object/mobile/shared_droopy_mccool.iff', 'tatooine', building.getCellByCellNumber(22), float(-3.9), float(3.0), float(26.1), float(-0.9), float(0), float(0.42), float(0))
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import sys
|
||||
|
||||
from resources.datatables import Options
|
||||
from resources.datatables import State
|
||||
from resources.datatables import StateStatus
|
||||
|
||||
def addPlanetSpawns(core, planet):
|
||||
|
||||
@@ -13,7 +14,7 @@ def addPlanetSpawns(core, planet):
|
||||
stcSvc = core.staticService
|
||||
objSvc = core.objectService
|
||||
|
||||
# TODO Check all NPCs for personalized scripting, change format.
|
||||
# TODO: Add NPCs sitting at Cantina tables with SittingOnChair bitmask.
|
||||
|
||||
#Cantina Interior
|
||||
building = core.objectService.getObject(long(1082874))
|
||||
@@ -105,7 +106,7 @@ def addPlanetSpawns(core, planet):
|
||||
anetiaKahryn.setCustomName('Anetia Kah\'ryn')
|
||||
anetiaKahryn.setOptionsBitmask(256)
|
||||
|
||||
figrinDan = stcSvc.spawnObject('object/mobile/tatooine_npc/shared_figrin_dan.iff', 'tatooine', building.getCellByCellNumber(6), float(3.7), float(-0.9), float(-14.4), float(0), float(0.42), float(0), float(0.91))
|
||||
figrinDan = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_figrin_dan.iff', 'tatooine', building.getCellByCellNumber(6), float(3.7), float(-0.9), float(-14.4), float(0), float(0.42), float(0), float(0.91))
|
||||
figrinDan.setCustomName('Figrin D\'an')
|
||||
figrinDan.setOptionsBitmask(256)
|
||||
|
||||
@@ -142,6 +143,10 @@ def addPlanetSpawns(core, planet):
|
||||
building = core.objectService.getObject(long(-466404040703447347))
|
||||
stcSvc.spawnObject('object/mobile/shared_han_solo.iff', 'tatooine', building.getCellByCellNumber(9), float(32.3), float(7.0), float(1.6), float(0), float(0), float(0), float(0))
|
||||
|
||||
valarian = stcSvc.spawnObject('object/mobile/shared_lady_valarian.iff', 'tatooine', building.getCellByCellNumber(4), float(-21.5), float(9.0), float(0.5), float(0), float(0.70), float(0), float(-0.71))
|
||||
valarian.setCustomName('Lady Valarian')
|
||||
valarian.setOptionsBitmask(256)
|
||||
|
||||
#Medical Center Interior
|
||||
|
||||
#Theater Interior
|
||||
@@ -150,155 +155,165 @@ def addPlanetSpawns(core, planet):
|
||||
|
||||
#Outside
|
||||
businessman2 = stcSvc.spawnObject('object/mobile/shared_dressed_businessman_human_male_01.iff', 'tatooine', long(0), float(3663.3), float(4.0), float(-4738.6), float(0), float(0))
|
||||
businessman2.setCustomName2('a Businessman')
|
||||
businessman2.setCustomName('a Businessman')
|
||||
businessman2.setOptionsBitmask(256)
|
||||
|
||||
noble2 = stcSvc.spawnObject('object/mobile/shared_dressed_noble_human_female_01.iff', 'tatooine', long(0), float(3542.3), float(5.0), float(-4826.0), float(0.42), float(0.91))
|
||||
noble2.setCustomName2('a Noble')
|
||||
noble2.setCustomName('a Noble')
|
||||
noble2.setOptionsBitmask(256)
|
||||
|
||||
commoner11 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_naboo_human_male_06.iff', 'tatooine', long(0), float(3529.1), float(5.0), float(-4900.4), float(0.42), float(0.91))
|
||||
commoner11.setCustomName2('a Commoner')
|
||||
commoner11.setCustomName('a Commoner')
|
||||
commoner11.setOptionsBitmask(256)
|
||||
|
||||
businessman3 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_tatooine_trandoshan_male_02.iff', 'tatooine', long(0), float(3595.7), float(5.0), float(-4740.1), float(0), float(0))
|
||||
businessman3.setCustomName2('a Businessman')
|
||||
businessman3.setCustomName('a Businessman')
|
||||
businessman3.setOptionsBitmask(256)
|
||||
|
||||
jawa1 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3663.3), float(5.0), float(-4858.6), float(0), float(0))
|
||||
jawa1.setCustomName2('a Jawa')
|
||||
jawa1.setCustomName('a Jawa')
|
||||
jawa1.setOptionsBitmask(256)
|
||||
|
||||
commoner12 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_naboo_moncal_male_01.iff', 'tatooine', long(0), float(3490.3), float(5.0), float(-4799.4), float(0), float(0))
|
||||
commoner12.setCustomName2('a Scientist')
|
||||
commoner12.setCustomName('a Scientist')
|
||||
commoner12.setOptionsBitmask(256)
|
||||
|
||||
commoner13 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_naboo_zabrak_female_02.iff', 'tatooine', long(0), float(3559.7), float(5.0), float(-4725.9), float(0), float(0))
|
||||
commoner13.setCustomName2('a Commoner')
|
||||
commoner13.setCustomName('a Commoner')
|
||||
commoner13.setOptionsBitmask(256)
|
||||
|
||||
commoner14 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_tatooine_devaronian_male_01.iff', 'tatooine', long(0), float(3527.7), float(5.0), float(-4721.1), float(0.71), float(0.71))
|
||||
commoner14.setCustomName2('a Commoner')
|
||||
commoner14.setCustomName('a Commoner')
|
||||
commoner14.setOptionsBitmask(256)
|
||||
|
||||
commoner15 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_tatooine_aqualish_female_01.iff', 'tatooine', long(0), float(3514.9), float(5.0), float(-4737.8), float(0), float(0))
|
||||
commoner15.setCustomName2('a Commoner')
|
||||
commoner15.setCustomName('a Commoner')
|
||||
commoner15.setOptionsBitmask(256)
|
||||
|
||||
jawa2 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3485.2), float(4.9), float(-4859.2), float(0), float(0))
|
||||
jawa2.setCustomName2('a Jawa')
|
||||
jawa2.setCustomName('a Jawa')
|
||||
jawa2.setOptionsBitmask(256)
|
||||
|
||||
jawa3 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3465.3), float(5.0), float(-4860.1), float(0.71), float(-0.71))
|
||||
jawa3.setCustomName2('a Jawa')
|
||||
jawa3.setCustomName('a Jawa')
|
||||
jawa3.setOptionsBitmask(256)
|
||||
|
||||
jawa4 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3486.8), float(5.0), float(-4884.7), float(0.43051), float(-0.9025))
|
||||
jawa4.setCustomName2('a Jawa')
|
||||
jawa4.setCustomName('a Jawa')
|
||||
jawa4.setOptionsBitmask(256)
|
||||
|
||||
jawa5 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3487.1), float(5.0), float(-4886.0), float(0.95105), float(0.3090))
|
||||
jawa5.setCustomName2('a Jawa')
|
||||
jawa5.setCustomName('a Jawa')
|
||||
jawa5.setOptionsBitmask(256)
|
||||
|
||||
jawa6 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3488.8), float(5.0), float(-4884.4), float(0.3255), float(-0.9455))
|
||||
jawa6.setCustomName2('a Jawa')
|
||||
jawa6.setCustomName('a Jawa')
|
||||
jawa6.setOptionsBitmask(256)
|
||||
|
||||
jawa7 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3472.2), float(5.0), float(-4918.4), float(0), float(0))
|
||||
jawa7.setCustomName2('a Jawa')
|
||||
jawa7.setCustomName('a Jawa')
|
||||
jawa7.setOptionsBitmask(256)
|
||||
|
||||
jawa8 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3471.4), float(5.0), float(-4919.5), float(0), float(0))
|
||||
jawa8.setCustomName2('a Jawa')
|
||||
jawa8.setCustomName('a Jawa')
|
||||
jawa8.setOptionsBitmask(256)
|
||||
|
||||
jawa9 = stcSvc.spawnObject('object/mobile/shared_jawa.iff', 'tatooine', long(0), float(3470.3), float(5.0), float(-4918.7), float(0), float(0))
|
||||
jawa9.setCustomName2('a Jawa')
|
||||
jawa9.setCustomName('a Jawa')
|
||||
jawa9.setOptionsBitmask(256)
|
||||
|
||||
bib = stcSvc.spawnObject('object/mobile/shared_bib_fortuna.iff', 'tatooine', long(0), float(3552.4), float(5.0), float(-4933.2), float(0.31730), float(-0.9483))
|
||||
bib.setCustomName2('Bib Fortuna')
|
||||
bib.setCustomName('Bib Fortuna')
|
||||
bib.setOptionsBitmask(256)
|
||||
|
||||
commoner16 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_naboo_human_male_06.iff', 'tatooine', long(0), float(3398.2), float(4.0), float(-4654.2), float(0.42), float(0.91))
|
||||
commoner16.setCustomName2('a Commoner')
|
||||
commoner16.setCustomName('a Commoner')
|
||||
commoner16.setOptionsBitmask(256)
|
||||
|
||||
noble3 = stcSvc.spawnObject('object/mobile/shared_dressed_noble_human_female_01.iff', 'tatooine', long(0), float(3396.3), float(4.0), float(-4774.1), float(0.42), float(0.91))
|
||||
noble3.setCustomName2('a Noble')
|
||||
noble3.setCustomName('a Noble')
|
||||
noble3.setOptionsBitmask(256)
|
||||
|
||||
entertainer1 = stcSvc.spawnObject('object/mobile/shared_dressed_entertainer_trainer_twk_female_01.iff', 'tatooine', long(0), float(3305.7), float(5.6), float(-4771.7), float(0), float(0))
|
||||
entertainer1.setCustomName2('an Entertainer')
|
||||
entertainer1.setCustomName('an Entertainer')
|
||||
entertainer1.setOptionsBitmask(256)
|
||||
|
||||
r3m6 = stcSvc.spawnObject('object/mobile/shared_r3.iff', 'tatooine', long(0), float(3460.1), float(4.0), float(-4898.2), float(0.38), float(-0.92))
|
||||
r3m6.setCustomName2('R3-M6')
|
||||
r3m6.setCustomName('R3-M6')
|
||||
r3m6.setOptionsBitmask(256)
|
||||
|
||||
eg1 = stcSvc.spawnObject('object/mobile/shared_eg6_power_droid.iff', 'tatooine', long(0), float(3463.8), float(4.0), float(-4882.6), float(-0.38), float(0.92))
|
||||
eg1.setCustomName2('an EG-6 Power Droid')
|
||||
eg1.setCustomName('an EG-6 Power Droid')
|
||||
eg1.setOptionsBitmask(256)
|
||||
|
||||
commoner17 = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_naboo_zabrak_female_02.iff', 'tatooine', long(0), float(3452.6), float(4.0), float(-4937.1), float(0), float(0))
|
||||
commoner17.setCustomName2('a Commoner')
|
||||
commoner17.setCustomName('a Commoner')
|
||||
commoner17.setOptionsBitmask(256)
|
||||
|
||||
lifter1 = stcSvc.spawnObject('object/mobile/shared_cll8_binary_load_lifter.iff', 'tatooine', long(0), float(3547), float(5.0), float(-4768.9), float(0), float(0))
|
||||
lifter1.setCustomName2('a CLL-8 Binary Load Lifter')
|
||||
lifter1.setCustomName('a CLL-8 Binary Load Lifter')
|
||||
lifter1.setOptionsBitmask(256)
|
||||
|
||||
r3j7 = stcSvc.spawnObject('object/mobile/shared_r3.iff', 'tatooine', long(0), float(3311.1), float(4.0), float(-4820.2), float(0.38), float(-0.92))
|
||||
r3j7.setCustomName2('R3-J7')
|
||||
r3j7.setCustomName('R3-J7')
|
||||
r3j7.setOptionsBitmask(256)
|
||||
|
||||
noble4 = stcSvc.spawnObject('object/mobile/shared_dressed_noble_human_female_03.iff', 'tatooine', long(0), float(3255.3), float(4.0), float(-4848.1), float(0.42), float(0.91))
|
||||
noble4.setCustomName2('a Noble')
|
||||
noble4.setCustomName('a Noble')
|
||||
noble4.setOptionsBitmask(256)
|
||||
|
||||
byxlePedette = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_opening_byxle.iff', 'tatooine', long(0), float(3365), float(5), float(-4639), float(0.99), float(0.12))
|
||||
byxlePedette.setOptionsBitmask(264)
|
||||
|
||||
errikDarksider = stcSvc.spawnObject('object/mobile/shared_dressed_herald_tatooine_01.iff', 'tatooine', long(0), float(3381), float(4.6), float(-4498), float(0.91), float(0.40))
|
||||
errikDarksider.setCustomName2('Errik Darksider')
|
||||
errikDarksider.setCustomName('Errik Darksider')
|
||||
errikDarksider.setOptionsBitmask(256)
|
||||
|
||||
gendra = stcSvc.spawnObject('object/mobile/shared_dressed_gendra.iff', 'tatooine', long(0), float(3308), float(5.6), float(-4785), float(0.84), float(0.53))
|
||||
gendra.setOptionsBitmask(264)
|
||||
|
||||
lurval = stcSvc.spawnObject('object/mobile/shared_lurval.iff', 'tatooine', long(0), float(3387), float(5), float(-4791), float(-0.4), float(0.91))
|
||||
lurval.setCustomName2('Lurval')
|
||||
lurval.setCustomName('Lurval')
|
||||
lurval.setOptionsBitmask(256)
|
||||
|
||||
matildaCarson = stcSvc.spawnObject('object/mobile/shared_dressed_noble_human_female_02.iff', 'tatooine', long(0), float(3490.2), float(5), float(-4778), float(0.87), float(0.48))
|
||||
matildaCarson.setCustomName2('Matilda Carson')
|
||||
matildaCarson.setCustomName('Matilda Carson')
|
||||
matildaCarson.setOptionsBitmask(256)
|
||||
|
||||
vanvi = stcSvc.spawnObject('object/mobile/shared_dressed_bestine_artist01.iff', 'tatooine', long(0), float(3312), float(5), float(-4655), float(0.95), float(-0.28))
|
||||
vanvi.setCustomName2('Vanvi Hotn')
|
||||
vanvi.setCustomName('Vanvi Hotn')
|
||||
vanvi.setOptionsBitmask(256)
|
||||
|
||||
harburik = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_lt_harburik.iff', 'tatooine', long(0), float(3486), float(5), float(-4740), float(0), float(-0.71), float(0), float(0.71))
|
||||
harburik.setCustomName('Lt. Harburik')
|
||||
harburik.setOptionsBitmask(256)
|
||||
|
||||
trehla = stcSvc.spawnObject('object/mobile/shared_dressed_tutorial_mentor.iff', 'tatooine', long(0), float(3484), float(5), float(-4808), float(0), float(0.92), float(0), float(-0.38))
|
||||
trehla.setCustomName('Trehla Keelo')
|
||||
trehla.setOptionsBitmask(256)
|
||||
|
||||
#Eisley Legacy Quest NPCs
|
||||
|
||||
vourk = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_opening_santos.iff', 'tatooine', long(0), float(3520.0), float(5.0), float(-4821.0), float(0.42), float(0.91))
|
||||
vourk.setCustomName2('Vourk Ver\'Zremp')
|
||||
vourk.setCustomName('Vourk Ver\'Zremp')
|
||||
vourk.setOptionsBitmask(256)
|
||||
|
||||
mayor = stcSvc.spawnObject('object/mobile/shared_dressed_mayor_mikdanyell_guhrantt.iff', 'tatooine', long(1279960), float(1.2), float(2.5), float(5.4), float(0), float(0))
|
||||
building = core.objectService.getObject(long(1279956))
|
||||
mayor = stcSvc.spawnObject('object/mobile/shared_dressed_mayor_mikdanyell_guhrantt.iff', 'tatooine', building.getCellByCellNumber(4), float(1.2), float(2.5), float(5.4), float(0), float(0), float(0), float(0))
|
||||
#mayor.setOptionsBitmask(264)
|
||||
|
||||
enthaKandela = stcSvc.spawnObject('object/mobile/shared_dressed_entha_kandela.iff', 'tatooine', long(0), float(3511), float(5.0), float(-4785), float(0.70), float(0.71))
|
||||
enthaKandela.setCustomName2('Entha Kandela')
|
||||
enthaKandela.setCustomName('Entha Kandela')
|
||||
enthaKandela.setOptionsBitmask(256)
|
||||
|
||||
purvis = stcSvc.spawnObject('object/mobile/shared_dressed_purvis_arrison.iff', 'tatooine', long(0), float(3512.4), float(5.0), float(-4764.9), float(0.38), float(-0.92))
|
||||
purvis.setCustomName2('Purvis Arrison')
|
||||
purvis.setCustomName('Purvis Arrison')
|
||||
purvis.setOptionsBitmask(256)
|
||||
|
||||
peawpRdawc = stcSvc.spawnObject('object/mobile/shared_peawp_bodyguard_trainer.iff', 'tatooine', long(1189639), float(-11.8), float(1.1), float(-10.1), float(0), float(0))
|
||||
#peawpRdawc.setCustomName2('Peawp R\'dawc')
|
||||
#peawpRdawc.setOptionsBitmask(256)
|
||||
building = core.objectService.getObject(long(1189630))
|
||||
peawpRdawc = stcSvc.spawnObject('object/mobile/shared_peawp_bodyguard_trainer.iff', 'tatooine', building.getCellByCellNumber(9), float(-11.8), float(1.1), float(-10.1), float(0), float(0), float(0), float(0))
|
||||
peawpRdawc.setCustomName('Peawp R\'dawc')
|
||||
peawpRdawc.setOptionsBitmask(256)
|
||||
|
||||
nikoBrehe = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_opening_niko.iff', 'tatooine', long(0), float(3506.7), float(5.0), float(-4795.8), float(0.70), float(0.71))
|
||||
nikoBrehe.setOptionsBitmask(264)
|
||||
|
||||
@@ -0,0 +1,86 @@
|
||||
import sys
|
||||
# Project SWG: WT Bunker: Static Spawns
|
||||
# (C)2014 ProjectSWG
|
||||
|
||||
|
||||
|
||||
from resources.datatables import Options
|
||||
from resources.datatables import State
|
||||
|
||||
def addPlanetSpawns(core, planet):
|
||||
|
||||
|
||||
stcSvc = core.staticService
|
||||
objSvc = core.objectService
|
||||
|
||||
|
||||
#Outside
|
||||
wt_guard = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3749.7), float(16.8), float(-4200.5), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard1 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3761.2), float(16.1), float(-4188.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard2 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3740.9), float(15.6), float(-4188.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard3 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3731.1), float(16.0), float(-4184.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard4 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3724.7), float(16.2), float(-4184.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard5 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3709.9), float(17.1), float(-4192.1), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard6 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3718.3), float(16.2), float(-4193.1), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard7 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', long(0), float(3707), float(17.7), float(-4187.6), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
|
||||
#inside
|
||||
wt_bunker = core.objectService.getObject(long(-466404036409557111))
|
||||
|
||||
#1st room
|
||||
wt_reciptionist = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_opening_wh_receptionist.iff', 'tatooine', wt_bunker.getCellByCellNumber(5), float(-0.3), float(-12), float(34.4), float(0), float(0), float(0), float(0))
|
||||
wt_reciptionist.setOptionsBitmask(256)
|
||||
wt_reciptionist.setCustomName('White Thranta Reciptionist')
|
||||
|
||||
wt_guard8 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', wt_bunker.getCellByCellNumber(5), float(8.9), float(-12), float(50.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_guard9 = stcSvc.spawnObject('white_thranta_security_guard', 'tatooine', wt_bunker.getCellByCellNumber(5), float(-1.7), float(-12), float(51.1), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
wt_technican = stcSvc.spawnObject('white_thranta_technican', 'tatooine', wt_bunker.getCellByCellNumber(5), float(6.9), float(-12), float(39.5), float(0), float(0), float(0), float(0), 45)
|
||||
wt_technican.setOptionsBitmask(128)
|
||||
|
||||
wt_technican1 = stcSvc.spawnObject('white_thranta_technican', 'tatooine', wt_bunker.getCellByCellNumber(10), float(8.5), float(-16), float(133.7), float(0), float(0), float(0), float(0), 45)
|
||||
wt_technican2 = stcSvc.spawnObject('white_thranta_technican', 'tatooine', wt_bunker.getCellByCellNumber(10), float(-2.0), float(-16), float(133.7), float(0), float(0), float(0), float(0), 45)
|
||||
wt_technican3 = stcSvc.spawnObject('white_thranta_technican', 'tatooine', wt_bunker.getCellByCellNumber(10), float(6.6), float(-16), float(100.5), float(0), float(0), float(0), float(0), 45)
|
||||
wt_technican4 = stcSvc.spawnObject('white_thranta_technican', 'tatooine', wt_bunker.getCellByCellNumber(26), float(-74.9), float(-28), float(56.9), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
wt_officer = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(7), float(11), float(-16), float(79), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer1 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(18), float(-7.8), float(-12), float(91.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer2 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(20), float(-34.5), float(-12), float(93.1), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer3 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(20), float(-33.1), float(-12), float(114.2), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer4 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(20), float(-36.7), float(-12), float(119.7), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer5 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(10), float(25.1), float(-16), float(119.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer6 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(10), float(11.9), float(-16), float(121.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer7 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(29), float(-139.4), float(-44), float(79.4), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer8 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(29), float(-153), float(-44), float(90.6), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer9 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(26), float(-76.2), float(-28), float(74), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer10 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(26), float(-75.7), float(-28), float(69.4), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer11 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(32), float(-90.5), float(-44), float(-20.4), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer12 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(32), float(-59.9), float(-44), float(4.2), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer13 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(32), float(-86.2), float(-44), float(-9.3), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer14 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(17), float(-77), float(-28), float(95.6), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer15 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(17), float(-78.2), float(-28), float(126.4), float(0), float(0), float(0), float(0), 45)
|
||||
wt_officer16 = stcSvc.spawnObject('white_thranta_security_officer', 'tatooine', wt_bunker.getCellByCellNumber(17), float(-96.6), float(-28), float(110.6), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
wt_specialist = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(7), float(23.7), float(-16), float(79), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist1 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(18), float(-14.3), float(-12), float(86.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist2 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(18), float(-16.4), float(-12), float(96.6), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist3 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(10), float(-9.7), float(-16), float(115.5), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist4 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(10), float(-11), float(-16), float(126.5), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist5 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(10), float(-2.2), float(-16), float(104.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist6 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(26), float(-76.1), float(-28), float(55.2), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist7 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(32), float(-93.4), float(-44), float(-8.8), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist8 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(12), float(-23.3), float(-12), float(162.9), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist9 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(12), float(-33.2), float(-12), float(167.9), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist10 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(12), float(-31.4), float(-12), float(171.2), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist11 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(12), float(-27), float(-12), float(144), float(0), float(0), float(0), float(0), 45)
|
||||
wt_specialist12 = stcSvc.spawnObject('white_thranta_specialist', 'tatooine', wt_bunker.getCellByCellNumber(12), float(-33.3), float(-12), float(151.1), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
wt_manager = stcSvc.spawnObject('white_thranta_manager', 'tatooine', wt_bunker.getCellByCellNumber(20), float(-40.2), float(-12), float(87.5), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
wt_elite = stcSvc.spawnObject('white_thranta_security_elite', 'tatooine', wt_bunker.getCellByCellNumber(29), float(-137.8), float(-44), float(74.1), float(0), float(0), float(0), float(0), 45)
|
||||
wt_elite1 = stcSvc.spawnObject('white_thranta_security_elite', 'tatooine', wt_bunker.getCellByCellNumber(29), float(-159.3), float(-44), float(85.1), float(0), float(0), float(0), float(0), 45)
|
||||
|
||||
|
||||
return
|
||||
|
||||
@@ -260,7 +260,7 @@ public class NGECore {
|
||||
options.setFilePath("options.cfg");
|
||||
boolean optionsConfigLoaded = options.loadConfigFile();
|
||||
|
||||
if (optionsConfigLoaded && options.getInt("CLEAN.ODB.FOLDERS") > 0) {
|
||||
if (optionsConfigLoaded && options.getInt("CLEAN.ODB.FOLDERS") > 0 || getExcludedDevelopers().contains(System.getProperty("user.name"))){
|
||||
File baseFolder = new File("./odb");
|
||||
|
||||
if (baseFolder.isDirectory()) {
|
||||
@@ -790,5 +790,13 @@ public class NGECore {
|
||||
public void setMotd(String motd) {
|
||||
this.motd = motd;
|
||||
}
|
||||
|
||||
public Vector<String> getExcludedDevelopers(){
|
||||
Vector<String> excludedDevelopers = new Vector<String>();
|
||||
excludedDevelopers.add("Charon");
|
||||
// Feel free to add your OS user account name here to exclude yourself from loading buildouts and snapshots
|
||||
// without having to change options.cfg all the time
|
||||
return excludedDevelopers;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -33,10 +33,18 @@ public class StopClientEffectObjectByLabel extends SWGMessage {
|
||||
private long objectId;
|
||||
private String effectFile;
|
||||
private String commandString;
|
||||
private byte unknownFlag;
|
||||
|
||||
public StopClientEffectObjectByLabel(long objectId, String commandString) {
|
||||
this.objectId = objectId;
|
||||
this.commandString = commandString;
|
||||
this.unknownFlag = 1;
|
||||
}
|
||||
|
||||
public StopClientEffectObjectByLabel(long objectId, String commandString, byte unknownFlag) {
|
||||
this.objectId = objectId;
|
||||
this.commandString = commandString;
|
||||
this.unknownFlag = unknownFlag;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -48,7 +56,7 @@ public class StopClientEffectObjectByLabel extends SWGMessage {
|
||||
result.putInt(0xAD6F6B26);
|
||||
result.putLong(objectId);
|
||||
result.put(getAsciiString(commandString));
|
||||
result.put((byte) 1);
|
||||
result.put(unknownFlag);
|
||||
|
||||
return result.flip();
|
||||
|
||||
|
||||
@@ -108,5 +108,9 @@ public abstract class AbstractCollidable {
|
||||
public abstract Point3D getRandomPosition(Point3D origin, float minDistance, float maxDistance);
|
||||
public abstract Point3D getRandomPosition();
|
||||
|
||||
public Vector<SWGObject> getCollisionList() {
|
||||
return collidedObjects;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -210,9 +210,8 @@ public class BuildingObject extends TangibleObject implements IPersistent, Seria
|
||||
return getCustomName();
|
||||
}
|
||||
|
||||
public void setBuildingName(String buildingName, CreatureObject owner) {
|
||||
public void setBuildingName(String buildingName) {
|
||||
setCustomName(buildingName);
|
||||
((CreatureObject) owner).sendSystemMessage("Structure renamed.", DisplayType.Broadcast);
|
||||
SWGObject sign = (SWGObject) getAttachment("sign");
|
||||
if(sign != null)
|
||||
sign.setCustomName(buildingName);
|
||||
|
||||
@@ -1049,7 +1049,7 @@ public class DevService implements INetworkDispatch {
|
||||
colorCrystal.getAttributes().put("@obj_attr_n:condition", "100/100");
|
||||
colorCrystal.getAttributes().put("@obj_attr_n:crystal_owner", "\\#D1F56F UNTUNED \\#FFFFFF ");
|
||||
colorCrystal.setAttachment("radial_filename", "item/tunable");
|
||||
core.lootService.setCustomization(colorCrystal, "colorcrystal");
|
||||
core.lootService.setCustomization(colorCrystal, "colorcrystal",null,null);
|
||||
inventory.add(colorCrystal);
|
||||
|
||||
TangibleObject lavaCrystal = (TangibleObject) core.objectService.createObject("object/tangible/component/weapon/lightsaber/shared_lightsaber_module_lava_crystal.iff", planet);
|
||||
|
||||
@@ -39,7 +39,9 @@ import java.util.Map;
|
||||
import java.util.Random;
|
||||
import java.util.Vector;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
import protocol.swg.PlayClientEffectObjectTransformMessage;
|
||||
import protocol.swg.StopClientEffectObjectByLabel;
|
||||
import resources.objects.craft.DraftSchematic;
|
||||
import resources.common.OutOfBand;
|
||||
import resources.datatables.DisplayType;
|
||||
@@ -100,7 +102,7 @@ public class LootService implements INetworkDispatch {
|
||||
}
|
||||
SWGObject lootedObjectInventory = lootedObject.getSlottedObject("inventory");
|
||||
core.simulationService.openContainer(requester, lootedObjectInventory);
|
||||
setLooted(requester,lootedObject);
|
||||
//setLooted(requester,lootedObject);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -214,7 +216,7 @@ public class LootService implements INetworkDispatch {
|
||||
|
||||
// For autoloot
|
||||
//SWGObject requesterInventory = requester.getSlottedObject("inventory");
|
||||
System.out.println("lootRollSession.getDroppedItems() " + (lootRollSession.getDroppedItems()));
|
||||
//System.out.println("lootRollSession.getDroppedItems() " + (lootRollSession.getDroppedItems()));
|
||||
for (TangibleObject droppedItem : lootRollSession.getDroppedItems()){
|
||||
|
||||
//droppedItem.setAttachment("radial_filename", "lootitem");
|
||||
@@ -223,10 +225,9 @@ public class LootService implements INetworkDispatch {
|
||||
|
||||
// RLS chest effect
|
||||
if (droppedItem.getAttachment("LootItemName").toString().contains("Loot Chest")){
|
||||
requester.playEffectObject("appearance/pt_loot_chest.prt", "");
|
||||
if (requester.getClient().isGM()) {
|
||||
requester.sendSystemMessage("GM Message: Played rlc effect due to RLC dropping.", DisplayType.Broadcast);
|
||||
}
|
||||
|
||||
lootedObject.playEffectObject("appearance/pt_rare_chest.prt", "");
|
||||
requester.playMusic("sound/rare_loot_chest.snd");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -509,7 +510,7 @@ public class LootService implements INetworkDispatch {
|
||||
else
|
||||
remainder += span;
|
||||
if (randomItemFromGroup <= remainder){
|
||||
System.out.println("this loot pool will drop something"); // e.g. kraytpearl_range
|
||||
//System.out.println("this loot pool will drop something"); // e.g. kraytpearl_range
|
||||
handleLootPool(lootPoolNames[i],lootRollSession); // This loot pool will drop something
|
||||
test = true;
|
||||
break;
|
||||
@@ -520,7 +521,7 @@ public class LootService implements INetworkDispatch {
|
||||
}
|
||||
|
||||
private void handleLootPool(String poolName,LootRollSession lootRollSession){
|
||||
System.err.println("poolName.toLowerCase() " + poolName.toLowerCase());
|
||||
//System.err.println("poolName.toLowerCase() " + poolName.toLowerCase());
|
||||
// Fetch the loot pool data from the poolName.py script
|
||||
String path = "scripts/loot/lootPools/"+poolName.toLowerCase();
|
||||
Vector<String> itemNames = (Vector<String>)core.scriptService.fetchStringVector(path,"itemNames");
|
||||
@@ -727,7 +728,7 @@ public class LootService implements INetworkDispatch {
|
||||
// if (customizationValues!=null)
|
||||
// setCustomization(droppedItem, itemName);
|
||||
|
||||
setCustomization(droppedItem, itemName); // for now
|
||||
setCustomization(droppedItem, itemName, customizationAttributes, customizationValues); // for now
|
||||
|
||||
handleSpecialItems(droppedItem, itemName);
|
||||
|
||||
@@ -781,8 +782,8 @@ public class LootService implements INetworkDispatch {
|
||||
return droppedItem;
|
||||
}
|
||||
|
||||
private DraftSchematic createDroppedSchematic(String template,Planet planet){
|
||||
DraftSchematic droppedItem = (DraftSchematic) core.objectService.createObject(template, planet);
|
||||
private TangibleObject createDroppedSchematic(String template,Planet planet){
|
||||
TangibleObject droppedItem = (TangibleObject) core.objectService.createObject(template, planet);
|
||||
//System.out.println("droppedItem " + droppedItem);
|
||||
return droppedItem;
|
||||
}
|
||||
@@ -990,6 +991,7 @@ public class LootService implements INetworkDispatch {
|
||||
remainder += span;
|
||||
if (randomItemFromPool<=remainder){
|
||||
fillChest4(itemNames.get(i), owner, chest);
|
||||
//fillChest4("colorcrystal", owner, chest);
|
||||
//break;
|
||||
return;
|
||||
}
|
||||
@@ -1048,6 +1050,7 @@ public class LootService implements INetworkDispatch {
|
||||
Vector<String> itemStats = null;
|
||||
Vector<String> itemSkillMods = null;
|
||||
Vector<String> STFparams = null;
|
||||
Vector<String> addToCollections = null;
|
||||
|
||||
if(core.scriptService.getMethod(itemPath,"","itemTemplate")==null){
|
||||
String errorMessage = "Loot item '" + itemName + "' has no template function assigned in its script. Please contact Charon about this issue.";
|
||||
@@ -1113,6 +1116,9 @@ public class LootService implements INetworkDispatch {
|
||||
if(core.scriptService.getMethod(itemPath,"","STFparams")!=null)
|
||||
STFparams = (Vector<String>)core.scriptService.fetchStringVector(itemPath,"STFparams");
|
||||
|
||||
if(core.scriptService.getMethod(itemPath,"","AddToCollections")!=null)
|
||||
addToCollections = (Vector<String>)core.scriptService.fetchStringVector(itemPath,"AddToCollections");
|
||||
|
||||
|
||||
System.out.println("itemTemplate " + itemTemplate);
|
||||
|
||||
@@ -1164,7 +1170,7 @@ public class LootService implements INetworkDispatch {
|
||||
setSTFParams(droppedItem, STFparams);
|
||||
}
|
||||
|
||||
setCustomization(droppedItem, itemName); // for now
|
||||
setCustomization(droppedItem, itemName, customizationAttributes, customizationValues); // for now
|
||||
|
||||
handleSpecialItems(droppedItem, itemName);
|
||||
|
||||
@@ -1195,15 +1201,15 @@ public class LootService implements INetworkDispatch {
|
||||
droppedItem.getAttributes().put("@obj_attr_n:rare_loot_category", "\\#D1F56F Rare Item \\#FFFFFF ");
|
||||
SWGObject inventory = owner.getSlottedObject("inventory");
|
||||
inventory.add(droppedItem);
|
||||
System.out.println("ACTUAL DROP " + droppedItem.getTemplate());
|
||||
// System.out.println("ACTUAL DROP " + droppedItem.getTemplate());
|
||||
} else
|
||||
{
|
||||
DraftSchematic droppedSchematic = createDroppedSchematic(itemTemplate,owner.getPlanet());
|
||||
TangibleObject droppedSchematic = createDroppedSchematic(itemTemplate,owner.getPlanet());
|
||||
if (droppedSchematic!=null){
|
||||
droppedSchematic.getAttributes().put("@obj_attr_n:rare_loot_category", "\\#D1F56F Rare Item \\#FFFFFF ");
|
||||
SWGObject inventory = owner.getSlottedObject("inventory");
|
||||
inventory.add(droppedSchematic);
|
||||
System.out.println("ACTUAL DROP " + droppedSchematic.getTemplate());
|
||||
//System.out.println("ACTUAL DROP " + droppedSchematic.getTemplate());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1213,20 +1219,28 @@ public class LootService implements INetworkDispatch {
|
||||
|
||||
}
|
||||
|
||||
public void setCustomization(TangibleObject droppedItem,String itemName) {
|
||||
public void setCustomization(TangibleObject droppedItem,String itemName, Vector<String> customizationAttributes, Vector<Integer> customizationValues) {
|
||||
|
||||
// Example color crystal
|
||||
if (itemName.contains("colorcrystal")) {
|
||||
System.out.println("colorcrystal");
|
||||
|
||||
int crystalColor = new Random().nextInt(11);
|
||||
|
||||
droppedItem.setCustomizationVariable("/private/index_color_1", (byte) crystalColor);
|
||||
droppedItem.getAttributes().put("@obj_attr_n:condition", "100/100");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:crystal_owner", "\\#D1F56F UNTUNED \\#FFFFFF ");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:color", resources.datatables.LightsaberColors.get(crystalColor));
|
||||
droppedItem.setAttachment("radial_filename", "item/tunable");
|
||||
//droppedItem.getAttributes().put("@obj_attr_n:color", "@jedi_spam:saber_color_" + crystalColor); // Commented out for now
|
||||
if (customizationAttributes==null){
|
||||
int crystalColor = new Random().nextInt(11);
|
||||
|
||||
droppedItem.setCustomizationVariable("/private/index_color_1", (byte) crystalColor);
|
||||
droppedItem.getAttributes().put("@obj_attr_n:condition", "100/100");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:crystal_owner", "\\#D1F56F UNTUNED \\#FFFFFF ");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:color", resources.datatables.LightsaberColors.get(crystalColor));
|
||||
droppedItem.setAttachment("radial_filename", "item/tunable");
|
||||
//droppedItem.getAttributes().put("@obj_attr_n:color", "@jedi_spam:saber_color_" + crystalColor); // Commented out for now
|
||||
} else {
|
||||
for (int i=0; i<customizationAttributes.size();i++){
|
||||
int intValue = customizationValues.get(i);
|
||||
byte value = (byte) intValue;
|
||||
droppedItem.setCustomizationVariable(customizationAttributes.get(i), value);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1246,22 +1260,21 @@ public class LootService implements INetworkDispatch {
|
||||
if (saberColor==31) // Cunning of Tyranus, which is not in @jedi_spam
|
||||
saberColor=0;
|
||||
|
||||
droppedItem.setAttachment("radial_filename", "item/tunable");
|
||||
droppedItem.setCustomizationVariable("/private/index_color_1", (byte) saberColor);
|
||||
droppedItem.getAttributes().put("@obj_attr_n:condition", "100/100");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:crystal_owner", "\\#D1F56F UNTUNED \\#FFFFFF ");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:color", resources.datatables.LightsaberColors.get((Integer)droppedItem.getAttachment("customColor1")));
|
||||
droppedItem.setAttachment("radial_filename", "item/tunable");
|
||||
droppedItem.getAttributes().put("@obj_attr_n:color", resources.datatables.LightsaberColors.get((Integer)droppedItem.getAttachment("customColor1")));
|
||||
}
|
||||
|
||||
if (lootDescriptor.contains("customattributes")) {
|
||||
for (int i=0; i<customizationAttributes.size();i++){
|
||||
int intValue = customizationValues.get(i);
|
||||
byte value = (byte) intValue;
|
||||
droppedItem.setCustomizationVariable(customizationAttributes.get(i), value);
|
||||
}
|
||||
}
|
||||
|
||||
// More general
|
||||
// String path = "scripts/loot/lootItems/"+droppedItem.getCustomName().toLowerCase();
|
||||
// Vector<String> customizationPaths = (Vector<String>)core.scriptService.fetchStringVector(path,"itemCustomizationPaths");
|
||||
// Vector<Integer> customizationValues = (Vector<Integer>)core.scriptService.fetchIntegerVector(path,"itemCustomizationValues");
|
||||
// for (int i=0;i<customizationPaths.size();i++){
|
||||
// String attributePath = customizationPaths.get(i);
|
||||
// int attributeValue = customizationValues.get(i);
|
||||
// droppedItem.setCustomizationVariable(attributePath, (byte)attributeValue);
|
||||
// }
|
||||
}
|
||||
|
||||
public void handleSpecialItems(TangibleObject droppedItem,String itemName) {
|
||||
@@ -1855,14 +1868,10 @@ public class LootService implements INetworkDispatch {
|
||||
return 42%42;
|
||||
}
|
||||
|
||||
public void setLooted(TangibleObject lootedObject,TangibleObject requester){
|
||||
public void setLooted(CreatureObject requester,TangibleObject lootedObject){
|
||||
lootedObject.setLooted(true);
|
||||
float y = -5.0F;
|
||||
float qz= 1.06535322E9F;
|
||||
Point3D effectorPosition = new Point3D(0,y,0);
|
||||
Quaternion effectorOrientation = new Quaternion(0,0,0,qz);
|
||||
//PlayClientEffectObjectTransformMessage lmsg = new PlayClientEffectObjectTransformMessage("",lootedObject.getObjectID(),"",effectorPosition,effectorOrientation);
|
||||
//((CreatureObject) requester).getClient().getSession().write(lmsg.serialize());
|
||||
StopClientEffectObjectByLabel stopmsg = new StopClientEffectObjectByLabel(lootedObject.getObjectID(),"lootMe", (byte) 0);
|
||||
requester.getClient().getSession().write(stopmsg.serialize());
|
||||
}
|
||||
|
||||
private String setRandomStatsJewelry(TangibleObject droppedItem, LootRollSession lootRollSession){
|
||||
@@ -2159,10 +2168,10 @@ public class LootService implements INetworkDispatch {
|
||||
double lootGroupRoll = new Random().nextDouble()*100;
|
||||
|
||||
if (lootGroupRoll <= groupChance){
|
||||
System.out.println("this lootGroup will drop something");
|
||||
//System.out.println("this lootGroup will drop something");
|
||||
handleContainerLootGroup(lootGroup,lootRollSession, containerObject); //this lootGroup will drop something e.g. {kraytpearl_range,krayt_tissue_rare}
|
||||
}
|
||||
System.out.println("While Loop Stuck check");
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2372,7 +2381,7 @@ public class LootService implements INetworkDispatch {
|
||||
handleSkillMods(droppedItem, itemSkillMods);
|
||||
}
|
||||
|
||||
setCustomization(droppedItem, itemName); // for now
|
||||
setCustomization(droppedItem, itemName, customizationAttributes, customizationValues); // for now
|
||||
|
||||
handleSpecialItems(droppedItem, itemName);
|
||||
|
||||
@@ -2544,6 +2553,8 @@ public class LootService implements INetworkDispatch {
|
||||
TangibleObject item11 = (TangibleObject)core.objectService.createObject("object/tangible/loot/npc_loot/shared_armor_repair_device_generic.iff", player.getPlanet());
|
||||
item11.setCustomName("Armor Repair Device");
|
||||
playerInventory.add(item11);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -188,7 +188,7 @@ public class StaticService implements INetworkDispatch {
|
||||
|
||||
for (int i = 1; i <= portal.cellCount; i++) {
|
||||
long cellObjectId = core.objectService.getDOId(planetName, "object/cell/shared_cell.iff", 0, object.getObjectID(), i, x, y, z);
|
||||
CellObject childCell = (CellObject) core.objectService.createObject("object/cell/shared_cell.iff", cellObjectId, core.terrainService.getPlanetByName(planetName), new Point3D(0, 0, 0), new Quaternion(1, 0, 0, 0), null, true, true);
|
||||
CellObject childCell = (CellObject) core.objectService.createObject("object/cell/shared_cell.iff", cellObjectId, core.terrainService.getPlanetByName(planetName), new Point3D(0, 0, 0), new Quaternion(0, 0, 1, 0), null, true, true);
|
||||
childCell.setCellNumber(i);
|
||||
building.add(childCell);
|
||||
}
|
||||
|
||||
@@ -192,27 +192,31 @@ public class TerrainService {
|
||||
boolean loaded = config.loadConfigFile();
|
||||
|
||||
if (loaded && config.getInt("LOAD.SNAPSHOT_OBJECTS") > 0) {
|
||||
try {
|
||||
core.objectService.loadSnapshotObjects(planet);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
if (!core.getExcludedDevelopers().contains(System.getProperty("user.name"))){
|
||||
try {
|
||||
core.objectService.loadSnapshotObjects(planet);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (loaded && config.getInt("LOAD.BUILDOUT_OBJECTS") > 0) {
|
||||
if (! config.keyExists("LOAD.BUILDOUT_ONLY_FOR")){
|
||||
try {
|
||||
core.objectService.loadBuildoutObjects(planet);
|
||||
} catch (InstantiationException | IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else {
|
||||
if (planet.getName().equals(config.getString("LOAD.BUILDOUT_ONLY_FOR"))){
|
||||
if (!core.getExcludedDevelopers().contains(System.getProperty("user.name"))){
|
||||
if (! config.keyExists("LOAD.BUILDOUT_ONLY_FOR")){
|
||||
try {
|
||||
core.objectService.loadBuildoutObjects(planet);
|
||||
} catch (InstantiationException | IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
} else {
|
||||
if (planet.getName().equals(config.getString("LOAD.BUILDOUT_ONLY_FOR"))){
|
||||
try {
|
||||
core.objectService.loadBuildoutObjects(planet);
|
||||
} catch (InstantiationException | IllegalAccessException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ package services.bazaar;
|
||||
|
||||
import java.nio.ByteOrder;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -35,6 +36,10 @@ import java.util.concurrent.TimeUnit;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
import main.NGECore;
|
||||
import engine.clients.Client;
|
||||
import engine.resources.common.CRC;
|
||||
@@ -46,12 +51,15 @@ import engine.resources.service.INetworkDispatch;
|
||||
import engine.resources.service.INetworkRemoteEvent;
|
||||
import resources.common.Opcodes;
|
||||
import resources.common.OutOfBand;
|
||||
import resources.common.ProsePackage;
|
||||
import resources.datatables.DisplayType;
|
||||
import resources.objects.building.BuildingObject;
|
||||
import resources.objects.creature.CreatureObject;
|
||||
import resources.objects.intangible.IntangibleObject;
|
||||
import resources.objects.manufacture.ManufactureSchematicObject;
|
||||
import resources.objects.tangible.TangibleObject;
|
||||
import services.chat.Mail;
|
||||
import services.chat.WaypointAttachment;
|
||||
import protocol.swg.auctionManagerClientListener.AuctionQueryHeadersMessage;
|
||||
import protocol.swg.auctionManagerClientListener.AuctionQueryHeadersResponseMessage;
|
||||
import protocol.swg.auctionManagerClientListener.BidAuctionMessage;
|
||||
@@ -422,17 +430,60 @@ public class BazaarService implements INetworkDispatch {
|
||||
else
|
||||
retrieveExpire = timeUntilExpire + VENDOR_EXPIRE;
|
||||
|
||||
CreatureObject seller = (CreatureObject) core.objectService.getObject(item.getOwnerId());
|
||||
|
||||
item.setStatus(AuctionItem.SOLD);
|
||||
item.setBuyerId(player.getObjectID());
|
||||
item.setExpireTime(retrieveExpire);
|
||||
item.setBidderName(player.getCustomName());
|
||||
player.setBankCredits(player.getBankCredits() - item.getPrice());
|
||||
player.getClient().getSession().write(new BidAuctionResponseMessage(item.getObjectId(), BidAuctionResponseMessage.SUCCESS).serialize());
|
||||
|
||||
WaypointAttachment waypoint = new WaypointAttachment();
|
||||
waypoint.positionX = vendor.getWorldPosition().x;
|
||||
waypoint.positionZ = vendor.getWorldPosition().z;
|
||||
waypoint.planetCRC = CRC.StringtoCRC(vendor.getPlanet().getName());
|
||||
waypoint.name = vendor.getCustomName() == null ? vendor.getObjectName().getStfValue() : vendor.getCustomName();
|
||||
|
||||
// TODO send mail with WP
|
||||
Mail sellerMail = new Mail();
|
||||
Mail buyerMail = new Mail();
|
||||
|
||||
CreatureObject seller = (CreatureObject) core.objectService.getObject(item.getOwnerId());
|
||||
sellerMail.setMailId(NGECore.getInstance().chatService.generateMailId());
|
||||
sellerMail.setMessage("");
|
||||
sellerMail.setRecieverId(item.getOwnerId());
|
||||
sellerMail.setStatus(Mail.NEW);
|
||||
sellerMail.setTimeStamp((int) (new Date().getTime() / 1000));
|
||||
sellerMail.setSenderName("SWG." + core.getGalaxyName() + ".auctioner");
|
||||
if(item.isOnBazaar()) {
|
||||
sellerMail.setSubject("@auction:subject_instant_seller");
|
||||
sellerMail.addProseAttachment(new ProsePackage("@auction:seller_success", "TO", item.getObjectId(), item.getItemName(), "TT", player.getObjectID(), item.getBidderName(), "DI", item.getPrice()));
|
||||
} else {
|
||||
sellerMail.setSubject("@auction:subject_vendor_seller");
|
||||
sellerMail.addProseAttachment(new ProsePackage("@auction:seller_success_vendor", "TO", item.getObjectId(), item.getItemName(), "TT", player.getObjectID(), item.getBidderName(), "DI", item.getPrice()));
|
||||
}
|
||||
sellerMail.addProseAttachment(new ProsePackage("@auction:seller_success_location", "TO", 0, "@planet_n:" + vendor.getPlanet().getName(), "TT", 0, core.mapService.getClosestCityName(vendor)));
|
||||
sellerMail.addWaypointAttachment(waypoint);
|
||||
|
||||
buyerMail.setMailId(NGECore.getInstance().chatService.generateMailId());
|
||||
buyerMail.setMessage("");
|
||||
buyerMail.setRecieverId(player.getObjectID());
|
||||
buyerMail.setStatus(Mail.NEW);
|
||||
buyerMail.setTimeStamp((int) (new Date().getTime() / 1000));
|
||||
buyerMail.setSenderName("SWG." + core.getGalaxyName() + ".auctioner");
|
||||
if(item.isOnBazaar())
|
||||
buyerMail.setSubject("@auction:subject_instant_buyer");
|
||||
else
|
||||
buyerMail.setSubject("@auction:subject_vendor_buyer");
|
||||
buyerMail.addProseAttachment(new ProsePackage("@auction:buyer_success", "TO", item.getObjectId(), item.getItemName(), "TT", item.getOwnerId(), item.getOwnerName(), "DI", item.getPrice()));
|
||||
buyerMail.addProseAttachment(new ProsePackage("@auction:buyer_success_location", "TO", 0, "@planet_n:" + vendor.getPlanet().getName(), "TT", 0, core.mapService.getClosestCityName(vendor)));
|
||||
buyerMail.addWaypointAttachment(waypoint);
|
||||
|
||||
core.chatService.storePersistentMessage(buyerMail);
|
||||
core.chatService.storePersistentMessage(sellerMail);
|
||||
core.chatService.sendPersistentMessageHeader(player.getClient(), buyerMail);
|
||||
if(seller != null && seller.getClient() != null)
|
||||
core.chatService.sendPersistentMessageHeader(seller.getClient(), sellerMail);
|
||||
|
||||
if(seller == null) {
|
||||
seller = core.objectService.getCreatureFromDB(item.getOwnerId());
|
||||
seller.setBankCredits(seller.getBankCredits() + item.getPrice());
|
||||
|
||||
@@ -65,6 +65,7 @@ public class PvPZone {
|
||||
if (core.mountService.isMounted(actor)) {
|
||||
actor = (CreatureObject) actor.getContainer();
|
||||
}
|
||||
area.getCollisionList().remove(actor);
|
||||
core.simulationService.teleport(actor, (Point3D) actor.getAttachment("lastValidPosition"), actor.getOrientation(), actor.getParentId());
|
||||
}
|
||||
|
||||
|
||||
@@ -34,8 +34,15 @@ import java.util.Map;
|
||||
import java.util.Random;
|
||||
import java.util.Vector;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.Executors;
|
||||
import java.util.concurrent.ScheduledExecutorService;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.AtomicReference;
|
||||
|
||||
import main.NGECore;
|
||||
import protocol.swg.EnterStructurePlacementModeMessage;
|
||||
import resources.datatables.DisplayType;
|
||||
import resources.objects.building.BuildingObject;
|
||||
import resources.objects.creature.CreatureObject;
|
||||
import resources.objects.player.PlayerObject;
|
||||
@@ -55,6 +62,7 @@ public class HousingService implements INetworkDispatch {
|
||||
private NGECore core;
|
||||
private Map<String, HouseTemplate> housingTemplates = new ConcurrentHashMap<String, HouseTemplate>();
|
||||
private Map<String, String> houseToDeed = new ConcurrentHashMap<String, String>();
|
||||
private final ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1);
|
||||
|
||||
public HousingService(NGECore core) {
|
||||
this.core = core;
|
||||
@@ -139,8 +147,11 @@ public class HousingService implements INetworkDispatch {
|
||||
admins.add(actor.getObjectID());
|
||||
|
||||
building.setAttachment("sign", sign); // meh workaround
|
||||
building.setAttachment("nextMaintenance", System.currentTimeMillis() + 3600000);
|
||||
building.setAttachment("structureOwner", actor.getObjectID());
|
||||
building.setAttachment("structureAdmins", admins);
|
||||
building.setAttachment("isCondemned", false);
|
||||
building.setAttachment("outstandingMaint", 0);
|
||||
building.setDeedTemplate(deed.getTemplate());
|
||||
building.setMaintenanceAmount(houseTemplate.getBaseMaintenanceRate());
|
||||
building.setConditionDamage(100); // Ouch
|
||||
@@ -154,7 +165,7 @@ public class HousingService implements INetworkDispatch {
|
||||
// Check for city founders joining a new city
|
||||
PlayerCity cityActorIsIn = core.playerCityService.getCityObjectIsIn(actor);
|
||||
|
||||
if (cityActorIsIn!=null){
|
||||
if (cityActorIsIn!=null) {
|
||||
actor.setAttachment("Has24HZoningFor",cityActorIsIn.getCityID()); // for testing
|
||||
|
||||
int cityActorHasZoning = (int)actor.getAttachment("Has24HZoningFor");
|
||||
@@ -169,6 +180,46 @@ public class HousingService implements INetworkDispatch {
|
||||
}
|
||||
|
||||
core.objectService.persistObject(building.getObjectID(), building, core.getSWGObjectODB());
|
||||
|
||||
}
|
||||
|
||||
public void startMaintenanceTask(BuildingObject building) {
|
||||
|
||||
AtomicReference<ScheduledFuture<?>> ref = new AtomicReference<ScheduledFuture<?>>();
|
||||
ref.set(scheduler.scheduleAtFixedRate(() -> {
|
||||
|
||||
if(core.objectService.getObject(building.getObjectID()) == null)
|
||||
ref.get().cancel(true);
|
||||
|
||||
int amount = building.getBMR();
|
||||
boolean needSave = false;
|
||||
CreatureObject owner = (CreatureObject) core.objectService.getObject((long) building.getAttachment("structureOwner"));
|
||||
if(owner == null) {
|
||||
needSave = true;
|
||||
owner = core.objectService.getCreatureFromDB((long) building.getAttachment("structureOwner"));
|
||||
}
|
||||
if(building.getMaintenanceAmount() >= amount) {
|
||||
building.setMaintenanceAmount(building.getMaintenanceAmount() - amount);
|
||||
} else {
|
||||
if(owner == null)
|
||||
ref.get().cancel(true);
|
||||
if(owner.getBankCredits() >= amount) {
|
||||
owner.setBankCredits(owner.getBankCredits() - amount);
|
||||
} else if(owner.getCashCredits() >= amount) {
|
||||
owner.setCashCredits(owner.getCashCredits() - amount);
|
||||
} else {
|
||||
if(building.getAttachment("isCondemned") != null && !((boolean) building.getAttachment("isCondemned"))) {
|
||||
building.setAttachment("isCondemned", true);
|
||||
building.setBuildingName(building.getBuildingName() + " \\#FF0000(CONDEMNED)\\#FFFFFF");
|
||||
}
|
||||
building.setAttachment("outstandingMaint", (int) building.getAttachment("outstandingMaint") + amount);
|
||||
// TODO: lock down building, add option to pay outstanding maintenance and uncondemn building
|
||||
}
|
||||
}
|
||||
if(needSave && owner != null)
|
||||
core.objectService.persistObject(owner.getObjectID(), owner, core.getSWGObjectODB());
|
||||
|
||||
}, (long) building.getAttachment("nextMaintenance") - System.currentTimeMillis(), 3600000, TimeUnit.MILLISECONDS));
|
||||
|
||||
}
|
||||
|
||||
@@ -292,6 +343,8 @@ public class HousingService implements INetworkDispatch {
|
||||
deed.setIntAttribute("@obj_attr_n:examine_maintenance", (int) building.getMaintenanceAmount());
|
||||
|
||||
core.objectService.destroyObject(building.getObjectID());
|
||||
if(building.getAttachment("sign") != null)
|
||||
core.objectService.destroyObject((SWGObject) building.getAttachment("sign"));
|
||||
|
||||
SWGObject ownerInventory = owner.getSlottedObject("inventory");
|
||||
ownerInventory.add(deed);
|
||||
@@ -394,8 +447,8 @@ public class HousingService implements INetworkDispatch {
|
||||
}
|
||||
|
||||
public void handleSetName(CreatureObject owner, TangibleObject target,String name) {
|
||||
|
||||
((BuildingObject) target).setBuildingName(name,owner);
|
||||
((BuildingObject) target).setBuildingName(name);
|
||||
owner.sendSystemMessage("Structure renamed.", DisplayType.Broadcast);
|
||||
}
|
||||
|
||||
public void createStatusSUIPage(SWGObject owner, TangibleObject target) {
|
||||
|
||||
@@ -205,6 +205,8 @@ public class ObjectService implements INetworkDispatch {
|
||||
sign.initAfterDBLoad();
|
||||
objectList.put(sign.getObjectID(), sign);
|
||||
}
|
||||
if(building.getAttachment("structureOwner") != null && ((BuildingObject) building).getMaintenanceAmount() > 0)
|
||||
core.housingService.startMaintenanceTask((BuildingObject) building);
|
||||
}
|
||||
|
||||
cursor.close();
|
||||
|
||||
@@ -184,6 +184,13 @@ public class SUIService implements INetworkDispatch {
|
||||
core.scriptService.callScript("scripts/radial/", "terminal/vendor", "handleSelection", core, owner, target, objMenuSelect.getSelection());
|
||||
return;
|
||||
}
|
||||
|
||||
if(target.getGrandparent() != null && target.getGrandparent().getAttachment("structureAdmins") != null) {
|
||||
if(core.housingService.getPermissions(owner, target.getContainer()) && !getRadialFilename(target).equals("structure/structure_management_terminal")) {
|
||||
core.scriptService.callScript("scripts/radial/", "structure/moveable", "handleSelection", core, owner, target, objMenuSelect.getSelection());
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
core.scriptService.callScript("scripts/radial/", getRadialFilename(target), "handleSelection", core, owner, target, objMenuSelect.getSelection());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user