The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 786 - File: showthread.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/showthread.php 786 errorHandler->error






Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Creating New Gathering Skill
Author Message
Archaaz
Journeyman
*

Posts: 98
Likes Given: 12
Likes Received: 4 in 4 posts
Joined: Aug 2013
Reputation: 1



Post: #1
Creating New Gathering Skill
I am trying to create a new gathering skill, but do not want it attached to any of the other gathering skills. The idea is to create a Foraging skill that can be triggered by ON=@DClick a particular item (perhaps some sort of special knife), and then being able to @TARGON on a variety of new Region Resource Types and gather certain Resources (mostly reagents, but a few others as well).

I have been looking through the Sphere files, and read both the Scripting tutorial and the Making Your Own Skills tutorial, and have a few questions. I am not sure I am on the right track or not. I understand how to create the item (knife) for the trigger, and have discovered a lot of pieces, but I am not sure exactly how they fit, or rather where the actual meat of the script is supposed to go, or if it works in some other manner.

1. Is it possible to create such a skill, unconnected to the others?
2. If so, is there an actual script behind the gathering skills (I cannot seem to find any, beyond the basics in the Script folder) I can use as an example?

Slightly modified Lumberjacking Skill (I left the numbers the same):
Quote:[SKILL --]
DEFNAME=SKILL_FORAGING
FLAGS=SKF_SCRIPTED
KEY=Lumberjacking
TITLE=Forager (working title)
PROMPT_MSG=
DELAY=1.0
STAT_STR=85
STAT_INT=30
STAT_DEX=45
BONUS_STR=90
BONUS_DEX=10
BONUS_INT=0
BONUS_STATS=20
ADV_RATE=2.5,50.0,200.0
VALUES=1,10,50

ON=@Fail
SRC.SYSMESSAGE @,,2 500495

ON=@Abort
SRC.SYSMESSAGE You decide not to forage for now.

[eof]

3. Can the Key be changed to Foraging? Is this merely the skill level?
4. What causes the Lumberjacking skill to trigger when an equipped axe is d-clicked, and from what file? I do not see any such triggers looking through the items (axes and bladed)

Resource to be Gathered:
Quote:[ITEMDEF 0f7b]
//Blood Moss
DEFNAME=i_reag_blood_moss
TYPE=T_REAGENT
VALUE=3
PILE=1
WEIGHT=.1
CATEGORY=Provisions - Alchemy & Magic
SUBSECTION=Reagents - Normal
DESCRIPTION=Blood Moss

Item to Be Harvested From (Targeted):
Quote:[ITEMDEF 0cf3]
//fallen log
DEFNAME=i_log_fallen
VALUE=1
CATEGORY=Vegetation
SUBSECTION=Trees
DESCRIPTION=Fallen Log

Sphere_Types
Quote:[TYPEDEF t_fallen_log]
TERRAIN = 0cf3
(and various sister items and dupes)

5. Can an Item be made a Terrain Type in this manner?

Sphere_Region
Quote:[REGIONTYPE r_default_fallen_log t_fallen_log]
// Default fallen log area resources
RESOURCES=5.0 mr_blood moss

Sphere_Region_Resource
Quote:[REGIONRESOURCE mr_fallen_log]
// t_fallen_log
skill=85.0,100.0
amount=1,5
reap=i_blood_moss
regen=60*60*2
09-05-2013 03:44 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
Creating New Gathering Skill - Archaaz - 09-05-2013 03:44 AM
RE: Creating New Gathering Skill - Archaaz - 09-05-2013, 02:23 PM
RE: Creating New Gathering Skill - Archaaz - 09-05-2013, 09:48 PM
RE: Creating New Gathering Skill - Archaaz - 09-06-2013, 06:47 PM
RE: Creating New Gathering Skill - Archaaz - 09-07-2013, 07:06 PM

Forum Jump:


User(s) browsing this thread: 4 Guest(s)