diff --git a/ngengine_public.jar b/ngengine_public.jar index d64a9419..079df450 100644 Binary files a/ngengine_public.jar and b/ngengine_public.jar differ diff --git a/scripts/loot/lootItems/exceptionallootchest/advertisement_rodian.py b/scripts/loot/lootItems/exceptionallootchest/advertisement_rodian.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/advertisement_rodian.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/exceptionallootchest/bacta_tank.py b/scripts/loot/lootItems/exceptionallootchest/bacta_tank.py new file mode 100644 index 00000000..46704737 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/bacta_tank.py @@ -0,0 +1,5 @@ + +def itemTemplate(): + + return ['object/tangible/loot/generic_usable/shared_bacta_tank.iff'] + diff --git a/scripts/loot/lootItems/exceptionallootchest/cunning_of_tyranus.py b/scripts/loot/lootItems/exceptionallootchest/cunning_of_tyranus.py new file mode 100644 index 00000000..fe363b99 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/cunning_of_tyranus.py @@ -0,0 +1,23 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] + +def customItemName(): + + return "Cunning Of Tyranus" + +def customColor1(): + + return 0 + +def lootDescriptor(): + + return 'rarecolorcrystal' + +def itemStats(): + + stats = ['elemtype','heat','heat'] + stats +=['elemdamage','6','6'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/dna_storage_device.py b/scripts/loot/lootItems/exceptionallootchest/dna_storage_device.py new file mode 100644 index 00000000..43ca2f4a --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/dna_storage_device.py @@ -0,0 +1,5 @@ + +def itemTemplate(): + + return ['object/tangible/item/beast/barn_lite/shared_beast_dna_storage_device.iff'] + diff --git a/scripts/loot/lootItems/exceptionallootchest/dusk_in_kachirho.py b/scripts/loot/lootItems/exceptionallootchest/dusk_in_kachirho.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/dusk_in_kachirho.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/exceptionallootchest/emperors_senate_office_chair.py b/scripts/loot/lootItems/exceptionallootchest/emperors_senate_office_chair.py new file mode 100644 index 00000000..d52cedd2 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/emperors_senate_office_chair.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_emperor_chair.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/fighter.py b/scripts/loot/lootItems/exceptionallootchest/fighter.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/fighter.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_1_schematic.py b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_1_schematic.py new file mode 100644 index 00000000..a6ba0c1b --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_1_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_statue_gungan_statue_s01.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_2_schematic.py b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_2_schematic.py new file mode 100644 index 00000000..f71c1747 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_2_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_statue_gungan_statue_s02.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_3_schematic.py b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_3_schematic.py new file mode 100644 index 00000000..65ea76df --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_3_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_statue_gungan_statue_s03.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_4_schematic.py b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_4_schematic.py new file mode 100644 index 00000000..479dcb1c --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/gungan_statue_style_4_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_statue_gungan_statue_s04.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/holo_entertainment_table.py b/scripts/loot/lootItems/exceptionallootchest/holo_entertainment_table.py new file mode 100644 index 00000000..bfe4cd74 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/holo_entertainment_table.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/event_perk/shared_lifeday_holo_table.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/jedi_master_cloak.py b/scripts/loot/lootItems/exceptionallootchest/jedi_master_cloak.py new file mode 100644 index 00000000..f8b19b7f --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/jedi_master_cloak.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/wearables/robe/shared_robe_s05_h1.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py b/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py new file mode 100644 index 00000000..7550577b --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/ranged/carbine/shared_carbine_e5_legend.iff'] + +def customItemName(): + + return 'Legendary E5 Carbine' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','400','450'] + stats += ['maxdamage','850','900'] + stats += ['attackspeed','0.6','0.6'] + stats += ['maxrange','0','50'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_electricity','@obj_attr_n:elemental_electricity'] + stats += ['elemdamage','23','23'] + stats += ['weapontype','1','1'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py b/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py new file mode 100644 index 00000000..81e1e8b5 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/ranged/pistol/shared_pistol_fwg5_legendary.iff'] + +def customItemName(): + + return 'Legendary FWG5 Pistol' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','250','270'] + stats += ['maxdamage','500','530'] + stats += ['attackspeed','0.4','0.4'] + stats += ['maxrange','0','35'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_heat','@obj_attr_n:elemental_heat'] + stats += ['elemdamage','35','35'] + stats += ['weapontype','2','2'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py b/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py new file mode 100644 index 00000000..58756024 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/melee/polearm/shared_lance_nightsister_legendary.iff'] + +def customItemName(): + + return 'Legendary Nightsister Energy Lance' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','750','800'] + stats += ['maxdamage','1100','1200'] + stats += ['attackspeed','1.0','1.0'] + stats += ['maxrange','0','5'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_electricity','@obj_attr_n:elemental_electricity'] + stats += ['elemdamage','50','50'] + stats += ['weapontype','7','7'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py b/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py new file mode 100644 index 00000000..3224b384 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/melee/2h_sword/shared_quest_2h_sword_battleaxe.iff'] + +def customItemName(): + + return 'Legendary Power Hammer' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','850','900'] + stats += ['maxdamage','1250','1350'] + stats += ['attackspeed','1.0','1.0'] + stats += ['maxrange','0','5'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_acid','@obj_attr_n:elemental_acid'] + stats += ['elemdamage','20','20'] + stats += ['weapontype','5','5'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py b/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py new file mode 100644 index 00000000..cbc9cb70 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/melee/baton/shared_baton_stun_legendary.iff'] + +def customItemName(): + + return 'Legendary Stun Baton' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','550','600'] + stats += ['maxdamage','1250','1300'] + stats += ['attackspeed','1.0','1.0'] + stats += ['maxrange','0','5'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_electricity','@obj_attr_n:elemental_electricity'] + stats += ['elemdamage','75','75'] + stats += ['weapontype','5','5'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py b/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py new file mode 100644 index 00000000..66a8dd30 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py @@ -0,0 +1,37 @@ + +def itemTemplate(): + + return ['object/weapon/ranged/rifle/shared_rifle_t21_legendary.iff'] + +def customItemName(): + + return 'Legendary T21 Rifle' + +def customItemStackCount(): + + return 1 + +def customizationAttributes(): + + return [] + +def customizationValues(): + + return [] + +def requiredCL(): + + return 88 + +def itemStats(): + + stats = ['mindamage','500','550'] + stats += ['maxdamage','1050','1100'] + stats += ['attackspeed','0.8','0.8'] + stats += ['maxrange','0','64'] + stats += ['damagetype','energy','energy'] + stats += ['elemtype','@obj_attr_n:elemental_acid','@obj_attr_n:elemental_acid'] + stats += ['elemdamage','30','30'] + stats += ['weapontype','0','0'] + + return stats diff --git a/scripts/loot/lootItems/exceptionallootchest/poster_block_turret_schematic.py b/scripts/loot/lootItems/exceptionallootchest/poster_block_turret_schematic.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/poster_block_turret_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/exceptionallootchest/prayer_mobile.py b/scripts/loot/lootItems/exceptionallootchest/prayer_mobile.py new file mode 100644 index 00000000..4009eb8a --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/prayer_mobile.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/ep3_rewards/shared_wke_prayer_mobile.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/shard_of_ferocity.py b/scripts/loot/lootItems/exceptionallootchest/shard_of_ferocity.py new file mode 100644 index 00000000..26186612 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/shard_of_ferocity.py @@ -0,0 +1,26 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] + +def customItemName(): + + return "Shard Of Ferocity" + +def biolink(): + + return 1 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','towCrystalUberCombat','towCrystalUberCombat'] + stats +=['effectname','Ferocity','Ferocity'] + stats +=['duration','180','180'] + stats +=['cooldown','3600','3600'] + + return stats + diff --git a/scripts/loot/lootItems/exceptionallootchest/shard_of_retaliation.py b/scripts/loot/lootItems/exceptionallootchest/shard_of_retaliation.py new file mode 100644 index 00000000..4bb1e5bc --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/shard_of_retaliation.py @@ -0,0 +1,25 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] # correct iff not found + +def customItemName(): + + return "Shard Of Retaliation" + +def biolink(): + + return 1 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','towCrystalUberDs','towCrystalUberDs'] + stats +=['effectname','towCrystalUberDs','towCrystalUberDs'] + stats +=['duration','180','180'] + stats +=['cooldown','3600','3600'] + + return stats \ No newline at end of file diff --git a/scripts/loot/lootItems/exceptionallootchest/sith_buff_holocron.py b/scripts/loot/lootItems/exceptionallootchest/sith_buff_holocron.py new file mode 100644 index 00000000..65658e9b --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/sith_buff_holocron.py @@ -0,0 +1,25 @@ + +def itemTemplate(): + + return ['object/tangible/loot/creature_loot/collections/shared_sith_holocron_01.iff'] + +def customItemName(): + + return 'Sith Holocron' + +def biolink(): + + return 1 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','towCrystalABImmune','towCrystalABImmune'] + stats +=['effectname','Forbidden Knowledge I','Forbidden Knowledge I'] + stats +=['duration','180','180'] + stats +=['cooldown','3600','3600'] + + return stats \ No newline at end of file diff --git a/scripts/loot/lootItems/exceptionallootchest/sith_relic.py b/scripts/loot/lootItems/exceptionallootchest/sith_relic.py new file mode 100644 index 00000000..007516fd --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/sith_relic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/loot/mustafar/shared_sith_relic_01.iff'] diff --git a/scripts/loot/lootItems/exceptionallootchest/war_phoenix.py b/scripts/loot/lootItems/exceptionallootchest/war_phoenix.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/exceptionallootchest/war_phoenix.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/biological_focus_crystal.py b/scripts/loot/lootItems/legendarylootchest/biological_focus_crystal.py new file mode 100644 index 00000000..f86494d1 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/biological_focus_crystal.py @@ -0,0 +1,29 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_crystal_health.iff'] # needs correct iff still + +def customItemName(): + + return "Biological Focus Crystal" + +def requiredLevelForEffect(): + + return 80 + +def biolink(): + + return 1 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','forceCrystalHealth','forceCrystalHealth'] + stats +=['effectname','Extended Constitution','Extended Constitution'] + stats +=['duration','10800','10800'] + stats +=['cooldown','86400','86400'] + + return stats diff --git a/scripts/loot/lootItems/legendarylootchest/concentrated_bacta_tank.py b/scripts/loot/lootItems/legendarylootchest/concentrated_bacta_tank.py new file mode 100644 index 00000000..e79e3e71 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/concentrated_bacta_tank.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/static/item/shared_item_medic_bacta_tank_advanced.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/dna_storage_device_kowakian.py b/scripts/loot/lootItems/legendarylootchest/dna_storage_device_kowakian.py new file mode 100644 index 00000000..43ca2f4a --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/dna_storage_device_kowakian.py @@ -0,0 +1,5 @@ + +def itemTemplate(): + + return ['object/tangible/item/beast/barn_lite/shared_beast_dna_storage_device.iff'] + diff --git a/scripts/loot/lootItems/legendarylootchest/dug_costume_instructions.py b/scripts/loot/lootItems/legendarylootchest/dug_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/dug_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/mercenaries_despair.py b/scripts/loot/lootItems/legendarylootchest/mercenaries_despair.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/mercenaries_despair.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/mercenaries_lament.py b/scripts/loot/lootItems/legendarylootchest/mercenaries_lament.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/mercenaries_lament.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/nightsister_melee_armguard.py b/scripts/loot/lootItems/legendarylootchest/nightsister_melee_armguard.py new file mode 100644 index 00000000..7c8d6cf8 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/nightsister_melee_armguard.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/wearables/armor/nightsister/shared_armor_nightsister_bicep_r_s01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/rare_painting.py b/scripts/loot/lootItems/legendarylootchest/rare_painting.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/rare_painting.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/legendarylootchest/sunriders_destiny.py b/scripts/loot/lootItems/legendarylootchest/sunriders_destiny.py new file mode 100644 index 00000000..b17aca6b --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/sunriders_destiny.py @@ -0,0 +1,23 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] + +def customItemName(): + + return "Sunrider's Destiny" + +def customColor1(): + + return 29 + +def lootDescriptor(): + + return 'rarecolorcrystal' + +def itemStats(): + + stats = ['elemtype','heat','heat'] + stats +=['elemdamage','6','6'] + + return stats diff --git a/scripts/loot/lootItems/legendarylootchest/synapse_focus_crystal.py b/scripts/loot/lootItems/legendarylootchest/synapse_focus_crystal.py new file mode 100644 index 00000000..94e070ed --- /dev/null +++ b/scripts/loot/lootItems/legendarylootchest/synapse_focus_crystal.py @@ -0,0 +1,29 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_crystal_force.iff'] # needs correct iff still + +def customItemName(): + + return "Synapse Focus Crystal" + +def requiredLevelForEffect(): + + return 80 + +def biolink(): + + return 1 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','forceCrystalForce','forceCrystalForce'] + stats +=['effectname','Extended Action','Extended Action'] + stats +=['duration','10800','10800'] + stats +=['cooldown','86400','86400'] + + return stats diff --git a/scripts/loot/lootItems/rareloot/lava_geode.py b/scripts/loot/lootItems/rareloot/lava_geode.py new file mode 100644 index 00000000..610f4b8c --- /dev/null +++ b/scripts/loot/lootItems/rareloot/lava_geode.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/loot/mustafar/shared_lava_geode.iff'] \ No newline at end of file diff --git a/scripts/loot/lootItems/rareloot/rarelootchest1.py b/scripts/loot/lootItems/rareloot/rarelootchest1.py index a7568822..1ba9ecc8 100644 --- a/scripts/loot/lootItems/rareloot/rarelootchest1.py +++ b/scripts/loot/lootItems/rareloot/rarelootchest1.py @@ -1,7 +1,7 @@ def itemTemplate(): - return ['object/tangible/item/shared_rare_loot_chest_3.iff'] + return ['object/tangible/loot/mustafar/shared_rare_loot_chest_3.iff'] def customItemName(): diff --git a/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_1.py b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_1.py new file mode 100644 index 00000000..26f9ce06 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_1.py @@ -0,0 +1,7 @@ + +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'] + diff --git a/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_2.py b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_2.py new file mode 100644 index 00000000..7e5d20d4 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_2.py @@ -0,0 +1,7 @@ + +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'] + diff --git a/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_3.py b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_3.py new file mode 100644 index 00000000..31df3dc8 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_3.py @@ -0,0 +1,7 @@ + +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'] + diff --git a/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_4.py b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_4.py new file mode 100644 index 00000000..d2a90a57 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/animal_hide_rack_style_4.py @@ -0,0 +1,7 @@ + +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'] + diff --git a/scripts/loot/lootItems/rarelootchest/at_st_pilots_helmet.py b/scripts/loot/lootItems/rarelootchest/at_st_pilots_helmet.py new file mode 100644 index 00000000..5f2421f7 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/at_st_pilots_helmet.py @@ -0,0 +1,9 @@ + +def itemTemplate(): + + return ['object/tangible/wearables/helmet/shared_helmet_atat.iff'] # iff not exact, tre files suck + +#def customItemName(): +# +# return 'Adjusted CDEF Rifle' + diff --git a/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_1.py b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_1.py new file mode 100644 index 00000000..04cbdebb --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_1.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_sculpture_1.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_2.py b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_2.py new file mode 100644 index 00000000..1830c89e --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_2.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_sculpture_2.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_3.py b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_3.py new file mode 100644 index 00000000..76ece5d6 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_3.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_sculpture_3.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_4.py b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_4.py new file mode 100644 index 00000000..f96fb1db --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/aurilian_sculpture_section_4.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/quest/force_sensitive/shared_fs_sculpture_4.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/banes_heart.py b/scripts/loot/lootItems/rarelootchest/banes_heart.py new file mode 100644 index 00000000..e7a0db2b --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/banes_heart.py @@ -0,0 +1,23 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] + +def customItemName(): + + return "Bane's Heart" + +def customColor1(): + + return 16 + +def lootDescriptor(): + + return 'rarecolorcrystal' + +def itemStats(): + + stats = ['elemtype','electricity','electricity'] + stats +=['elemdamage','5','5'] + + return stats diff --git a/scripts/loot/lootItems/rarelootchest/bar_corner_piece_1.py b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_1.py new file mode 100644 index 00000000..2a8d9aca --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_1.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/bar_corner_piece_2.py b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_2.py new file mode 100644 index 00000000..2a8d9aca --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_2.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/bar_corner_piece_3.py b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_3.py new file mode 100644 index 00000000..2a8d9aca --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bar_corner_piece_3.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/bar_counter_large.py b/scripts/loot/lootItems/rarelootchest/bar_counter_large.py new file mode 100644 index 00000000..2a8d9aca --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bar_counter_large.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_diner_counter_corner.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/bothan_beauty.py b/scripts/loot/lootItems/rarelootchest/bothan_beauty.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bothan_beauty.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/bothan_buff.py b/scripts/loot/lootItems/rarelootchest/bothan_buff.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/bothan_buff.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/cast_wing_in_flight.py b/scripts/loot/lootItems/rarelootchest/cast_wing_in_flight.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/cast_wing_in_flight.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/corellian_seaside.py b/scripts/loot/lootItems/rarelootchest/corellian_seaside.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/corellian_seaside.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/data_disk_hologram.py b/scripts/loot/lootItems/rarelootchest/data_disk_hologram.py new file mode 100644 index 00000000..0a34621e --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/data_disk_hologram.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_frn_hologram_data_disk_s01.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/decorative_bubble_tank.py b/scripts/loot/lootItems/rarelootchest/decorative_bubble_tank.py new file mode 100644 index 00000000..a308bef3 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/decorative_bubble_tank.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/loot/loot_schematic/shared_bubble_tank_schematic.iff'] # needs visual verification diff --git a/scripts/loot/lootItems/rarelootchest/droid_in_contrast.py b/scripts/loot/lootItems/rarelootchest/droid_in_contrast.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/droid_in_contrast.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/drum.py b/scripts/loot/lootItems/rarelootchest/drum.py new file mode 100644 index 00000000..d4120e07 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/drum.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/container/drum/shared_warren_drum_loot.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/emperors_eyes.py b/scripts/loot/lootItems/rarelootchest/emperors_eyes.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/emperors_eyes.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/family_bonds.py b/scripts/loot/lootItems/rarelootchest/family_bonds.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/family_bonds.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/feared.py b/scripts/loot/lootItems/rarelootchest/feared.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/feared.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/fighter_study.py b/scripts/loot/lootItems/rarelootchest/fighter_study.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/fighter_study.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/fighters_courage.py b/scripts/loot/lootItems/rarelootchest/fighters_courage.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/fighters_courage.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/geonosian_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/geonosian_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/geonosian_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/hanging_life_day_orb.py b/scripts/loot/lootItems/rarelootchest/hanging_life_day_orb.py new file mode 100644 index 00000000..24ff425b --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/hanging_life_day_orb.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday07_orb.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/hutt_greed.py b/scripts/loot/lootItems/rarelootchest/hutt_greed.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/hutt_greed.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/imperial_oppression.py b/scripts/loot/lootItems/rarelootchest/imperial_oppression.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/imperial_oppression.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/jedi_statue_schematic.py b/scripts/loot/lootItems/rarelootchest/jedi_statue_schematic.py new file mode 100644 index 00000000..0e8ba392 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/jedi_statue_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_must_furniture_jedi_statue.iff'] # needs verification diff --git a/scripts/loot/lootItems/rarelootchest/jubilee_wheel_schematic.py b/scripts/loot/lootItems/rarelootchest/jubilee_wheel_schematic.py new file mode 100644 index 00000000..596fcbdd --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/jubilee_wheel_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/object/shared_hoverlifter_speeder_crafted.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/kachirho_wall_cornucopia.py b/scripts/loot/lootItems/rarelootchest/kachirho_wall_cornucopia.py new file mode 100644 index 00000000..85a71191 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/kachirho_wall_cornucopia.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/ep3/shared_poi_kash_mystic_tree_healthy.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/kowakian_cage.py b/scripts/loot/lootItems/rarelootchest/kowakian_cage.py new file mode 100644 index 00000000..810362f8 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/kowakian_cage.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/event_perk/shared_lifeday_monkey_cage.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/krayt_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/krayt_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/krayt_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/large_fruit_stand_schematic.py b/scripts/loot/lootItems/rarelootchest/large_fruit_stand_schematic.py new file mode 100644 index 00000000..9f57dba9 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/large_fruit_stand_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/event_perk/shared_fruit_stand.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/large_unmarked_crate.py b/scripts/loot/lootItems/rarelootchest/large_unmarked_crate.py new file mode 100644 index 00000000..6393f2b9 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/large_unmarked_crate.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/container/drum/shared_large_plain_crate_s01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/lava_geode.py b/scripts/loot/lootItems/rarelootchest/lava_geode.py new file mode 100644 index 00000000..610f4b8c --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/lava_geode.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/loot/mustafar/shared_lava_geode.iff'] \ No newline at end of file diff --git a/scripts/loot/lootItems/rarelootchest/life_day_lamp.py b/scripts/loot/lootItems/rarelootchest/life_day_lamp.py new file mode 100644 index 00000000..37616eb5 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/life_day_lamp.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday07_lamp.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/life_day_proud_wookie.py b/scripts/loot/lootItems/rarelootchest/life_day_proud_wookie.py new file mode 100644 index 00000000..d6bdaef5 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/life_day_proud_wookie.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday07_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/life_day_red_robed_wookie.py b/scripts/loot/lootItems/rarelootchest/life_day_red_robed_wookie.py new file mode 100644 index 00000000..d6bdaef5 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/life_day_red_robed_wookie.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday07_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/living_canals.py b/scripts/loot/lootItems/rarelootchest/living_canals.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/living_canals.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/lugjack_machine_schematic.py b/scripts/loot/lootItems/rarelootchest/lugjack_machine_schematic.py new file mode 100644 index 00000000..7715cf97 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/lugjack_machine_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/furniture/shared_furniture_uber_lugjack.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/miniature_wroshyr_tree.py b/scripts/loot/lootItems/rarelootchest/miniature_wroshyr_tree.py new file mode 100644 index 00000000..85a71191 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/miniature_wroshyr_tree.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/ep3/shared_poi_kash_mystic_tree_healthy.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/modified_fusion_reactor_schematic.py b/scripts/loot/lootItems/rarelootchest/modified_fusion_reactor_schematic.py new file mode 100644 index 00000000..b1bcf947 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/modified_fusion_reactor_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/deed/generator_deed/shared_generator_fusion_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/mustafarian_injector.py b/scripts/loot/lootItems/rarelootchest/mustafarian_injector.py new file mode 100644 index 00000000..5eb85000 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/mustafarian_injector.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['bject/tangible/gcw/crafting_quest/shared_gcw_bacta_injectors.iff'] # this is wrong needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/mynock_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/mynock_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/mynock_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/no_division.py b/scripts/loot/lootItems/rarelootchest/no_division.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/no_division.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/nym_collectible_globe.py b/scripts/loot/lootItems/rarelootchest/nym_collectible_globe.py new file mode 100644 index 00000000..eb1c8d23 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/nym_collectible_globe.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/static/worldbuilding/terminal/shared_floor_console_tableglobe_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/pilgrimage.py b/scripts/loot/lootItems/rarelootchest/pilgrimage.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/pilgrimage.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/poster_of_a_ship_schematic.py b/scripts/loot/lootItems/rarelootchest/poster_of_a_ship_schematic.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/poster_of_a_ship_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/poster_of_a_turret_schematic.py b/scripts/loot/lootItems/rarelootchest/poster_of_a_turret_schematic.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/poster_of_a_turret_schematic.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/poster_of_food_preparation.py b/scripts/loot/lootItems/rarelootchest/poster_of_food_preparation.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/poster_of_food_preparation.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/proton_chair.py b/scripts/loot/lootItems/rarelootchest/proton_chair.py new file mode 100644 index 00000000..94bd8336 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/proton_chair.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/lifeday/shared_lifeday_proton_chair.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/rancor_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/rancor_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/rancor_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/rotj_helmet.py b/scripts/loot/lootItems/rarelootchest/rotj_helmet.py new file mode 100644 index 00000000..acc54422 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/rotj_helmet.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/quest/rebel/shared_rtp_leia_rebel_helmet.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/shard_of_the_serpent.py b/scripts/loot/lootItems/rarelootchest/shard_of_the_serpent.py new file mode 100644 index 00000000..08728ddc --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/shard_of_the_serpent.py @@ -0,0 +1,29 @@ + +def itemTemplate(): + + return ['object/tangible/component/weapon/lightsaber/shared_lightsaber_module_force_crystal.iff'] + +def customItemName(): + + return "Shard Of The Serpent" + +def biolink(): + + return 1 + +def customColor1(): + + return 3 + +def lootDescriptor(): + + return 'rarebuffitem' + +def itemStats(): + + stats =['proc_name','towCrystalUberCombat','towCrystalUberCombat'] + stats +=['effectname','Harmonious Counteraction','Harmonious Counteraction'] + stats +=['duration','180','180'] + stats +=['cooldown','3600','3600'] + + return stats \ No newline at end of file diff --git a/scripts/loot/lootItems/rarelootchest/stap1_vehicle_deed.py b/scripts/loot/lootItems/rarelootchest/stap1_vehicle_deed.py new file mode 100644 index 00000000..647347bf --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/stap1_vehicle_deed.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/draft_schematic/vehicle/civilian/shared_speeder_stap.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/target_dummy_black_sun.py b/scripts/loot/lootItems/rarelootchest/target_dummy_black_sun.py new file mode 100644 index 00000000..7d85ed97 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/target_dummy_black_sun.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/mobile/shared_target_dummy_blacksun.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/target_dummy_rebel.py b/scripts/loot/lootItems/rarelootchest/target_dummy_rebel.py new file mode 100644 index 00000000..0417d75b --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/target_dummy_rebel.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/mobile/shared_target_dummy_rebel_trooper.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/target_dummy_stormtrooper.py b/scripts/loot/lootItems/rarelootchest/target_dummy_stormtrooper.py new file mode 100644 index 00000000..4ce37ad7 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/target_dummy_stormtrooper.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/mobile/shared_target_dummy_stormtrooper.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/tatooine_dune_speeder.py b/scripts/loot/lootItems/rarelootchest/tatooine_dune_speeder.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/tatooine_dune_speeder.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/triumph.py b/scripts/loot/lootItems/rarelootchest/triumph.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/triumph.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/ugnaught_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/ugnaught_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/ugnaught_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/victory.py b/scripts/loot/lootItems/rarelootchest/victory.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/victory.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/wampa_costume_instructions.py b/scripts/loot/lootItems/rarelootchest/wampa_costume_instructions.py new file mode 100644 index 00000000..72f76e42 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/wampa_costume_instructions.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/item/costume_kit/shared_costume_deed.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/war_terminal.py b/scripts/loot/lootItems/rarelootchest/war_terminal.py new file mode 100644 index 00000000..fcb691ca --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/war_terminal.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/object/tangible/beta/shared_beta_terminal_warp.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/warriors honor.py b/scripts/loot/lootItems/rarelootchest/warriors honor.py new file mode 100644 index 00000000..75858734 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/warriors honor.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday05_painting_01.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/wookie_home_banner_kit.py b/scripts/loot/lootItems/rarelootchest/wookie_home_banner_kit.py new file mode 100644 index 00000000..10432fd0 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/wookie_home_banner_kit.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_wookiee_shield.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/wookie_life_day_orb.py b/scripts/loot/lootItems/rarelootchest/wookie_life_day_orb.py new file mode 100644 index 00000000..90e2b3a0 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/wookie_life_day_orb.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/decorative/shared_event_lifeday07_orb.iff'] # needs correct iff still diff --git a/scripts/loot/lootItems/rarelootchest/xeno_couch.py b/scripts/loot/lootItems/rarelootchest/xeno_couch.py new file mode 100644 index 00000000..6eb683cd --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/xeno_couch.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_xeno_couch.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/xeno_desk.py b/scripts/loot/lootItems/rarelootchest/xeno_desk.py new file mode 100644 index 00000000..75478c35 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/xeno_desk.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_xeno_desk.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/xeno_desk_lamp.py b/scripts/loot/lootItems/rarelootchest/xeno_desk_lamp.py new file mode 100644 index 00000000..26b580c3 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/xeno_desk_lamp.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_xeno_desk_lamp.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/xeno_rug.py b/scripts/loot/lootItems/rarelootchest/xeno_rug.py new file mode 100644 index 00000000..6430ec09 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/xeno_rug.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_xeno_rug.iff'] diff --git a/scripts/loot/lootItems/rarelootchest/xeno_table.py b/scripts/loot/lootItems/rarelootchest/xeno_table.py new file mode 100644 index 00000000..84542507 --- /dev/null +++ b/scripts/loot/lootItems/rarelootchest/xeno_table.py @@ -0,0 +1,4 @@ + +def itemTemplate(): + + return ['object/tangible/furniture/house_cleanup/shared_xeno_table.iff'] diff --git a/scripts/loot/rarelootchestcontents/exceptionaltable.py b/scripts/loot/rarelootchestcontents/exceptionaltable.py index b8c4ba4d..f652f0a4 100644 --- a/scripts/loot/rarelootchestcontents/exceptionaltable.py +++ b/scripts/loot/rarelootchestcontents/exceptionaltable.py @@ -1,12 +1,48 @@ -def itemTemplates(): - templates = ['Biological_Focus_Crystal','Synapse_Focus_Crystal','Concentrated_Bacta_Tank','DNA_Storage_Device_Kowakian'] - templates = templates + ['Dug_Costume_Instructions','Dusk_in_Kachirho','Mercenaries_Despair','Mercenaries_Lament','Nightsister_Melee_Armguard'] - templates = templates + ['Rare_Painting','Sunriders_Destiny'] +def itemNames(): + # Exceptional part + templates = ['bacta_tank','legendary_e5_carbine','legendary_fwg5_pistol','legendary_nightsister_energy_lance'] + templates +=['legendary_power_hammer','legendary_stun_baton','legendary_t21_rifle','advertisement_rodian'] + templates +=['cunning_of_tyranus','dna_storage_device','dusk_in_kachirho','emperors_senate_office_chair'] + templates +=['fighter','gungan_statue_style_1_schematic','gungan_statue_style_2_schematic','gungan_statue_style_3_schematic'] + templates +=['gungan_statue_style_4_schematic','holo_entertainment_table','jedi_master_cloak','jedi_relic_1'] + templates +=['poster_block_turret_schematic','prayer_mobile','shard_of_ferocity','shard_of_retaliation'] + templates +=['sith_buff_holocron','sith_relic','war_phoenix'] + # Rare part + templates +=['animal_hide_rack_style_1','animal_hide_rack_style_2','animal_hide_rack_style_3','animal_hide_rack_style_4'] + templates +=['at_st_pilots_helmet','aurilian_sculpture_section_1','aurilian_sculpture_section_2','aurilian_sculpture_section_3'] + templates +=['aurilian_sculpture_section_4','banes_heart','bar_corner_piece_1','bar_corner_piece_2'] + templates +=['bar_corner_piece_3','bar_counter_large','bothan_beauty','bothan_buff'] + templates +=['cast_wing_in_flight','corellian_seaside','data_disk_hologram','decorative_bubble_tank'] + templates +=['droid_in_contrast','drum','emperors_eyes','family_bonds'] + templates +=['feared','fighter_study','fighters_courage','geonosian_costume_instructions'] + templates +=['hanging_life_day_orb','hutt_greed','imperial_oppression','jedi_statue_schematic'] + templates +=['jubilee_wheel_schematic','kachirho_wall_cornucopia','kowakian_cage','krayt_costume_instructions'] + templates +=['large_fruit_stand_schematic','large_unmarked_crate','lava_geode','life_day_lamp'] + templates +=['life_day_proud_wookie','life_day_red_robed_wookie','living_canals','lugjack_machine_schematic'] + templates +=['miniature_wroshyr_tree','modified_fusion_reactor_schematic','mustafarian_injector','mynock_costume_instructions'] + templates +=['no_division','nym_collectible_globe','pilgrimage','poster_of_a_ship_schematic'] + templates +=['poster_of_a_turret_schematic','poster_of_food_preparation','proton_chair','rancor_costume_instructions'] + templates +=['rotj_helmet','shard_of_the_serpent','stap1_vehicle_deed','target_dummy_black_sun'] + templates +=['target_dummy_rebel','target_dummy_stormtrooper','tatooine_dune_speeder','triumph'] + templates +=['ugnaught_costume_instructions','victory','wampa_costume_instructions','war_terminal'] + templates +=['warriors honor','wookie_home_banner_kit','wookie_life_day_orb','xeno_couch'] + templates +=['xeno_desk','xeno_desk_lamp','xeno_rug','xeno_table'] + return templates def itemChances(): - chances = [9,9,9,9] - chances = chances+[9,9,9,9,9] - chances = chances+[9,9] #= 100% - return chances \ No newline at end of file + chances = [1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908] #27 Exceptionals + chances += [1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908,1.908] + chances += [1.908,1.908,1.908,1.908,1.908,1.908,1.908] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] #76 Rares + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636,0.636] + chances += [0.636,0.636,0.636,0.636,0.636,0.784] + + return chances + \ No newline at end of file diff --git a/scripts/loot/rarelootchestcontents/legendarytable.py b/scripts/loot/rarelootchestcontents/legendarytable.py index d372b968..c46a7855 100644 --- a/scripts/loot/rarelootchestcontents/legendarytable.py +++ b/scripts/loot/rarelootchestcontents/legendarytable.py @@ -1,8 +1,51 @@ def itemNames(): + # Legendary part + templates = ['biological_focus_crystal','synapse_focus_crystal','concentrated_bacta_tank','dna_storage_device_kowakian'] + templates +=['dug_costume_instructions','mercenaries_despair','mercenaries_lament','nightsister_melee_armguard'] + templates +=['rare_painting','sunriders_destiny'] # 10 items + # Exceptional part + templates +=['bacta_tank','legendary_e5_carbine','legendary_fwg5_pistol','legendary_nightsister_energy_lance'] + templates +=['legendary_power_hammer','legendary_stun_baton','legendary_t21_rifle','advertisement_rodian'] + templates +=['cunning_of_tyranus','dna_storage_device','dusk_in_kachirho','emperors_senate_office_chair'] + templates +=['fighter','gungan_statue_style_1_schematic','gungan_statue_style_2_schematic','gungan_statue_style_3_schematic'] + templates +=['gungan_statue_style_4_schematic','holo_entertainment_table','jedi_master_cloak','jedi_relic_1'] + templates +=['poster_block_turret_schematic','prayer_mobile','shard_of_ferocity','shard_of_retaliation'] + templates +=['sith_buff_holocron','sith_relic','war_phoenix'] + # Rare part + templates +=['animal_hide_rack_style_1','animal_hide_rack_style_2','animal_hide_rack_style_3','animal_hide_rack_style_4'] + templates +=['at_st_pilots_helmet','aurilian_sculpture_section_1','aurilian_sculpture_section_2','aurilian_sculpture_section_3'] + templates +=['aurilian_sculpture_section_4','banes_heart','bar_corner_piece_1','bar_corner_piece_2'] + templates +=['bar_corner_piece_3','bar_counter_large','bothan_beauty','bothan_buff'] + templates +=['cast_wing_in_flight','corellian_seaside','data_disk_hologram','decorative_bubble_tank'] + templates +=['droid_in_contrast','drum','emperors_eyes','family_bonds'] + templates +=['feared','fighter_study','fighters_courage','geonosian_costume_instructions'] + templates +=['hanging_life_day_orb','hutt_greed','imperial_oppression','jedi_statue_schematic'] + templates +=['jubilee_wheel_schematic','kachirho_wall_cornucopia','kowakian_cage','krayt_costume_instructions'] + templates +=['large_fruit_stand_schematic','large_unmarked_crate','lava_geode','life_day_lamp'] + templates +=['life_day_proud_wookie','life_day_red_robed_wookie','living_canals','lugjack_machine_schematic'] + templates +=['miniature_wroshyr_tree','modified_fusion_reactor_schematic','mustafarian_injector','mynock_costume_instructions'] + templates +=['no_division','nym_collectible_globe','pilgrimage','poster_of_a_ship_schematic'] + templates +=['poster_of_a_turret_schematic','poster_of_food_preparation','proton_chair','rancor_costume_instructions'] + templates +=['rotj_helmet','shard_of_the_serpent','stap1_vehicle_deed','target_dummy_black_sun'] + templates +=['target_dummy_rebel','target_dummy_stormtrooper','tatooine_dune_speeder','triumph'] + templates +=['ugnaught_costume_instructions','victory','wampa_costume_instructions','war_terminal'] + templates +=['warriors honor','wookie_home_banner_kit','wookie_life_day_orb','xeno_couch'] + templates +=['xeno_desk','xeno_desk_lamp','xeno_rug','xeno_table'] + return templates - return ['colorCrystal'] - def itemChances(): - - return [70] \ No newline at end of file + chances = [1.875,1.875,1.875,1.875,1.875,1.875,1.875,1.875,1.875,1.875] #10 Legendaries + chances += [1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25] #27 Exceptionals + chances += [1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25,1.25] + chances += [1.25,1.25,1.25,1.25,1.25,1.25,1.25] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] #76 Rares + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625,0.625] + chances += [0.625,0.625,0.625,0.625,0.625,0.625] + + return chances \ No newline at end of file diff --git a/scripts/loot/rarelootchestcontents/raretable.py b/scripts/loot/rarelootchestcontents/raretable.py index e69de29b..8e049299 100644 --- a/scripts/loot/rarelootchestcontents/raretable.py +++ b/scripts/loot/rarelootchestcontents/raretable.py @@ -0,0 +1,36 @@ + +def itemNames(): + + items = ['animal_hide_rack_style_1','animal_hide_rack_style_2','animal_hide_rack_style_3','animal_hide_rack_style_4'] + items +=['at_st_pilots_helmet','aurilian_sculpture_section_1','aurilian_sculpture_section_2','aurilian_sculpture_section_3'] + items +=['aurilian_sculpture_section_4','banes_heart','bar_corner_piece_1','bar_corner_piece_2'] + items +=['bar_corner_piece_3','bar_counter_large','bothan_beauty','bothan_buff'] + items +=['cast_wing_in_flight','corellian_seaside','data_disk_hologram','decorative_bubble_tank'] + items +=['droid_in_contrast','drum','emperors_eyes','family_bonds'] + items +=['feared','fighter_study','fighters_courage','geonosian_costume_instructions'] + items +=['hanging_life_day_orb','hutt_greed','imperial_oppression','jedi_statue_schematic'] + items +=['jubilee_wheel_schematic','kachirho_wall_cornucopia','kowakian_cage','krayt_costume_instructions'] + items +=['large_fruit_stand_schematic','large_unmarked_crate','lava_geode','life_day_lamp'] + items +=['life_day_proud_wookie','life_day_red_robed_wookie','living_canals','lugjack_machine_schematic'] + items +=['miniature_wroshyr_tree','modified_fusion_reactor_schematic','mustafarian_injector','mynock_costume_instructions'] + items +=['no_division','nym_collectible_globe','pilgrimage','poster_of_a_ship_schematic'] + items +=['poster_of_a_turret_schematic','poster_of_food_preparation','proton_chair','rancor_costume_instructions'] + items +=['rotj_helmet','shard_of_the_serpent','stap1_vehicle_deed','target_dummy_black_sun'] + items +=['target_dummy_rebel','target_dummy_stormtrooper','tatooine_dune_speeder','triumph'] + items +=['ugnaught_costume_instructions','victory','wampa_costume_instructions','war_terminal'] + items +=['warriors honor','wookie_home_banner_kit','wookie_life_day_orb','xeno_couch'] + items +=['xeno_desk','xeno_desk_lamp','xeno_rug','xeno_table'] + return items + +def itemChances(): + + chances=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315,1.315] + chances+=[1.315,1.315,1.315,1.315,1.315,1.375] + return chances ##Sum must be exactly 100 76 items -> 1.315 + \ No newline at end of file diff --git a/scripts/object/mobile/dressed_rebel_recruiter_human_female_01.py b/scripts/object/mobile/dressed_rebel_recruiter_human_female_01.py index e0dd64a1..d4d1de24 100644 --- a/scripts/object/mobile/dressed_rebel_recruiter_human_female_01.py +++ b/scripts/object/mobile/dressed_rebel_recruiter_human_female_01.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('rebel_recruiter') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:rebel', object.getPosition().x, object.getPosition().z, 45, 47, 0) return diff --git a/scripts/object/mobile/dressed_rebel_recruiter_human_female_02.py b/scripts/object/mobile/dressed_rebel_recruiter_human_female_02.py index ccad8904..4f948254 100644 --- a/scripts/object/mobile/dressed_rebel_recruiter_human_female_02.py +++ b/scripts/object/mobile/dressed_rebel_recruiter_human_female_02.py @@ -1,4 +1,13 @@ import sys +from resources.datatables import Options def setup(core, object): - return \ No newline at end of file + object.setAttachment('radial_filename', 'object/conversation'); + object.setAttachment('conversationFile','reb_recruiter') + object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) + object.setStfFilename('mob/creature_names') + object.setStfName('rebel_recruiter') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:rebel', object.getPosition().x, object.getPosition().z, 45, 47, 0) + + return diff --git a/scripts/object/mobile/dressed_rebel_recruiter_moncal_male_01.py b/scripts/object/mobile/dressed_rebel_recruiter_moncal_male_01.py index ccad8904..efad85db 100644 --- a/scripts/object/mobile/dressed_rebel_recruiter_moncal_male_01.py +++ b/scripts/object/mobile/dressed_rebel_recruiter_moncal_male_01.py @@ -1,4 +1,13 @@ import sys +from resources.datatables import Options def setup(core, object): - return \ No newline at end of file + object.setAttachment('radial_filename', 'object/conversation'); + object.setAttachment('conversationFile','reb_recruiter') + object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) + object.setStfFilename('mob/creature_names') + object.setStfName('rebel_recruiter') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:rebel', object.getPosition().x, object.getPosition().z, 45, 47, 0) + + return diff --git a/scripts/object/mobile/dressed_rebel_recruiter_twilek_female_01.py b/scripts/object/mobile/dressed_rebel_recruiter_twilek_female_01.py index ccad8904..25c143c9 100644 --- a/scripts/object/mobile/dressed_rebel_recruiter_twilek_female_01.py +++ b/scripts/object/mobile/dressed_rebel_recruiter_twilek_female_01.py @@ -1,4 +1,13 @@ import sys +from resources.datatables import Options def setup(core, object): - return \ No newline at end of file + object.setAttachment('radial_filename', 'object/conversation'); + object.setAttachment('conversationFile','reb_recruiter') + object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) + object.setStfFilename('mob/creature_names') + object.setStfName('rebel_recruiter') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:rebel', object.getPosition().x, object.getPosition().z, 45, 47, 0) + + return diff --git a/scripts/object/mobile/junk_dealer_f_01.py b/scripts/object/mobile/junk_dealer_f_01.py index 6fed84e5..0864b43c 100644 --- a/scripts/object/mobile/junk_dealer_f_01.py +++ b/scripts/object/mobile/junk_dealer_f_01.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/mobile/junk_dealer_f_02.py b/scripts/object/mobile/junk_dealer_f_02.py index 6e9644e2..f366e0a9 100644 --- a/scripts/object/mobile/junk_dealer_f_02.py +++ b/scripts/object/mobile/junk_dealer_f_02.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer_smuggler') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/mobile/junk_dealer_f_03.py b/scripts/object/mobile/junk_dealer_f_03.py index 9ed1eded..8de1dd20 100644 --- a/scripts/object/mobile/junk_dealer_f_03.py +++ b/scripts/object/mobile/junk_dealer_f_03.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer_special') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/mobile/junk_dealer_m_01.py b/scripts/object/mobile/junk_dealer_m_01.py index 6fed84e5..0864b43c 100644 --- a/scripts/object/mobile/junk_dealer_m_01.py +++ b/scripts/object/mobile/junk_dealer_m_01.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/mobile/junk_dealer_m_02.py b/scripts/object/mobile/junk_dealer_m_02.py index 6e9644e2..f366e0a9 100644 --- a/scripts/object/mobile/junk_dealer_m_02.py +++ b/scripts/object/mobile/junk_dealer_m_02.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer_smuggler') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/mobile/junk_dealer_m_03.py b/scripts/object/mobile/junk_dealer_m_03.py index 9ed1eded..8de1dd20 100644 --- a/scripts/object/mobile/junk_dealer_m_03.py +++ b/scripts/object/mobile/junk_dealer_m_03.py @@ -7,4 +7,6 @@ def setup(core, object): object.setOptionsBitmask(Options.CONVERSABLE | Options.INVULNERABLE) object.setStfFilename('mob/creature_names') object.setStfName('junk_dealer_special') + + core.mapService.addLocation(object.getPlanet(), '@map_loc_cat_n:junkshop', object.getPosition().x, object.getPosition().z, 26, 81, 0) return \ No newline at end of file diff --git a/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_force.py b/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_force.py index ccad8904..0e442157 100644 --- a/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_force.py +++ b/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_force.py @@ -1,4 +1,9 @@ import sys def setup(core, object): - return \ No newline at end of file + object.setStfFilename('static_item_n') + object.setStfName('item_force_crystal_04_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_force_crystal_04_02') + object.setAttachment('radial_filename', 'item/item') + return diff --git a/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_health.py b/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_health.py index ccad8904..fd74930e 100644 --- a/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_health.py +++ b/scripts/object/tangible/item/quest/force_sensitive/fs_crystal_health.py @@ -1,4 +1,9 @@ import sys def setup(core, object): - return \ No newline at end of file + object.setStfFilename('static_item_n') + object.setStfName('item_force_crystal_04_01') + object.setDetailFilename('static_item_d') + object.setDetailName('item_force_crystal_04_01') + object.setAttachment('radial_filename', 'item/item') + return diff --git a/scripts/object/tangible/loot/generic_usable/item_spy_clicky_01_02.p b/scripts/object/tangible/loot/generic_usable/item_spy_clicky_01_02.p new file mode 100644 index 00000000..dd1385a7 --- /dev/null +++ b/scripts/object/tangible/loot/generic_usable/item_spy_clicky_01_02.p @@ -0,0 +1,9 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_spy_clicky_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_spy_clicky_01_02') + object.setStringAttribute('class_required', 'Spy') + return diff --git a/scripts/object/tangible/wearables/armor/zam/item_roadmap_belt_spy_01_02.py b/scripts/object/tangible/wearables/armor/zam/item_roadmap_belt_spy_01_02.py new file mode 100644 index 00000000..71012ad3 --- /dev/null +++ b/scripts/object/tangible/wearables/armor/zam/item_roadmap_belt_spy_01_02.py @@ -0,0 +1,13 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_roadmap_belt_spy_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_roadmap_belt_spy_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', 'Spy') + object.setIntAttribute('required_combat_level', 90) + return diff --git a/scripts/object/tangible/wearables/backpack/item_spy_backpack_01_02.py b/scripts/object/tangible/wearables/backpack/item_spy_backpack_01_02.py new file mode 100644 index 00000000..f6412dee --- /dev/null +++ b/scripts/object/tangible/wearables/backpack/item_spy_backpack_01_02.py @@ -0,0 +1,11 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_spy_backpack_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_spy_backpack_01_02') + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 5) + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 5) + object.setStringAttribute('class_required', 'Spy') + return diff --git a/scripts/object/tangible/wearables/necklace/item_spy_pendant_01_02.py b/scripts/object/tangible/wearables/necklace/item_spy_pendant_01_02.py new file mode 100644 index 00000000..f46a52b8 --- /dev/null +++ b/scripts/object/tangible/wearables/necklace/item_spy_pendant_01_02.py @@ -0,0 +1,11 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_spy_pendant_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_spy_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', 'Spy') + return diff --git a/scripts/object/tangible/wearables/ring/item_spy_ring_01_02.py b/scripts/object/tangible/wearables/ring/item_spy_ring_01_02.py new file mode 100644 index 00000000..e6d4aafb --- /dev/null +++ b/scripts/object/tangible/wearables/ring/item_spy_ring_01_02.py @@ -0,0 +1,11 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_spy_ring_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('item_spy_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', 'Spy') + return diff --git a/scripts/object/tangible/wearables/robe/robe_s05_h1.py b/scripts/object/tangible/wearables/robe/robe_s05_h1.py index ccad8904..6df15568 100644 --- a/scripts/object/tangible/wearables/robe/robe_s05_h1.py +++ b/scripts/object/tangible/wearables/robe/robe_s05_h1.py @@ -1,4 +1,22 @@ import sys def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('item_jedi_robe_06_01') + object.setDetailFilename('static_item_d') + object.setDetailName('item_jedi_robe_06_01') + + object.setStringAttribute('protection_level', 'Luminous') + object.setStringAttribute('class_required', 'Jedi') + object.setIntAttribute('required_combat_level', 80) + + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:constitution_modified', 100) + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:strength_modified', 100) + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:agility_modified', 100) + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:luck_modified', 100) + + object.setStringAttribute('@set_bonus:piece_bonus_count_2', '@set_bonus:set_bonus_jedi_robe_1') + + object.setAttachment('type', 'jedi_robe') + object.setAttachment('setBonus', 'set_bonus_jedi_robe') return \ No newline at end of file diff --git a/scripts/object/weapon/ranged/carbine/weapon_carbine_sp_roadmap_01_02.py b/scripts/object/weapon/ranged/carbine/weapon_carbine_sp_roadmap_01_02.py new file mode 100644 index 00000000..b8697c39 --- /dev/null +++ b/scripts/object/weapon/ranged/carbine/weapon_carbine_sp_roadmap_01_02.py @@ -0,0 +1,17 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('weapon_carbine_sp_roadmap_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('weapon_carbine_sp_roadmap_01_02') + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 5) + object.setStringAttribute('class_required', 'Spy') + object.setIntAttribute('required_combat_level', 50) + object.setFloatAttribute('cat_wpn_damage.wpn_attack_speed', 0.6) + object.setStringAttribute('cat_wpn_damage.wpn_damage_type', 'Energy') + object.setStringAttribute('cat_wpn_damage.damage', '195-392') + object.setStringAttribute('cat_wpn_damage.range', '0-55m') + object.setStringAttribute('cat_wpn_damage.wpn_category', 'Carbine') + object.setIntAttribute('cat_wpn_damage.dps', object.getDamagePerSecond()) + return diff --git a/scripts/object/weapon/ranged/pistol/weapon_pistol_sp_roadmap_01_02.py b/scripts/object/weapon/ranged/pistol/weapon_pistol_sp_roadmap_01_02.py new file mode 100644 index 00000000..5951524c --- /dev/null +++ b/scripts/object/weapon/ranged/pistol/weapon_pistol_sp_roadmap_01_02.py @@ -0,0 +1,17 @@ +import sys + +def setup(core, object): + object.setStfFilename('static_item_n') + object.setStfName('weapon_pistol_sp_roadmap_01_02') + object.setDetailFilename('static_item_d') + object.setDetailName('weapon_pistol_sp_roadmap_01_02') + object.setIntAttribute('cat_stat_mod_bonus.@stat_n:precision_modified', 5) + object.setStringAttribute('class_required', 'Spy') + object.setIntAttribute('required_combat_level', 30) + object.setFloatAttribute('cat_wpn_damage.wpn_attack_speed', 0.4) + object.setStringAttribute('cat_wpn_damage.wpn_damage_type', 'Energy') + object.setStringAttribute('cat_wpn_damage.damage', '73-145') + object.setStringAttribute('cat_wpn_damage.range', '0-35m') + object.setStringAttribute('cat_wpn_damage.wpn_category', 'Pistol') + object.setIntAttribute('cat_wpn_damage.dps', object.getDamagePerSecond()) + return diff --git a/scripts/radial/item/lootchest.py b/scripts/radial/item/lootchest.py index 1a0c9889..90c6b03e 100644 --- a/scripts/radial/item/lootchest.py +++ b/scripts/radial/item/lootchest.py @@ -8,6 +8,7 @@ def createRadial(core, owner, target, radials): def handleSelection(core, owner, target, option): if option == 21 and target: - owner.sendSystemMessage('RLS chest content system not yet implemented.',1) + core.lootService.fillrarelootchest(owner, target) + return \ No newline at end of file diff --git a/scripts/roadmap/officer_1a.py b/scripts/roadmap/officer_1a.py index 83bca56f..3a139591 100644 --- a/scripts/roadmap/officer_1a.py +++ b/scripts/roadmap/officer_1a.py @@ -25,4 +25,96 @@ def getAction(): return 75 def getRewards(name): - return \ No newline at end of file + + if name == 'item_officer_backpack_01_02': + return "object/tangible/wearables/backpack/shared_backpack_s03.iff" + + if name == 'armor_officer_roadmap_bicep_l_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_bicep_l.iff" + + if name == 'armor_officer_roadmap_bicep_r_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_bicep_r.iff" + + if name == 'armor_officer_roadmap_bracer_l_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_bracer_l.iff" + + if name == 'armor_officer_roadmap_bracer_r_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_bracer_r.iff" + + if name == 'armor_officer_roadmap_boots_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_boots.iff" + + if name == 'armor_officer_roadmap_chest_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_chest_plate.iff" + + if name == 'armor_officer_roadmap_gloves_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_gloves.iff" + + if name == 'armor_officer_roadmap_helmet_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_helmet.iff" + + if name == 'armor_officer_roadmap_leggings_02_01': + return "object/tangible/wearables/armor/composite/shared_armor_composite_leggings.iff" + + if name == 'armor_wookiee_roadmap_chest_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_chestplate.iff" + + if name == 'armor_wookiee_roadmap_leggings_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_leggings.iff" + + if name == 'armor_wookiee_roadmap_bicep_l_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bicep_l.iff" + + if name == 'armor_wookiee_roadmap_bicep_r_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bicep_r.iff" + + if name == 'armor_wookiee_roadmap_bracer_l_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bracer_l.iff" + + if name == 'armor_wookiee_roadmap_bracer_r_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bracer_r.iff" + + if name == 'armor_ithorian_roadmap_chest_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_chest_plate.iff" + + if name == 'armor_ithorian_roadmap_leggings_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_leggings.iff" + + if name == 'armor_ithorian_roadmap_helmet_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_helmet.iff" + + if name == 'armor_ithorian_roadmap_bicep_l_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bicep_l.iff" + + if name == 'armor_ithorian_roadmap_bicep_r_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bicep_r.iff" + + if name == 'armor_ithorian_roadmap_bracer_l_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bracer_l.iff" + + if name == 'armor_ithorian_roadmap_bracer_r_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bracer_r.iff" + + if name == 'armor_ithorian_roadmap_boots_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_boots.iff" + + if name == 'armor_ithorian_roadmap_gloves_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_gloves.iff" + + if name == 'weapon_pistol_sp_roadmap_01_02': + return "object/weapon/ranged/pistol/shared_pistol_dl44.iff" + + if name == 'item_officer_ring_01_02': + return "object/tangible/wearables/ring/shared_ring_s02.iff" + + if name == 'weapon_carbine_of_roadmap_01_02': + return "object/weapon/ranged/pistol/shared_pistol_dl44_metal.iff" + + if name == 'item_officer_pendant_01_02': + return "object/tangible/wearables/necklace/shared_necklace_s02.iff" + + if name == 'item_officer_clicky_01_02': + return "object/tangible/loot/generic_usable/shared_survey_pad_adv_generic.iff" + + if name == 'item_roadmap_belt_officer_01_02': + return "object/tangible/wearables/armor/zam/shared_armor_zam_wesell_belt.iff" diff --git a/scripts/roadmap/spy_1a.py b/scripts/roadmap/spy_1a.py index 079de728..65d40d6c 100644 --- a/scripts/roadmap/spy_1a.py +++ b/scripts/roadmap/spy_1a.py @@ -25,4 +25,96 @@ def getAction(): return 75 def getRewards(name): - return \ No newline at end of file + + if name == 'item_spy_backpack_01_02': + return "object/tangible/wearables/backpack/shared_backpack_s04.iff" + + if name == 'armor_spy_roadmap_bicep_l_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_bicep_l.iff" + + if name == 'armor_spy_roadmap_bicep_r_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_bicep_r.iff" + + if name == 'armor_spy_roadmap_bracer_l_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_bracer_l.iff" + + if name == 'armor_spy_roadmap_bracer_r_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_bracer_r.iff" + + if name == 'armor_spy_roadmap_boots_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_boots.iff" + + if name == 'armor_spy_roadmap_chest_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_chest_plate.iff" + + if name == 'armor_spy_roadmap_gloves_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_gloves.iff" + + if name == 'armor_spy_roadmap_helmet_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_helmet.iff" + + if name == 'armor_spy_roadmap_leggings_02_01': + return "object/tangible/wearables/armor/padded/shared_armor_padded_s01_leggings.iff" + + if name == 'armor_wookiee_roadmap_chest_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_chestplate.iff" + + if name == 'armor_wookiee_roadmap_leggings_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_leggings.iff" + + if name == 'armor_wookiee_roadmap_bicep_l_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bicep_l.iff" + + if name == 'armor_wookiee_roadmap_bicep_r_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bicep_r.iff" + + if name == 'armor_wookiee_roadmap_bracer_l_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bracer_l.iff" + + if name == 'armor_wookiee_roadmap_bracer_r_02_03': + return "object/tangible/wearables/armor/kashyyykian_hunting/shared_armor_kashyyykian_hunting_bracer_r.iff" + + if name == 'armor_ithorian_roadmap_chest_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_chest_plate.iff" + + if name == 'armor_ithorian_roadmap_leggings_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_leggings.iff" + + if name == 'armor_ithorian_roadmap_helmet_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_helmet.iff" + + if name == 'armor_ithorian_roadmap_bicep_l_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bicep_l.iff" + + if name == 'armor_ithorian_roadmap_bicep_r_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bicep_r.iff" + + if name == 'armor_ithorian_roadmap_bracer_l_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bracer_l.iff" + + if name == 'armor_ithorian_roadmap_bracer_r_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_bracer_r.iff" + + if name == 'armor_ithorian_roadmap_boots_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_boots.iff" + + if name == 'armor_ithorian_roadmap_gloves_02_03': + return "object/tangible/wearables/armor/ithorian_sentinel/shared_ith_armor_s03_gloves.iff" + + if name == 'weapon_pistol_sp_roadmap_01_02': + return "object/weapon/ranged/pistol/shared_pistol_striker.iff" + + if name == 'item_spy_ring_01_02': + return "object/tangible/wearables/ring/shared_ring_s02.iff" + + if name == 'weapon_carbine_sp_roadmap_01_02': + return "object/weapon/ranged/carbine/shared_carbine_e11.iff" + + if name == 'item_spy_pendant_01_02': + return "object/tangible/wearables/necklace/shared_necklace_s02.iff" + + if name == 'item_spy_clicky_01_02': + return "object/tangible/loot/generic_usable/shared_survey_pad_adv_generic.iff" + + if name == 'item_roadmap_belt_spy_01_02': + return "object/tangible/wearables/armor/zam/shared_armor_zam_wesell_belt.iff" diff --git a/scripts/static_spawns/corellia/bela_vistal.py b/scripts/static_spawns/corellia/bela_vistal.py new file mode 100644 index 00000000..45ea12ee --- /dev/null +++ b/scripts/static_spawns/corellia/bela_vistal.py @@ -0,0 +1,17 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + stcSvc = core.staticService + objSvc = core.objectService + + #junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'corellia', long(0), float(6840), float(315), float(-5630), float(0.707), float(-0.707)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'corellia', long(0), float(6852), float(315), float(-5802), float(0.71), float(-0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'corellia', long(0), float(6756), float(315), float(-5778), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'corellia', long(0), float(6970), float(330), float(-5588), float(0.71), float(0.71)) + return diff --git a/scripts/static_spawns/corellia/coronet.py b/scripts/static_spawns/corellia/coronet.py index 60de3058..e7974869 100644 --- a/scripts/static_spawns/corellia/coronet.py +++ b/scripts/static_spawns/corellia/coronet.py @@ -121,5 +121,7 @@ def addPlanetSpawns(core, planet): mackJasper.setCustomName2('Lieutenant Mack Jasper') mackJasper.setOptionsBitmask(256) + #Junkdealer will be added as soon as i can find coords + return \ No newline at end of file diff --git a/scripts/static_spawns/corellia/doaba_guerfel.py b/scripts/static_spawns/corellia/doaba_guerfel.py new file mode 100644 index 00000000..bb48cb72 --- /dev/null +++ b/scripts/static_spawns/corellia/doaba_guerfel.py @@ -0,0 +1,12 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + + #junkdealer will be added as soon as i find coords + + return diff --git a/scripts/static_spawns/corellia/factional_recruiters.py b/scripts/static_spawns/corellia/factional_recruiters.py index a2a70bf2..17de611c 100644 --- a/scripts/static_spawns/corellia/factional_recruiters.py +++ b/scripts/static_spawns/corellia/factional_recruiters.py @@ -15,4 +15,13 @@ def addPlanetSpawns(core, planet): stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_4.iff', 'corellia', long(0), float(6718), float(315), float(-5809), float(0), float(0), float(0), float(0)) + #rebrecruiter tyrena + tyrenaCantina = core.objectService.getObject(long(2625352)) + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_moncal_male_01.iff', 'corellia', tyrenaCantina.getCellByCellNumber(11), float(-25.8), float(-0.9), float(0.4), float(0), float(-0.707), float(0), float(0.707)) + + #cnet cantina + cnetCantina = core.objectService.getObject(long(8105493)) + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_twilek_female_01.iff', 'corellia', cnetCantina.getCellByCellNumber(11), float(-25.8), float(-0.9), float(0.4), float(0), float(-0.707), float(0), float(0.707)) + + return \ No newline at end of file diff --git a/scripts/static_spawns/corellia/kor_vella.py b/scripts/static_spawns/corellia/kor_vella.py new file mode 100644 index 00000000..bb48cb72 --- /dev/null +++ b/scripts/static_spawns/corellia/kor_vella.py @@ -0,0 +1,12 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + + #junkdealer will be added as soon as i find coords + + return diff --git a/scripts/static_spawns/corellia/tyrena.py b/scripts/static_spawns/corellia/tyrena.py new file mode 100644 index 00000000..bb48cb72 --- /dev/null +++ b/scripts/static_spawns/corellia/tyrena.py @@ -0,0 +1,12 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + + #junkdealer will be added as soon as i find coords + + return diff --git a/scripts/static_spawns/dantooine/factional_recruiters.py b/scripts/static_spawns/dantooine/factional_recruiters.py index d3514fbf..22c27df9 100644 --- a/scripts/static_spawns/dantooine/factional_recruiters.py +++ b/scripts/static_spawns/dantooine/factional_recruiters.py @@ -11,8 +11,12 @@ def addPlanetSpawns(core, planet): stcSvc = core.staticService objSvc = core.objectService - #recruiter Imp Outpost + #imprecruiter Imp Outpost stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_6.iff', 'dantooine', long(0), float(-4198), float(3), float(-2411), float(0.819), float(-0.572)) + #rebrecruiter abandoned base + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_moncal_male_01.iff', 'dantooine', long(0), float(-6817), float(46), float(5511), float(0), float(-0.707), float(0), float(0.707)) + + return \ No newline at end of file diff --git a/scripts/static_spawns/lok/nyms_stronghold.py b/scripts/static_spawns/lok/nyms_stronghold.py new file mode 100644 index 00000000..c45e284d --- /dev/null +++ b/scripts/static_spawns/lok/nyms_stronghold.py @@ -0,0 +1,18 @@ +import sys +# Project SWG: Imperial Recruiters tatooine: 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 + #recruiter Imp Outpost + + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_03.iff', 'lok', long(0), float(366), float(9), float(5202), float(0.71), float(0), float(0.70), float(0)) + + return \ No newline at end of file diff --git a/scripts/static_spawns/naboo/deeja_peak.py b/scripts/static_spawns/naboo/deeja_peak.py new file mode 100644 index 00000000..6fdf650b --- /dev/null +++ b/scripts/static_spawns/naboo/deeja_peak.py @@ -0,0 +1,15 @@ +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + stcSvc = core.staticService + objSvc = core.objectService + + #junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(5135), float(346.5), float(-1514), float(0.707), float(0.707)) + + + return diff --git a/scripts/static_spawns/naboo/factional_recruiters.py b/scripts/static_spawns/naboo/factional_recruiters.py index 5ddcc31b..4be2c940 100644 --- a/scripts/static_spawns/naboo/factional_recruiters.py +++ b/scripts/static_spawns/naboo/factional_recruiters.py @@ -17,4 +17,8 @@ def addPlanetSpawns(core, planet): #deeja Peek stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_5.iff', 'naboo', long(0), float(5307), float(326), float(-1584), float(0), float(0), float(0), float(0)) + #Rebrecruiter Moenia + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_human_female_02.iff', 'naboo', long(0), float(4827), float(4), float(-4697), float(0), float(-0.707), float(0), float(0.707)) + + return \ No newline at end of file diff --git a/scripts/static_spawns/naboo/kaadara.py b/scripts/static_spawns/naboo/kaadara.py new file mode 100644 index 00000000..bb48cb72 --- /dev/null +++ b/scripts/static_spawns/naboo/kaadara.py @@ -0,0 +1,12 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + + #junkdealer will be added as soon as i find coords + + return diff --git a/scripts/static_spawns/naboo/keren.py b/scripts/static_spawns/naboo/keren.py new file mode 100644 index 00000000..2c6c6ce0 --- /dev/null +++ b/scripts/static_spawns/naboo/keren.py @@ -0,0 +1,16 @@ +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + stcSvc = core.staticService + objSvc = core.objectService + + #junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(1242), float(13), float(2732), float(0.707), float(0.707)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(1774), float(12.5), float(2625), float(0.707), float(0.707)) + + + return diff --git a/scripts/static_spawns/naboo/moenia.py b/scripts/static_spawns/naboo/moenia.py new file mode 100644 index 00000000..4c63c0fc --- /dev/null +++ b/scripts/static_spawns/naboo/moenia.py @@ -0,0 +1,17 @@ + +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + stcSvc = core.staticService + objSvc = core.objectService + + # TODO Check all NPCs for personalized scripting, change format. + + #Junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_03.iff', 'naboo', long(0), float(4318.83), float(5.15), float(-4797.57), float(0), float(1)) + + return diff --git a/scripts/static_spawns/naboo/theed.py b/scripts/static_spawns/naboo/theed.py new file mode 100644 index 00000000..292e9649 --- /dev/null +++ b/scripts/static_spawns/naboo/theed.py @@ -0,0 +1,24 @@ +import sys +from resources.datatables import Options +from resources.datatables import StateStatus + + +def addPlanetSpawns(core, planet): + + stcSvc = core.staticService + objSvc = core.objectService + + #junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5694), float(6.5), float(4182), float(0.707), float(-0.707)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5717), float(6.5), float(4159), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5086), float(6), float(4142), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5147), float(6.5), float(4158), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5114), float(6.5), float(4161), float(0.71), float(-0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5222), float(6), float(4217), float(0.71), float(-0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5127), float(6), float(4239), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5761), float(6.6), float(4234), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5475), float(6), float(4105), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-4999), float(6), float(4119), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'naboo', long(0), float(-5883), float(6), float(4214), float(0.71), float(0.71)) + + return diff --git a/scripts/static_spawns/talus/factional_recruiters.py b/scripts/static_spawns/talus/factional_recruiters.py index 6e8e6969..31a1a19c 100644 --- a/scripts/static_spawns/talus/factional_recruiters.py +++ b/scripts/static_spawns/talus/factional_recruiters.py @@ -14,4 +14,8 @@ def addPlanetSpawns(core, planet): #recruiter Imp Outpost stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_6.iff', 'talus', long(0), float(-2192), float(20), float(2269), float(0), float(0), float(0), float(0)) + #Reb recruiter + dearicCantina = core.objectService.getObject(long(3175388)) + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_human_female_02.iff', 'talus', dearicCantina.getCellByCellNumber(11), float(-25.8), float(-0.9), float(-0.7), float(0), float(-0.707), float(0), float(0.707)) + return \ No newline at end of file diff --git a/scripts/static_spawns/tatooine/anchorhead.py b/scripts/static_spawns/tatooine/anchorhead.py index 5e2fb31e..ff4809f1 100644 --- a/scripts/static_spawns/tatooine/anchorhead.py +++ b/scripts/static_spawns/tatooine/anchorhead.py @@ -16,9 +16,6 @@ def addPlanetSpawns(core, planet): # TODO Check all NPCs for personalized scripting, change format. # Cantina Interior - rebRecruiter = stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_human_female_01.iff', 'tatooine', long(1213345), float(-2.2), float(0.4), float(-5.4), float(0), float(0)) - #rebRecruiter.setOptionsBitmask(264) - borraSetas = stcSvc.spawnObject('object/mobile/shared_dressed_commoner_tatooine_rodian_female_03.iff', 'tatooine', long(1213345), float(9.8), float(0.4), float(-1.2), float(-0.65), float(0.75)) #borraSetas.setCustomName2('Borra Setas') #borraSetas.setOptionsBitmask(256) @@ -47,5 +44,9 @@ def addPlanetSpawns(core, planet): Sorna = stcSvc.spawnObject('object/mobile/shared_dressed_tatooine_tosche_sorna.iff', 'tatooine', long(0), float(-135), float(52.0), float(-5331), float(0.36), float(0.93)) Sorna.setCustomName2('Sorna') Sorna.setOptionsBitmask(256) + + #Junk Dealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(110), float(52), float(-5428), float(0.71), float(0.71)) + return diff --git a/scripts/static_spawns/tatooine/bestine.py b/scripts/static_spawns/tatooine/bestine.py index a636f8c3..7a124bd6 100644 --- a/scripts/static_spawns/tatooine/bestine.py +++ b/scripts/static_spawns/tatooine/bestine.py @@ -96,5 +96,12 @@ def addPlanetSpawns(core, planet): #calebKnolar.setCustomName2('Major Caleb Knolar') #calebKnolar.setOptionsBitmask(256) + #Junk Dealers + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1287), float(12), float(-3655), float(0.71), float(0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1259), float(12), float(-3673), float(0.71), float(-0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1026), float(10), float(-3557), float(0), float(0)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1260), float(12), float(-3573), float(0), float(1)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1126), float(12), float(-3674), float(0.71), float(-0.71)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-1118), float(12), float(-3687), float(0), float(0)) return diff --git a/scripts/static_spawns/tatooine/factional_recruiters.py b/scripts/static_spawns/tatooine/factional_recruiters.py index cf02a957..6f9b4137 100644 --- a/scripts/static_spawns/tatooine/factional_recruiters.py +++ b/scripts/static_spawns/tatooine/factional_recruiters.py @@ -1,5 +1,5 @@ import sys -# Project SWG: Imperial Recruiters tatooine: Static Spawns +# Project SWG: Factional Recruiters tatooine: Static Spawns # (C)2014 ProjectSWG @@ -11,14 +11,20 @@ def addPlanetSpawns(core, planet): stcSvc = core.staticService objSvc = core.objectService - #recruiter Eisley + #Imp recruiter Eisley smallImpHouse = core.objectService.getObject(long(1280129)) stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_f.iff', 'tatooine', smallImpHouse.getCellByCellNumber(3), float(-6), float(1), float(9.2), float(0.71), float(0), float(0.70), float(0)) - #recruiter Bestine + #Imp recruiter Bestine #Hill stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_5.iff', 'tatooine', long(0), float(-1138), float(98), float(-3897), float(0.71), float(0), float(0.70), float(0)) #outside SP stcSvc.spawnObject('object/mobile/shared_dressed_imperial_officer_m_3.iff', 'tatooine', long(0), float(-1275), float(12), float(-3594), float(0), float(0), float(0), float(0)) + # Reb Recruiter + + #Anchorhead cantina + anchCantina = core.objectService.getObject(long(1213343)) + stcSvc.spawnObject('object/mobile/shared_dressed_rebel_recruiter_human_female_01.iff', 'tatooine', anchCantina.getCellByCellNumber(2), float(-2.2), float(0.4), float(-5.4), float(0), float(0), float(0), float(0)) + return \ No newline at end of file diff --git a/scripts/static_spawns/tatooine/mos_entha.py b/scripts/static_spawns/tatooine/mos_entha.py index e99d36ea..4686d285 100644 --- a/scripts/static_spawns/tatooine/mos_entha.py +++ b/scripts/static_spawns/tatooine/mos_entha.py @@ -20,6 +20,11 @@ def addPlanetSpawns(core, planet): ankwee.setCustomName2('An\'kwee') ankwee.setOptionsBitmask(256) - + #Junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(1271), float(7.7), float(2919), float(0), float(0)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(1271), float(7.7), float(2960), float(1), float(0)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(1396), float(7), float(3026), float(0), float(0)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(1471), float(7), float(3325), float(0), float(1)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(1463), float(7), float(3126), float(0.71), float(-0.71)) return diff --git a/scripts/static_spawns/tatooine/mos_espa.py b/scripts/static_spawns/tatooine/mos_espa.py index f2a18ed5..666d8b1b 100644 --- a/scripts/static_spawns/tatooine/mos_espa.py +++ b/scripts/static_spawns/tatooine/mos_espa.py @@ -67,6 +67,9 @@ def addPlanetSpawns(core, planet): commoner23.setCustomName2('a Commoner') commoner23.setOptionsBitmask(256) + #Junkdealer will be added as soon as i can find coords + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_03.iff', 'tatooine', long(0), float(-3060.50), float(5), float(2181.71), float(0), float(1)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_03.iff', 'tatooine', long(0), float(-2924.53), float(5), float(2173.97), float(0), float(1)) return diff --git a/scripts/static_spawns/tatooine/mos_taike.py b/scripts/static_spawns/tatooine/mos_taike.py new file mode 100644 index 00000000..e3e78bf7 --- /dev/null +++ b/scripts/static_spawns/tatooine/mos_taike.py @@ -0,0 +1,22 @@ +import sys +# Project SWG: Mos Taike: 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 + + # TODO Check all NPCs for personalized scripting, change format. + + + #Junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(3902), float(33), float(2362), float(0), float(0)) + return + diff --git a/scripts/static_spawns/tatooine/wayfar.py b/scripts/static_spawns/tatooine/wayfar.py new file mode 100644 index 00000000..4864ed87 --- /dev/null +++ b/scripts/static_spawns/tatooine/wayfar.py @@ -0,0 +1,23 @@ +import sys +# Project SWG: Wayfar: 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 + + # TODO Check all NPCs for personalized scripting, change format. + + + #Junkdealer + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-5242), float(75), float(-6495), float(0), float(0)) + stcSvc.spawnObject('object/mobile/shared_junk_dealer_m_01.iff', 'tatooine', long(0), float(-5129), float(75), float(-6584), float(0), float(0)) + return + diff --git a/src/protocol/swg/auctionManagerClientListener/AuctionQueryHeadersResponseMessage.java b/src/protocol/swg/auctionManagerClientListener/AuctionQueryHeadersResponseMessage.java index 65fbbf26..fa025157 100644 --- a/src/protocol/swg/auctionManagerClientListener/AuctionQueryHeadersResponseMessage.java +++ b/src/protocol/swg/auctionManagerClientListener/AuctionQueryHeadersResponseMessage.java @@ -97,20 +97,20 @@ public class AuctionQueryHeadersResponseMessage extends SWGMessage { result.putInt(item.getPrice()); result.putInt((int) ((item.getExpireTime() - System.currentTimeMillis()) / 1000)); result.putInt(item.getPrice()); + result.putShort((short) getStringIndex(item.getVuid())); + result.putLong(item.getOwnerId()); result.putShort((short) getStringIndex(item.getOwnerName())); - result.putInt(0); - result.putShort((short) 0); + /*result.putInt(0); result.put((byte) 0); - result.put((byte) (item.isAuction() ? 0 : 1)); + result.putShort((short) getStringIndex(item.getOwnerName())); + result.put((byte) 0);*/ result.putLong(0); - result.putShort((short) 0); result.putInt(2); // unk result.putInt(0); result.putShort((short) 0); - result.putInt(0); + result.putInt(item.getItemType()); // gameObjectType/category bitmask - //result.putInt(0x400C); // category bitmask? - result.putInt(0); + result.putInt(0); int options = 0; if(item.getOwnerId() == playerId && (item.getStatus() == AuctionItem.OFFERED || item.getStatus() == AuctionItem.FORSALE)) diff --git a/src/protocol/swg/auctionManagerClientListener/CommoditiesItemTypeListResponse.java b/src/protocol/swg/auctionManagerClientListener/CommoditiesItemTypeListResponse.java index d299a44e..cbf52fe3 100644 --- a/src/protocol/swg/auctionManagerClientListener/CommoditiesItemTypeListResponse.java +++ b/src/protocol/swg/auctionManagerClientListener/CommoditiesItemTypeListResponse.java @@ -22,31 +22,76 @@ package protocol.swg.auctionManagerClientListener; import java.nio.ByteOrder; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Map.Entry; import main.NGECore; import org.apache.mina.core.buffer.IoBuffer; +import org.apache.mina.core.buffer.SimpleBufferAllocator; +import engine.resources.objects.SWGObject; import protocol.swg.SWGMessage; +import services.bazaar.AuctionItem; public class CommoditiesItemTypeListResponse extends SWGMessage { + + private Map> itemList = new HashMap>(); + private static SimpleBufferAllocator bufferPool = new SimpleBufferAllocator(); + + public void addItem(AuctionItem item) { + if(itemList.get(item.getItemType()) == null) + itemList.put(item.getItemType(), new ArrayList()); + itemList.get(item.getItemType()).add(item); + } @Override public void deserialize(IoBuffer data) { // TODO Auto-generated method stub } + /** + * Struct of category lists: + * int numberofcategories + * + * int category + * number of items in category + * + * int server crc (w/o shared_) + * int category + * astring stf filename + * int spacer + * astring stf name + * + */ @Override public IoBuffer serialize() { - // TODO: research how categories work String galaxy = NGECore.getInstance().getGalaxyName(); - IoBuffer result = IoBuffer.allocate(14 + galaxy.length()).order(ByteOrder.LITTLE_ENDIAN); + IoBuffer result = bufferPool.allocate(14 + galaxy.length(), false).order(ByteOrder.LITTLE_ENDIAN); + result.setAutoExpand(true); result.putShort((short) 2); result.putInt(0xD4E937FC); - result.put(getAsciiString(galaxy + ".0")); - result.putInt(0); - return result.flip(); + result.put(getAsciiString(galaxy + "." + Integer.toString(itemList.size()))); + result.putInt(itemList.size()); + + for(Entry> e : itemList.entrySet()) { + result.putInt(e.getKey()); + result.putInt(e.getValue().size()); + for(AuctionItem item : e.getValue()) { + result.putInt(item.getItemTypeCRC()); + result.putInt(item.getItemType()); + result.put(item.getItem().getObjectName().getBytes()); + } + } + + int size = result.position(); + IoBuffer result2 = IoBuffer.allocate(size).put(result.array(), 0, size); + + return result2.flip(); } } diff --git a/src/resources/datatables/LightsaberColors.java b/src/resources/datatables/LightsaberColors.java index cb2028c5..e8adbba9 100644 --- a/src/resources/datatables/LightsaberColors.java +++ b/src/resources/datatables/LightsaberColors.java @@ -62,8 +62,9 @@ public final class LightsaberColors { map.put("Kenobi's Legacy", 28); map.put("Sunrider's Destiny", 29); map.put("Kit's Ferocity", 30); + map.put("Cunning of Tyranus", 31); - // Special crystals that have seperate shaders - the 256 is for a hacky way to set blade type and color without more code + // Special crystals that have seperate shaders - the 256 is for a hacky way to set blade type and color without more code map.put("Lava", 256 + 1); map.put("Permafrost", 256 + 2); map.put("Blackwing Bezoar", 256 + 3); diff --git a/src/services/BuffService.java b/src/services/BuffService.java index de08efd2..8d2d4038 100644 --- a/src/services/BuffService.java +++ b/src/services/BuffService.java @@ -91,11 +91,14 @@ public class BuffService implements INetworkDispatch { if(buff == null) return false; + // Here the necessary checks must be placed to prevent buffs from the same buff group (e.g. Buff D) being stacked! + if(buff.isGroupBuff()) { addGroupBuff(buffer, buffName, buffer); return true; } else { - doAddBuff(target, buffName, buffer); + if (! hasBuff(target,buffName)) // QA, prevent infinite "refreshing" of buff by repeated use + doAddBuff(target, buffName, buffer); return true; } } @@ -290,6 +293,14 @@ public class BuffService implements INetworkDispatch { } + public boolean hasBuff(final CreatureObject creature, String buffName) { + + for(final Buff buff : creature.getBuffList().get().toArray(new Buff[] { })) { + if (buff.getBuffName().contains(buffName)) { return true; } + } + return false; + } + public void addGroupBuff(CreatureObject buffer, String buffName) { try { throw new Exception(); diff --git a/src/services/LootService.java b/src/services/LootService.java index 1b009f25..98b4520e 100644 --- a/src/services/LootService.java +++ b/src/services/LootService.java @@ -39,9 +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.SceneCreateObjectByCrc; +import resources.objects.craft.DraftSchematic; import resources.common.OutOfBand; import resources.datatables.DisplayType; import resources.loot.LootGroup; @@ -57,6 +57,9 @@ import services.sui.SUIWindow; import services.sui.SUIWindow.SUICallback; import services.sui.SUIWindow.Trigger; import main.NGECore; +import engine.clientdata.ClientFileManager; +import engine.clientdata.visitors.SlotArrangementVisitor; +import engine.resources.container.AllPermissions; import engine.resources.common.Stf; import engine.resources.container.CreatureContainerPermissions; import engine.resources.container.Traverser; @@ -158,34 +161,46 @@ public class LootService implements INetworkDispatch { if (projectionCoefficientMatrixModulo!=0) lootGroupRoll=groupChance+1; if (lootGroupRoll <= groupChance){ - System.out.println("this lootGroup will drop something"); + //System.out.println("this lootGroup will drop something"); handleLootGroup(lootGroup,lootRollSession); //this lootGroup will drop something e.g. {kraytpearl_range,krayt_tissue_rare} - } - System.out.println("While Loop Stuck check"); + } } - System.out.println("Past while "); - // Rare Loot System Stage (Is in place for all looted creatures) - if (lootRollSession.isAllowRareLoot()){ + + // Rare Loot System Stage (Is in place for all looted creatures with 6 CL difference) + //if (lootRollSession.isAllowRareLoot()){ + if (true){ int randomRareLoot = new Random().nextInt(100); int chanceRequirement = 1; + chanceRequirement = 10; // This is for a test period to lift chest drop chance a bit + if (lootRollSession.getLootedObjectDifficulty()==1) + chanceRequirement+=2; + if (lootRollSession.getLootedObjectDifficulty()==2) + chanceRequirement+=3; if (lootRollSession.isIncreasedRLSChance()) - chanceRequirement+=3; // RLS chance is at 4% for groupsize >= 4 + chanceRequirement+=3; if (randomRareLoot <= chanceRequirement){ handleRareLootChest(lootRollSession); } + + // to test: + //handleRareLootChest(lootRollSession); } // set info above corpse - System.out.println("lootedObject instanceof CreatureObject " + (lootedObject instanceof CreatureObject)); + //System.out.println("lootedObject instanceof CreatureObject " + (lootedObject instanceof CreatureObject)); if (lootedObject instanceof CreatureObject){ - float y = 0.5F; // 1.3356977F - float qz= 1.06535322E9F; - Point3D effectorPosition = new Point3D(0,y,0); - Quaternion effectorOrientation = new Quaternion(0,0,0,qz); - PlayClientEffectObjectTransformMessage lmsg = new PlayClientEffectObjectTransformMessage("appearance/pt_loot_disc.prt",lootedObject.getObjectID(),"lootMe",effectorPosition,effectorOrientation); - requester.getClient().getSession().write(lmsg.serialize()); - tools.CharonPacketUtils.printAnalysis(lmsg.serialize()); + try { + float y = 0.5F; // 1.3356977F + float qz= 1.06535322E9F; + Point3D effectorPosition = new Point3D(0,y,0); + Quaternion effectorOrientation = new Quaternion(0,0,0,qz); + PlayClientEffectObjectTransformMessage lmsg = new PlayClientEffectObjectTransformMessage("appearance/pt_loot_disc.prt",lootedObject.getObjectID(),"lootMe",effectorPosition,effectorOrientation); + requester.getClient().getSession().write(lmsg.serialize()); + tools.CharonPacketUtils.printAnalysis(lmsg.serialize()); + } catch (Exception e) { + e.printStackTrace(); + } } // handle errors @@ -208,6 +223,7 @@ public class LootService implements INetworkDispatch { for (TangibleObject droppedItem : lootRollSession.getDroppedItems()){ //droppedItem.setAttachment("radial_filename", "lootitem"); + //if (! droppedItem.getTemplate().contains("shared_rare_loot_chest")) lootedObjectInventory.add(droppedItem); // RLS chest effect @@ -682,6 +698,10 @@ public class LootService implements INetworkDispatch { droppedItem.setJunkType(junkType); } + if (biolink>0){ + droppedItem.setStringAttribute("bio_link", "bio_link_pending"); + } + if (itemStats!=null){ if (itemStats.size()%3!=0){ String errorMessage = "Loot item '" + itemName + "' has a wrong number of itemstats. Please contact Charon about this issue."; @@ -721,7 +741,6 @@ public class LootService implements INetworkDispatch { lootRollSession.addDroppedItem(droppedItem); - System.out.println("END REACHED"); } private void handleCustomDropName(TangibleObject droppedItem,String customName) { @@ -740,6 +759,12 @@ public class LootService implements INetworkDispatch { return droppedItem; } + private DraftSchematic createDroppedSchematic(String template,Planet planet){ + DraftSchematic droppedItem = (DraftSchematic) core.objectService.createObject(template, planet); + //System.out.println("droppedItem " + droppedItem); + return droppedItem; + } + private void handleRareLootChest(LootRollSession lootRollSession){ TangibleObject droppedItem = null; @@ -750,6 +775,10 @@ public class LootService implements INetworkDispatch { if (lootRollSession.isIncreasedRLSChance()) chancemodifier += 15; + //legendaryRoll=500; // For TEST + //legendaryRoll=1; // For TEST + //exceptionalRoll = 5; + if (legendaryRoll<2+chancemodifier){ String itemTemplate="object/tangible/item/shared_rare_loot_chest_3.iff"; droppedItem = createDroppedItem(itemTemplate,lootRollSession.getSessionPlanet()); @@ -760,7 +789,7 @@ public class LootService implements INetworkDispatch { droppedItem.setDetailName("rare_loot_chest_3_d"); droppedItem.setAttachment("LootItemName", itemName); droppedItem.getAttributes().put("@obj_attr_n:rare_loot_category", "\\#D1F56F Rare Item \\#FFFFFF "); - fillLegendaryChest(droppedItem); + //fillLegendaryChest(droppedItem, lootRollSession); } else if (exceptionalRoll<10+chancemodifier){ String itemTemplate="object/tangible/item/shared_rare_loot_chest_2.iff"; @@ -772,7 +801,7 @@ public class LootService implements INetworkDispatch { droppedItem.setDetailName("rare_loot_chest_2_d"); droppedItem.setAttachment("LootItemName", itemName); droppedItem.getAttributes().put("@obj_attr_n:rare_loot_category", "\\#D1F56F Rare Item \\#FFFFFF "); - fillExceptionalChest(droppedItem); + //fillExceptionalChest(droppedItem, lootRollSession); } else { String itemTemplate="object/tangible/item/shared_rare_loot_chest_1.iff"; droppedItem = createDroppedItem(itemTemplate,lootRollSession.getSessionPlanet()); @@ -783,21 +812,374 @@ public class LootService implements INetworkDispatch { droppedItem.setDetailName("rare_loot_chest_1_d"); droppedItem.setAttachment("LootItemName", itemName); droppedItem.getAttributes().put("@obj_attr_n:rare_loot_category", "\\#D1F56F Rare Item \\#FFFFFF "); - fillRareChest(droppedItem); + //fillRareChest(droppedItem, lootRollSession); } lootRollSession.addDroppedItem(droppedItem); } - private void fillLegendaryChest(TangibleObject droppedItem){ + public void fillrarelootchest(CreatureObject owner, TangibleObject chest){ + SWGObject inventory = owner.getSlottedObject("inventory"); + inventory.remove(chest); + + if (chest.getTemplate().contains("object/tangible/item/shared_rare_loot_chest_1.iff")){ + fillRareChest(owner, chest); + } + if (chest.getTemplate().contains("object/tangible/item/shared_rare_loot_chest_2.iff")){ + fillExceptionalChest(owner, chest); + } + if (chest.getTemplate().contains("object/tangible/item/shared_rare_loot_chest_3.iff")){ + fillLegendaryChest(owner, chest); + } + core.objectService.destroyObject(chest.getObjectID()); } - private void fillExceptionalChest(TangibleObject droppedItem){ + private void fillLegendaryChest(CreatureObject owner, TangibleObject chest){ + int itemNumber = 2; + int quantityModifierChance = new Random().nextInt(100); + if (quantityModifierChance>25 && quantityModifierChance<50) + itemNumber = 1; + if (quantityModifierChance<25) + itemNumber = 3; + List lootGroups = new ArrayList(); + for (int i=0;i iterator = lootGroups.iterator(); + + while (iterator.hasNext()){ + LootGroup lootGroup = iterator.next(); + fillChest2(lootGroup, owner, chest); + } + } + + private void fillExceptionalChest(CreatureObject owner, TangibleObject chest){ + int itemNumber = 2; + int quantityModifierChance = new Random().nextInt(100); + if (quantityModifierChance>25 && quantityModifierChance<50) + itemNumber = 1; + if (quantityModifierChance<25) + itemNumber = 3; + + List lootGroups = new ArrayList(); + for (int i=0;i iterator = lootGroups.iterator(); + + while (iterator.hasNext()){ + LootGroup lootGroup = iterator.next(); + fillChest2(lootGroup, owner, chest); + } } - private void fillRareChest(TangibleObject droppedItem){ + private void fillRareChest(CreatureObject owner, TangibleObject chest){ + + int itemNumber = 1; + int quantityModifierChance = new Random().nextInt(100); + if (quantityModifierChance>15 && quantityModifierChance<50) + itemNumber = 2; + if (quantityModifierChance<15) + itemNumber = 3; + + List lootGroups = new ArrayList(); + for (int i=0;i iterator = lootGroups.iterator(); + + while (iterator.hasNext()){ + LootGroup lootGroup = iterator.next(); + fillChest2(lootGroup, owner, chest); + } + } + + private void fillChest2(LootGroup lootGroup, CreatureObject owner, TangibleObject chest){ + + double[] lootPoolChances = lootGroup.getLootPoolChances(); + String[] lootPoolNames = lootGroup.getLootPoolNames(); + if (lootPoolChances==null || lootPoolNames==null){ + System.err.println("Lootpools are null!"); + return; + } + if (lootPoolChances.length==0 || lootPoolNames.length==0){ + System.err.println("No Lootpools in Lootgroup!"); + return; + } + + double randomItemFromGroup = new Random().nextDouble()*100; + double remainder = 0; // [10,20,30,34,5,1] + double span = 100/lootPoolNames.length; + + boolean test = false; + + for(int i=0;i itemNames = (Vector)core.scriptService.fetchStringVector(path,"itemNames"); + + Vector itemChances = (Vector)core.scriptService.fetchDoubleVector(path,"itemChances"); + + double randomItemFromPool = new Random().nextDouble()*100; + double remainder = 0.0; // [10,20,30,34,5,1] + double span = 100.0/(double)itemNames.size(); + + for (int i=0;i foundPath = new Vector(); + Path p = Paths.get("scripts/loot/lootItems/"); + FileVisitor fv = new SimpleFileVisitor() { + @Override + public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException { + String actualFileName = file.getFileName().toString(); + actualFileName = actualFileName.substring(0, actualFileName.length()-3); + if (actualFileName.equals(itemName.toLowerCase())){ + foundPath.add(file.toString()); + } + return FileVisitResult.CONTINUE; + } + }; + try { + Files.walkFileTree(p, fv); + } catch (IOException e) { + e.printStackTrace(); + } + + + if (foundPath.size()==0){ + String errorMessage = "Loot item '" + itemName + "' not found in file system. Please contact Charon about this issue."; + return; + + } + String itemPath = foundPath.get(0); + + itemPath = itemPath.substring(0, itemPath.length()-3); // remove the file type + + String customName = ""; + String itemTemplate = ""; + Vector itemTemplates = null; + int stackCount = 1; + int biolink = 0; + int requiredCL = 1; + int requiredLevelForEffect = 1; + int stackable = -1; + int junkDealerPrice = 0; + byte junkType = -1; + String requiredProfession = ""; + String requiredFaction = ""; + Vector customizationAttributes = null; + Vector customizationValues = null; + int customColor1 = 0; + String lootDescriptor = ""; + Vector itemStats = null; + Vector itemSkillMods = 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."; + return; + } + + itemTemplates = (Vector)core.scriptService.fetchStringVector(itemPath,"itemTemplate"); + if (itemTemplates.size()==1) + itemTemplate = itemTemplates.get(0); + if (itemTemplates.size()>1){ + itemTemplate = itemTemplates.get(new Random().nextInt(itemTemplates.size()-1)); + } + + // only consider the following variables, if they are in the python-script file + if(core.scriptService.getMethod(itemPath,"","customItemName")!=null) + customName = (String)core.scriptService.fetchString(itemPath,"customItemName"); + + if(core.scriptService.getMethod(itemPath,"","customItemStackCount")!=null) + stackCount = (Integer)core.scriptService.fetchInteger(itemPath,"customItemStackCount"); + + if(core.scriptService.getMethod(itemPath,"","customizationAttributes")!=null) + customizationAttributes = (Vector)core.scriptService.fetchStringVector(itemPath,"customizationAttributes"); + + if(core.scriptService.getMethod(itemPath,"","customizationValues")!=null) + customizationValues = (Vector)core.scriptService.fetchIntegerVector(itemPath,"customizationValues"); + + if(core.scriptService.getMethod(itemPath,"","customColor1")!=null) + customColor1 = (Integer)core.scriptService.fetchInteger(itemPath,"customColor1"); + + if(core.scriptService.getMethod(itemPath,"","lootDescriptor")!=null) + lootDescriptor = (String)core.scriptService.fetchString(itemPath,"lootDescriptor"); + + if(core.scriptService.getMethod(itemPath,"","itemStats")!=null) + itemStats = (Vector)core.scriptService.fetchStringVector(itemPath,"itemStats"); + + if(core.scriptService.getMethod(itemPath,"","itemSkillMods")!=null) + itemSkillMods = (Vector)core.scriptService.fetchStringVector(itemPath,"itemSkillMods"); + + if(core.scriptService.getMethod(itemPath,"","biolink")!=null) + biolink = (Integer)core.scriptService.fetchInteger(itemPath,"biolink"); + + if(core.scriptService.getMethod(itemPath,"","requiredCL")!=null) + requiredCL = (Integer)core.scriptService.fetchInteger(itemPath,"requiredCL"); + + if(core.scriptService.getMethod(itemPath,"","requiredLevelForEffect")!=null) + requiredLevelForEffect = (Integer)core.scriptService.fetchInteger(itemPath,"requiredLevelForEffect"); + + if(core.scriptService.getMethod(itemPath,"","requiredProfession")!=null) + requiredProfession = (String)core.scriptService.fetchString(itemPath,"requiredProfession"); + + if(core.scriptService.getMethod(itemPath,"","requiredFaction")!=null) + requiredFaction = (String)core.scriptService.fetchString(itemPath,"requiredFaction"); + + if(core.scriptService.getMethod(itemPath,"","stackable")!=null) + stackable = (Integer)core.scriptService.fetchInteger(itemPath,"stackable"); + + if(core.scriptService.getMethod(itemPath,"","junkDealerPrice")!=null) + junkDealerPrice = (Integer)core.scriptService.fetchInteger(itemPath,"junkDealerPrice"); + + if(core.scriptService.getMethod(itemPath,"","junkType")!=null) + junkType = (byte)core.scriptService.fetchInteger(itemPath,"junkType"); + + + System.out.println("itemTemplate " + itemTemplate); + + TangibleObject droppedItem = null; + + if (! itemTemplate.contains("schematic")){ + + droppedItem = createDroppedItem(itemTemplate,owner.getPlanet()); + + droppedItem.setLootItem(true); + droppedItem.setAttachment("LootItemName", itemName); + droppedItem.setAttachment("customColor1", customColor1); + droppedItem.setAttachment("lootDescriptor", lootDescriptor); + droppedItem.setAttachment("customName", customName); + + + + if (!customName.isEmpty()) + handleCustomDropName(droppedItem, customName); + + if (stackable!=-1){ + if(stackable==1) + droppedItem.setStackable(true); + else + droppedItem.setStackable(false); + } + + if (junkDealerPrice!=0){ + droppedItem.setJunkDealerPrice(junkDealerPrice); + } + + if (junkType!=-1){ + droppedItem.setJunkType(junkType); + } + + if (itemStats!=null){ + if (itemStats.size()%3!=0){ + String errorMessage = "Loot item '" + itemName + "' has a wrong number of itemstats. Please contact Charon about this issue."; + return; + } + handleStats(droppedItem, itemStats); + } + + if (itemSkillMods!=null){ + handleSkillMods(droppedItem, itemSkillMods); + } + + setCustomization(droppedItem, itemName); // for now + + handleSpecialItems(droppedItem, itemName); + + if (requiredCL>1){ + droppedItem.setIntAttribute("required_combat_level", requiredCL); + } + + if (requiredLevelForEffect>1) { + droppedItem.getAttributes().put("@proc/proc:effect_level", ""+requiredLevelForEffect); + } + + if (requiredProfession.length()>0){ + droppedItem.setStringAttribute("class_required", requiredProfession); + } + + if (requiredFaction.length()>0){ + droppedItem.setStringAttribute("required_faction", requiredFaction); + } + + if (biolink>0){ + droppedItem.setStringAttribute("bio_link", "@obj_attr_n:bio_link_pending"); + } + + if(core.scriptService.getMethod(itemPath,"","customSetup") != null) + core.scriptService.callScript(itemPath, "", "customSetup", droppedItem); + + + 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()); + } else + { + DraftSchematic 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()); + } + } + + } + + public void handleChestItem(String itemName, TangibleObject chest){ } @@ -824,6 +1206,23 @@ public class LootService implements INetworkDispatch { droppedItem.setCustomizationVariable("/private/index_color_1", (byte) 0x21); // 0x1F } + String lootDescriptor = (String)droppedItem.getAttachment("lootDescriptor"); + if (lootDescriptor==null) + lootDescriptor=""; + if (lootDescriptor.contains("rarecolorcrystal")) { + System.out.println("rarecolorcrystal"); + + int saberColor = (Integer)droppedItem.getAttachment("customColor1"); + if (saberColor==31) // Cunning of Tyranus, which is not in @jedi_spam + saberColor=0; + + 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"); + } + // More general // String path = "scripts/loot/lootItems/"+droppedItem.getCustomName().toLowerCase(); // Vector customizationPaths = (Vector)core.scriptService.fetchStringVector(path,"itemCustomizationPaths"); @@ -846,7 +1245,7 @@ public class LootService implements INetworkDispatch { private void handleStats(TangibleObject droppedItem, Vector itemStats) { - if (droppedItem.getTemplate().contains("/weapon")){ + if (droppedItem.getTemplate().contains("object/weapon")){ WeaponObject weaponObject = (WeaponObject) droppedItem; for (int i=0;i skillMods) { @@ -1190,7 +1611,9 @@ public class LootService implements INetworkDispatch { if (statName.equals("elemdamage")){ int minimalValue = (int) Integer.parseInt(minValue); int maximalValue = (int) Integer.parseInt(maxValue); - int randomValue = minimalValue + new Random().nextInt(maximalValue-minimalValue); + int randomValue = minimalValue; + if (minimalValue0) + result = minValue; + if (maxValue.length()>0) + result = maxValue; + crystal.setAttachment("ElementalType", result); + } + + if (statName.equals("elemdamage")){ + int minimalValue = (int) Integer.parseInt(minValue); + int value = minimalValue; + crystal.setAttachment("ElementalDamage", value); + } + } + + private void setBuffItemStat(TangibleObject buffItem, String statName, String minValue, String maxValue){ + + if (statName.equals("effectname")){ + String result = minValue; + if (minValue.length()==0) + if (maxValue.length()==0) + result = "Error"; + buffItem.setAttachment("BuffEffectName", result); + buffItem.getAttributes().put("@obj_attr_n:proc_name", result); + } + + if (statName.equals("proc_name")){ + String result = minValue; + if (minValue.length()==0) + if (maxValue.length()==0) + result = "Error"; + buffItem.setAttachment("BuffProcName", result); + buffItem.setStringAttribute("proc_name",result); + } + + + if (statName.equals("duration")){ + int minimalValue = (int) Integer.parseInt(minValue); + buffItem.setAttachment("BuffEffectDuration", minimalValue); + } + + if (statName.equals("cooldown")){ + /* + String displayString = ""; + String[] cooldownArr = minValue.split(":"); // 24:00:00 -> HH:MM:SS + if (cooldownArr.length==3){ + String hours = cooldownArr[0]; + String minutes = cooldownArr[1]; + String seconds = cooldownArr[2]; + if (hours.equals("00") || hours.equals("0")){ + displayString=minutes + " minutes"; + } else + { + displayString=hours + " hours, " + minutes + " minutes"; + } + } else + { + displayString= "Format Error!"; + } + */ + String displayString = minValue + " sec"; + int minimalValue = (int) Integer.parseInt(minValue); + buffItem.setAttachment("BuffEffectCoolDown", minimalValue); + buffItem.getAttributes().put("@obj_attr_n:reuse_time", displayString); + buffItem.getAttributes().put("@ui_attrib_mod:timeleft", "0"); + } + + // Deal with buff items that have colorcrystal templates or not unique templates , because no py script can be used for them to set the radials + + // Shard of the Serpent + if (buffItem.getCustomName().contains("Serpent")){ + buffItem.setAttachment("radial_filename", "item/item"); + buffItem.setStfFilename("static_item_n"); + buffItem.setStfName("item_tow_buff_crystal_02_03"); + buffItem.setDetailFilename("static_item_d"); + buffItem.setDetailName("item_tow_buff_crystal_02_03"); + buffItem.setCustomizationVariable("/private/index_color_1", (byte) 3); + } + // Shard of Ferocity + if (buffItem.getCustomName().contains("Ferocity")){ + buffItem.setAttachment("radial_filename", "item/item"); + buffItem.setStfFilename("static_item_n"); + buffItem.setStfName("item_tow_crystal_uber_01_05"); + buffItem.setDetailFilename("static_item_d"); + buffItem.setDetailName("item_tow_crystal_uber_01_05"); + buffItem.setCustomizationVariable("/private/index_color_1", (byte) 9); + + } + // Shard of Retaliation + if (buffItem.getCustomName().contains("Retaliation")){ + buffItem.setAttachment("radial_filename", "item/item"); + buffItem.setStfFilename("static_item_n"); + buffItem.setStfName("item_tow_crystal_uber_02_05"); + buffItem.setDetailFilename("static_item_d"); + buffItem.setDetailName("item_tow_crystal_uber_02_05"); + } + // Sith Buff Holocron + if (buffItem.getCustomName().contains("Sith")){ + buffItem.setAttachment("radial_filename", "item/item"); + buffItem.setStfFilename("static_item_n"); + buffItem.setStfName("item_tow_holocron_ab_immune_01_02"); + buffItem.setDetailFilename("static_item_d"); + buffItem.setDetailName("item_tow_holocron_ab_immune_01_02"); + } + } + private void setArmorStat(SWGObject armor, String statName, String minValue, String maxValue){ // Armor is not represented with its own class, // so we gotta create the attributes here diff --git a/src/services/PlayerService.java b/src/services/PlayerService.java index 9eb592f6..11a81f58 100644 --- a/src/services/PlayerService.java +++ b/src/services/PlayerService.java @@ -126,6 +126,13 @@ public class PlayerService implements INetworkDispatch { creature.getClient().getSession().write(packet); }, 45, 45, TimeUnit.SECONDS)); + scheduleList.add(scheduler.scheduleAtFixedRate(() -> { + PlayerObject player = (PlayerObject) creature.getSlottedObject("ghost"); + player.setTotalPlayTime((int) (player.getTotalPlayTime() + ((System.currentTimeMillis() - player.getLastPlayTimeUpdate()) / 1000))); + player.setLastPlayTimeUpdate(System.currentTimeMillis()); + core.collectionService.checkExplorationRegions(creature); + }, 30, 30, TimeUnit.SECONDS)); + scheduleList.add(scheduler.scheduleAtFixedRate(() -> { if (creature.isInStealth() && !creature.getOption(Options.INVULNERABLE) && ((PlayerObject) creature.getSlottedObject("ghost")).getGodLevel() == 0) { List objects = core.simulationService.get(creature.getPlanet(), creature.getPosition().x, creature.getPosition().z, 64); @@ -149,15 +156,12 @@ public class PlayerService implements INetworkDispatch { } } } + + if (creature.getDefendersList().size() == 0 && creature.isInCombat()) { + creature.setInCombat(false); + } }, 15, 15, TimeUnit.SECONDS)); - scheduleList.add(scheduler.scheduleAtFixedRate(() -> { - PlayerObject player = (PlayerObject) creature.getSlottedObject("ghost"); - player.setTotalPlayTime((int) (player.getTotalPlayTime() + ((System.currentTimeMillis() - player.getLastPlayTimeUpdate()) / 1000))); - player.setLastPlayTimeUpdate(System.currentTimeMillis()); - core.collectionService.checkExplorationRegions(creature); - }, 30, 30, TimeUnit.SECONDS)); - scheduleList.add(scheduler.scheduleAtFixedRate(() -> { if(creature.getAction() < creature.getMaxAction() && creature.getPosture() != 14) { if(!creature.isInCombat()) @@ -1341,7 +1345,7 @@ public class PlayerService implements INetworkDispatch { @Override public void process(SWGObject owner, int eventType, Vector returnList) { - if (eventType == 0 && returnList.get(0) != null) { + if (eventType == 0 && returnList.size() > 0 && returnList.get(0) != null) { int bounty = Integer.parseInt(returnList.get(0)); int totalFunds = victim.getBankCredits() + victim.getCashCredits(); diff --git a/src/services/SimulationService.java b/src/services/SimulationService.java index 1610fb0f..f93defd4 100644 --- a/src/services/SimulationService.java +++ b/src/services/SimulationService.java @@ -341,9 +341,9 @@ public class SimulationService implements INetworkDispatch { CreatureObject creature = (CreatureObject) client.getParent(); - CreatureObject object = (CreatureObject) client.getParent(); + CreatureObject object = creature; - if (core.mountService.isMounted(object)) { + if (core.mountService.isMounted(creature) && creature.getObjectID() == ((CreatureObject) creature.getContainer()).getOwnerId()) { object = (CreatureObject) object.getContainer(); } @@ -371,59 +371,41 @@ public class SimulationService implements INetworkDispatch { add(object, newPos.x, newPos.z); } - - - //object.setParentId(0); //object.setParent(null); // System.out.println("Parsed Height: " + core.terrainService.getHeight(object.getPlanetId(), dataTransform.getXPosition(), dataTransform.getZPosition()) // + " should be: " + dataTransform.getYPosition()); UpdateTransformMessage utm = new UpdateTransformMessage(object.getObjectID(), dataTransform.getTransformedX(), dataTransform.getTransformedY(), dataTransform.getTransformedZ(), dataTransform.getMovementCounter(), (byte) dataTransform.getMovementAngle(), dataTransform.getSpeed()); - - List newAwareObjects = get(object.getPlanet(), newPos.x, newPos.z, 512); - ArrayList oldAwareObjects = new ArrayList(object.getAwareObjects()); - @SuppressWarnings("unchecked") Collection updateAwareObjects = CollectionUtils.intersection(oldAwareObjects, newAwareObjects); object.notifyObservers(utm, false); - + + List newAwareObjects = get(creature.getPlanet(), newPos.x, newPos.z, 512); + ArrayList oldAwareObjects = new ArrayList(creature.getAwareObjects()); + @SuppressWarnings("unchecked") Collection updateAwareObjects = CollectionUtils.intersection(oldAwareObjects, newAwareObjects); + for(int i = 0; i < oldAwareObjects.size(); i++) { SWGObject obj = oldAwareObjects.get(i); - if(!updateAwareObjects.contains(obj) && obj != object && obj.getWorldPosition().getDistance2D(newPos) > 200 && obj.isInQuadtree() /*&& obj.getParentId() == 0*/) { + if(!updateAwareObjects.contains(obj) && obj != creature && obj.getWorldPosition().getDistance2D(newPos) > 200 && obj.isInQuadtree() /*&& obj.getParentId() == 0*/) { if(obj.getAttachment("bigSpawnRange") != null && obj.getWorldPosition().getDistance2D(newPos) < 512) continue; - object.makeUnaware(obj); + creature.makeUnaware(obj); if(obj.getClient() != null) - obj.makeUnaware(object); - } else if(obj != object && obj.getWorldPosition().getDistance2D(newPos) > 200 && obj.isInQuadtree() && obj.getAttachment("bigSpawnRange") == null) { - object.makeUnaware(obj); + obj.makeUnaware(creature); + } else if(obj != creature && obj.getWorldPosition().getDistance2D(newPos) > 200 && obj.isInQuadtree() && obj.getAttachment("bigSpawnRange") == null) { + creature.makeUnaware(obj); if(obj.getClient() != null) - obj.makeUnaware(object); + obj.makeUnaware(creature); } } + for(int i = 0; i < newAwareObjects.size(); i++) { SWGObject obj = newAwareObjects.get(i); //System.out.println(obj.getTemplate()); - if(!updateAwareObjects.contains(obj) && obj != object && !object.getAwareObjects().contains(obj) && obj.getContainer() != object && obj.isInQuadtree()) { + if(!updateAwareObjects.contains(obj) && obj != creature && !creature.getAwareObjects().contains(obj) && obj.getContainer() != creature && obj.isInQuadtree()) { if(obj.getAttachment("bigSpawnRange") == null && obj.getWorldPosition().getDistance2D(newPos) > 200) continue; - //object.makeAware(obj); - - if (object.getOption(Options.MOUNT)){ - CreatureObject owner = (CreatureObject) core.objectService.getObject(object.getOwnerId()); - owner.makeAware(obj); - } - else { - object.makeAware(obj); - } - - if(obj.getClient() != null){ - if (object.getOption(Options.MOUNT)){ - CreatureObject owner = (CreatureObject) core.objectService.getObject(object.getOwnerId()); - obj.makeAware(owner); - } - else { - obj.makeAware(object); - } - } + creature.makeAware(obj); + if(obj.getClient() != null) + obj.makeAware(creature); } } @@ -434,8 +416,7 @@ public class SimulationService implements INetworkDispatch { object.getEventBus().publish(event); } - - + }); objControllerOpcodes.put(ObjControllerOpcodes.DATA_TRANSFORM_WITH_PARENT, new INetworkRemoteEvent() { @@ -485,7 +466,7 @@ public class SimulationService implements INetworkDispatch { if(object.getContainer() != null) object.getContainer()._remove(object); if (object.getClient().isGM() && parent != null && parent instanceof CellObject && parent.getContainer() != null) - object.sendSystemMessage("BuildingId Hex: " + Long.toHexString(parent.getContainer().getObjectID()) + " CellNumber: " + ((CellObject) parent).getCellNumber(), DisplayType.Broadcast); + object.sendSystemMessage("BuildingId - Dec: " + parent.getContainer().getObjectID() + " Hex: " + Long.toHexString(parent.getContainer().getObjectID()) + " CellNumber: " + ((CellObject) parent).getCellNumber(), DisplayType.Broadcast); parent._add(object); } object.setPosition(newPos); @@ -767,6 +748,7 @@ public class SimulationService implements INetworkDispatch { return new Point3D(x, y, z); } + /* * Moved this to ConnectionService which will disconnect them * from the server if they don't send packets for 5 minutes or more @@ -845,7 +827,7 @@ public class SimulationService implements INetworkDispatch { if (object.getAttachment("disconnectTask") != null) { try { - core.combatService.endCombat(object); + core.combatService.endCombat((CreatureObject) object); } catch (Exception e) { e.printStackTrace(); } diff --git a/src/services/bazaar/AuctionItem.java b/src/services/bazaar/AuctionItem.java index 4e0d2fca..0c8d23be 100644 --- a/src/services/bazaar/AuctionItem.java +++ b/src/services/bazaar/AuctionItem.java @@ -41,6 +41,7 @@ public class AuctionItem implements Comparable, Serializable { private long buyerId; private long offerToId; private int itemType; + private int itemTypeCRC; private String ownerName; private String bidderName = ""; private String itemName; @@ -51,7 +52,7 @@ public class AuctionItem implements Comparable, Serializable { private boolean auction; private String vuid; private int status; - private boolean onBazaar; + private boolean onBazaar = false; private long expireTime; private int auctionOptions; @@ -278,5 +279,13 @@ public class AuctionItem implements Comparable, Serializable { else return 0; } + + public int getItemTypeCRC() { + return itemTypeCRC; + } + + public void setItemTypeCRC(int itemTypeCRC) { + this.itemTypeCRC = itemTypeCRC; + } } diff --git a/src/services/bazaar/BazaarService.java b/src/services/bazaar/BazaarService.java index 32f760a2..98a85288 100644 --- a/src/services/bazaar/BazaarService.java +++ b/src/services/bazaar/BazaarService.java @@ -22,7 +22,9 @@ package services.bazaar; import java.nio.ByteOrder; +import java.util.ArrayList; import java.util.Iterator; +import java.util.List; import java.util.Map; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; @@ -30,8 +32,12 @@ import java.util.concurrent.ConcurrentSkipListSet; import java.util.concurrent.Executors; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; + + + import main.NGECore; import engine.clients.Client; +import engine.resources.common.CRC; import engine.resources.database.ODBCursor; import engine.resources.objects.SWGObject; import engine.resources.scene.Planet; @@ -112,7 +118,16 @@ public class BazaarService implements INetworkDispatch { if (player == null) return; - + + CommoditiesItemTypeListResponse response = new CommoditiesItemTypeListResponse(); + + List insertedItems = new ArrayList(); + auctionItems.stream().filter(i -> !insertedItems.contains(i.getItem().getObjectName().getStfValue())).forEach(i -> { + response.addItem(i); + insertedItems.add(i.getItem().getObjectName().getString()); + System.out.println(i.getItem().getObjectName().getString()); + }); + session.write(new CommoditiesItemTypeListResponse().serialize()); }); @@ -359,7 +374,7 @@ public class BazaarService implements INetworkDispatch { if(vendor == null) return; - getItemData(player, vendor, queryHeaders.getRange(), queryHeaders.getScreen(), queryHeaders.getCounter(), queryHeaders.getOffset(), queryHeaders.getItemTypeCRC(), queryHeaders.getMinPrice(), queryHeaders.getMaxPrice()); + getItemData(player, vendor, queryHeaders.getRange(), queryHeaders.getScreen(), queryHeaders.getCounter(), queryHeaders.getOffset(), queryHeaders.getCategory(), queryHeaders.getMinPrice(), queryHeaders.getMaxPrice()); }); @@ -531,7 +546,6 @@ public class BazaarService implements INetworkDispatch { int displayedItems = 0; AuctionQueryHeadersResponseMessage response = new AuctionQueryHeadersResponseMessage(player.getObjectID(), screen, counter, offset, false); - while(it.hasNext() && displayedItems < offset + 100) { AuctionItem item = it.next(); @@ -544,10 +558,12 @@ public class BazaarService implements INetworkDispatch { // Auctions case 2: if(item.getStatus() == AuctionItem.FORSALE && item.isOnBazaar()) { - if((category & 255) != 0 && item.getItemType() == category) { - if(displayedItems >= offset) - response.addItem(item); - displayedItems++; + if((category & 255) != 0) { + if(item.getItemType() == category) { + if(displayedItems >= offset) + response.addItem(item); + displayedItems++; + } } else if((item.getItemType() & category) != 0) { if(displayedItems >= offset) response.addItem(item); @@ -726,16 +742,17 @@ public class BazaarService implements INetworkDispatch { auctionItem.setItemDescription(description); auctionItem.setPrice(price); auctionItem.setItemType(item.getTemplateData().getAttribute("gameObjectType")); + auctionItem.setItemTypeCRC(CRC.StringtoCRC(item.getTemplate().replace("shared_", ""))); auctionItem.setStatus(AuctionItem.FORSALE); //auctionItem.setItemName("@" + item.getStfFilename() + ":" + item.getStfName()); - String name = item.getCustomName() == null ? "@" + item.getStfFilename() + ":" + item.getStfName() : item.getCustomName(); + String name = item.getCustomName() == null ? item.getObjectName().getStfValue() : item.getCustomName(); auctionItem.setItemName(name); auctionItem.setVendorId(vendor.getObjectID()); auctionItem.setPlanet(vendor.getPlanet().getName()); auctionItem.setVuid(getVendorUID((TangibleObject) vendor)); auctionItem.setOwnerName(player.getCustomName()); - if(vendor.getTemplate().contains("terminal_bazaar")) + if(vendor.getAttachment("isVendor") == null) auctionItem.setOnBazaar(true); else { if(!((long) vendor.getAttachment("vendorOwner") == player.getObjectID())) { diff --git a/src/services/object/ObjectService.java b/src/services/object/ObjectService.java index 47a5ab93..c2aa8e82 100644 --- a/src/services/object/ObjectService.java +++ b/src/services/object/ObjectService.java @@ -129,6 +129,9 @@ import services.command.CombatCommand; import services.bazaar.AuctionItem; import services.chat.ChatRoom; import services.equipment.EquipmentService; +import services.sui.SUIWindow; +import services.sui.SUIWindow.SUICallback; +import services.sui.SUIWindow.Trigger; @SuppressWarnings("unused") public class ObjectService implements INetworkDispatch { @@ -669,11 +672,54 @@ public class ObjectService implements INetworkDispatch { return objectId; } - public void useObject(CreatureObject creature, SWGObject object) { + public void useObject(CreatureObject creature, final SWGObject object) { if (creature == null || object == null) { return; } + // Bio-Linking + String bl = object.getStringAttribute("bio_link"); + if (bl!=null){ + if (! object.getContainer().getTemplate().contains("shared_character_inventory")){ + creature.sendSystemMessage("@base_player:must_biolink_to_use_from_inventory", (byte)1); + return; + } + if (! bl.contains("@obj_attr_n:bio_link_pending") && ! bl.contains(creature.getCustomName())){ + creature.sendSystemMessage("@base_player:not_linked_to_holder", (byte)1); + return; + } + if (bl.contains("@obj_attr_n:bio_link_pending")){ + creature.setAttachment("BioLinkItemCandidate", object.getObjectID()); + SUIWindow window = core.suiService.createSUIWindow("Script.messageBox", creature, creature, 0); + window.setProperty("bg.caption.lblTitle:Text", "@sui:bio_link_item_title"); + window.setProperty("Prompt.lblPrompt:Text", "@sui:bio_link_item_prompt"); + window.setProperty("btnCancel:visible", "True"); + window.setProperty("btnOk:visible", "True"); + window.setProperty("btnUpdate:visible", "False"); + window.setProperty("btnCancel:Text", "@cancel"); + window.setProperty("btnOk:Text", "@ui_radial:bio_link"); + Vector returnList = new Vector(); + returnList.add("List.lstList:SelectedRow"); + window.addHandler(0, "", Trigger.TRIGGER_OK, returnList, new SUICallback() { + @Override + public void process(SWGObject owner, int eventType, Vector returnList) { + ((CreatureObject)owner).sendSystemMessage("@base_player:item_bio_linked", (byte)1); + object.setStringAttribute("bio_link", owner.getCustomName()); + object.setAttachment("bio_link_PlayerID", owner.getObjectID()); + return; + } + }); + window.addHandler(1, "", Trigger.TRIGGER_CANCEL, returnList, new SUICallback() { + @Override + public void process(SWGObject owner, int eventType, Vector returnList) { + return; + } + }); + core.suiService.openSUIWindow(window); + return; + } + } + creature.setUseTarget(object); int reuse_time; @@ -711,7 +757,7 @@ public class ObjectService implements INetworkDispatch { return; } - creature.addCooldown(cooldownGroup, object.getIntAttribute("reuse_time")); + creature.addCooldown(cooldownGroup, reuse_time); } foundTemplate = true; @@ -720,12 +766,12 @@ public class ObjectService implements INetworkDispatch { } } - if (!foundTemplate) { + if (!foundTemplate && reuse_time > 0) { if (creature.hasCooldown(object.getTemplate())) { return; } - creature.addCooldown(object.getTemplate(), object.getIntAttribute("reuse_time")); + creature.addCooldown(object.getTemplate(), reuse_time); } } catch (Exception e) { e.printStackTrace();