![]() |
Minimal Lumberjacking - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: General Help (/Forum-General-Help) +--- Thread: Minimal Lumberjacking (/Thread-Minimal-Lumberjacking) Pages: 1 2 |
Minimal Lumberjacking - Rostok - 02-19-2017 03:44 PM Hello all! I'm tryed to create minimal lumberjacking, but failed =(( System: Ubuntu 16 Spheresvr: Sphere Version 0.56d-Release [Linux] by http://www.spherecommunity.net Compiled: Feb 13 2017 (12:32:30) [build 333 / GIT hash 4f84c89] There are my scripts: lumber_res.scp PHP Code: // Craft-Item REGION_TYPE PHP Code: [REGIONTYPE r_default_tree t_tree] MAP PHP Code: [AREADEF a_world] SKILL LUMBERJACKING PHP Code: [SKILL 44] Seems that's all... So problem: Every time i'm trying to chop a tree with hatchet i see only text "It appears immune to your blow" ... There was no any error with similar scripts for mining, but lumberjacking fails... Please help me, i'm stuck with that basic functionality =(( p.s. i will try to test this with 56c too... Tryed to get 56c sources - failed =( RE: Minimal Lumberjacking - Rostok - 02-19-2017 04:57 PM Ok, I got working Lumberjacking with scripts-pack from GitHub... That means that my build is ok, and problem is in scripts... uh... RE: Minimal Lumberjacking - Rostok - 02-19-2017 06:01 PM Om, i got it! Seems that this section helped: [ITEMDEF 01bdd] DEFNAME=i_log NAME=log%s TYPE=t_log VALUE=1 WEIGHT=0.5 DUPELIST=01bde,01bdf,01be0,01be1,01be2 [ITEMDEF i_Willow_log] ID=i_log DEFNAME=i_Willow_log NAME=Willow log%s VALUE=10 TYPE=T_LOG WEIGHT=.5 CATEGORY=Resources DESCRIPTION=Log RE: Minimal Lumberjacking - Coruja - 02-20-2017 12:58 PM try using axe weapons (TYPE=t_weapon_axe), because I can't remember correctly but maybe swords (TYPE=t_weapon_sword) only get kindling instead logs from trees RE: Minimal Lumberjacking - Rostok - 02-20-2017 03:14 PM Thank you! RE: Minimal Lumberjacking - Rostok - 03-02-2017 07:47 AM Some new problem with gathering: I cannot gather more resources than i set in AMOUNT PHP Code: [REGIONRESOURCE mr_tree] I'm trying to create luck-chance to gather more resources sometimes and stuck with PHP Code: @ResourceFound Tryed to change ARGO.AMOUNT in @ResourceFound - fail Tryed to change <ARGN1> in @Resourcegather - In this case i can get ONLY MAX amount from PHP Code: [REGIONRESOURCE mr_tree] - AMOUNT I know, that resources are creating after @ResourceFound, so it is normal system behavior, but how i can get write-access to amount of resources? Thank You! Sphere 56d RE: Minimal Lumberjacking - darksun84 - 03-02-2017 09:15 PM argn1 in @resourcegather works fine for me, remember that you can't get more resource than there are in the gembit (if the gembit have 10 resources, and you set argn1 to 30 you'll get 10 resources). RE: Minimal Lumberjacking - Rostok - 03-02-2017 10:08 PM (03-02-2017 09:15 PM)darksun84 Wrote: argn1 in @resourcegather works fine for me, remember that you can't get more resource than there are in the gembit (if the gembit have 10 resources, and you set argn1 to 30 you'll get 10 resources). Yes, i understand that. Question is "How to set custom resources amount in gembit when gembit is created, or how to change it after creation?" Thank you in advance! RE: Minimal Lumberjacking - Rostok - 03-03-2017 01:43 AM I will try <ARGO.AMOUNT> in @RegionResourceFound this evening ... <ARGO.AMOUNT> in @ResourceFound failed - value always is "1" =(( RE: Minimal Lumberjacking - darksun84 - 03-03-2017 02:17 AM I took a look in the save file and i noticed this: //This is a gembit related to a lumberjacking resource [WORLDITEM i_worldgem_bit] SERIAL=040001fd4 TIMER=35808 AMOUNT=5 TYPE=t_tree ATTR=092 MORE1=mr_tree P=1522,1750,1 After we change the amount, this happens: [WORLDITEM i_worldgem_bit] SERIAL=040001fd4 TIMER=35808 AMOUNT=5 TYPE=t_tree ATTR=092 MORE1=mr_tree P=1522,1750,1 AMOUNT=10 Looks like that the new amount is added at the bottom of the item block instead of overwriting the previous value |