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






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Gold Loot
Author Message
XuN
Sphere Developer
*****

Posts: 852
Likes Given: 102
Likes Received: 156 in 119 posts
Joined: Jul 2013
Reputation: 30



Post: #11
RE: Gold Loot
Is there any special reason to use a custom Shrink? If not ... I suggest you to do this:

Code:
[function petshrink]
sysmessage=@09c1 To whom do you wish to duel?
targetf _petshrink

[function _petshrink]
if (<argo.id>==c_system_pet_rabbit)
argo.shrink 1 // the 1 will bounce the figurine
act.events +t_pet_rabbit_fix // act is automatically set to the figurine. No need to override the type, just add one event to it.
endif

[typedef t_pet_rabbit_fix]
ON=@DClick
if (<topobj>!=<src>)
src.sysmessage @09c1 You must have the item in your pack.  
return 1 //stop the action, and because you are using one event instead of overriding the type ... default actions (unshrink) will be performed after this.
endif

You are saving some lines of code being executed and stored in memory. You are not removing the pet, so you won't have problems in the future with storing tags/changing skills/properties/whatever because you'll be using the same one.
03-19-2015 05:48 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
Gold Loot - Van Glan Bloom - 03-09-2015, 09:36 AM
RE: Gold Loot - azmanomer - 03-09-2015, 09:39 AM
RE: Gold Loot - Van Glan Bloom - 03-10-2015, 12:59 AM
RE: Gold Loot - azmanomer - 03-10-2015, 01:29 AM
RE: Gold Loot - Van Glan Bloom - 03-10-2015, 03:26 AM
RE: Gold Loot - XuN - 03-17-2015, 08:42 PM
RE: Gold Loot - Van Glan Bloom - 03-17-2015, 11:51 PM
RE: Gold Loot - darksun84 - 03-18-2015, 12:13 AM
RE: Gold Loot - XuN - 03-18-2015, 06:10 AM
RE: Gold Loot - Van Glan Bloom - 03-18-2015, 11:33 PM
RE: Gold Loot - XuN - 03-19-2015 05:48 PM
RE: Gold Loot - Van Glan Bloom - 03-22-2015, 08:21 AM
RE: Gold Loot - UltimaAku - 04-28-2015, 07:43 PM
RE: Gold Loot - richm - 04-29-2015, 08:19 AM
RE: Gold Loot - Van Glan Bloom - 05-03-2015, 02:22 AM
RE: Gold Loot - XuN - 05-03-2015, 04:37 AM
RE: Gold Loot - Van Glan Bloom - 05-03-2015, 08:32 AM
RE: Gold Loot - XuN - 05-03-2015, 05:25 PM
RE: Gold Loot - Van Glan Bloom - 05-04-2015, 10:34 PM
RE: Gold Loot - XuN - 05-05-2015, 04:57 PM
RE: Gold Loot - Van Glan Bloom - 05-05-2015, 09:47 PM
RE: Gold Loot - XuN - 05-06-2015, 04:19 PM
RE: Gold Loot - Van Glan Bloom - 05-07-2015, 09:22 AM
RE: Gold Loot - XuN - 05-07-2015, 04:32 PM

Forum Jump:


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