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
Regeneration armor uhm uhm!
Author Message
Crusader
Master
**

Posts: 254
Likes Given: 7
Likes Received: 19 in 12 posts
Joined: Apr 2012
Reputation: 6

Erehwon New Hera

Post: #4
RE: Regeneration armor uhm uhm!
i had also a problem with armors that drains mana:

badly regen tags doesn't work properly, they always regen even if i put zero or -100 as a regen value.


i guess the only way to do this is modify the typedef of the armor and add a timer every 3 seconds that lower mana to 0.

I tryed also this:

EDIT: i just fixed this version and now seems to work properly

Code:
[TYPEDEF T_ARMOR_LEATHER]  // but also t_armor
ON=@EQUIP
IF !(<TAG0.ALLOWMANA>) && !(<SRC.ISGM>)
    IF (<SRC.ACTION> == skill_meditation)
        SRC.ACTION = -1
        SRC.SYSMESSAGE You can't meditate with armor.
    ENDIF
    SRC.MESSAGE Mana drained by the armor!
    SRC.MANA = 0
    SRC.MAXMANA = 1
    IF !(<SRC.TAG0.ARMORMANA>)
        SRC.TAG.ARMORMANA = 1
        SRC.EVENTS +e_nomedit
    ELSE
        SRC.TAG.ARMORMANA += 1
    ENDIF
ENDIF
RETURN 0

ON=@UNEQUIP
IF !(<TAG0.ALLOWMANA>) && !(<SRC.ISGM>)
    SRC.TAG.ARMORMANA -= 1
    IF !(<SRC.TAG0.ARMORMANA>) || (<EVAL <SRC.TAG0.ARMORMANA>> <= 0)
        SRC.MAXMANA =
        SRC.TAG0.ARMORMANA =
        SRC.EVENTS -e_nomedit
    ENDIF
ENDIF
RETURN 0

///////////////////////////////////////////////////////////
// armor events
///////////////////////////////////////////////////////////

[EVENTS e_nomedit]

ON=@SKILLPRESTART
IF (<ARGN1> == 46)
    SRC.SYSMESSAGE You can't meditate in this state
    RETURN 1
ENDIF
RETURN 0



Now i need to address the regen life problem.

For the moment, the best approach seems to be:

1) a typedef to add as tevents on all the pieces of the armor, with timer that every 3 second give +1 hitpoint, if hits are below 50.

2) like before, but instead of having every pieces of the armor with timer, use only one timer within a memory, to add to the player as the first item is equipped, and through the more1 value, raise his regen value
(every armor piece added will increase the more by one, so On timer the player will be healed for the <more1> value of the memory

Any other suggestions are more than appreciated!
(This post was last modified: 03-02-2013 02:50 AM by Crusader.)
03-02-2013 01:29 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
Regeneration armor uhm uhm! - Crusader - 03-01-2013, 10:22 PM
RE: Regeneration armor uhm uhm! - Crusader - 03-02-2013 01:29 AM
RE: Regeneration armor uhm uhm! - RanXerox - 03-02-2013, 09:25 AM

Forum Jump:


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