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
[split] 56b - some problems ....
Author Message
an0n!m0use
Journeyman
*

Posts: 56
Likes Given: 16
Likes Received: 0 in 0 posts
Joined: Feb 2013
Reputation: 0



Post: #1
Question [split] 56b - some problems ....
Another problem ...

Script:
PHP Code:
[ITEMDEF i_restore_bers]
Name=Restoration
ID
=00F09
WEIGHT
=25

On
=@Create
    COLOR
=042c
    morey 
25

on
=@click
message 
<name> (<eval <morey>>)
return 
1
 
On
=@Dclick
 
if !<src.tag0.berserker>)
  
src.message @55 Only Berserker can drink restoration!
  return 

 
endif
 if <
src.hits> >= <src.str>
  return 

 
endif
 if <
src.tag0.berserker>==1
    more1 
= { 15 17 }
 elseif <
src.tag0.berserker>==2
    more1 
= { 17 20 }
 elseif <
src.tag0.berserker>==3
    more1 
= { 20 23 }
 elseif <
src.tag0.berserker>==4
    more1 
= { 23 26 }
 endif
 if 
0<src.findid.i_rest_delay_level1>
  
src.sysmessage @55 You cant drink restoration yet
  
return 
 
else
  if <
morey> > 1
   src
.effect=3,0376a,10,25,10
   src
.hits=<src.hits> + { <more1> }
   
serv.newitem=i_rest_delay_level1
   
new.equip
   morey 
-= 1
  
else
   
remove
  
endif
 endif
  if <
src.hits> > <src.str>)
   
src.hits=<src.str
  endif
return 
1

[ITEMDEF i_rest_delay_level1
Id i_bottle_6 
Name 
Restore Delay level 1 
Weight 

Layer 
30 
Type t_eq_script 

On
=@Create 
    attr 
attr_newbie attr_decay 
 
On
=@Equip 
 
if <src.tag0.berserker>==1
  timer 
5
 
elseif <src.tag0.berserker>==2
  timer 
4
 
elseif <src.tag0.berserker>==3
  timer 
3
 
elseif <src.tag0.berserker>==4
  timer 
3
 
endif

On=@Timer 
 remove 
 
return 

When I try a drink this, I just die ... What's the problem?



And second problem ... After resurrect ... With this script:
PHP Code:
[ITEMDEF i_ress_floor]
id=01822
name
=Resurrect

on
=@create
    attr
=010
    timer
=-1
    color
=0446
    
on
=@click
    message 
<name>
    return 
1
    
on
=@step

    
if ( (<src.body>==c_ghost_man) || (<src.body>==c_ghost_woman) )
        
src.go britain
        src
.resurrect
        src
.update
        src
.consume 1 i_deathshroud
        src
.hits = <src.str>
        
src.mana = <src.int>
        
src.stam = <src.dex>
    else
        
src.sysmessage @55 It is only for ghosts!
        return 
1
    
endif 

I do not know how to explain .... I like a ghost ... Bet, after command ",resend" (Inject) it's all right ...

It's after resurrect ... Floor "Up!" working after, resend ....
[Image: adcfedb88c4f.jpg]
03-09-2013 06:39 AM
Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

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

Erehwon New Hera

Post: #2
RE: 56b - some problems ....
Code:
endif
  if <src.hits> > <src.str>)
   src.hits=<src.str>
  endif
return 1

i see a parentesis that is not opened Tongue

and one more thing, why u use morey first, then more1, then morey again? shouldn't be always morey? (and actually, is better if u use more1, since morey is about coordinates)


i don't get it what about the second problem... but i would do like this:
Code:
on=@step
    if ( (<src.body>==c_ghost_man) || (<src.body>==c_ghost_woman) )
        src.go britain
        src.resurrect
        src.consume 1 i_deathshroud
        src.hits = <src.str>
        src.mana = <src.int>
        src.stam = <src.dex>
        update  
else
        src.sysmessage @55 It is only for ghosts!
        return 1
    endif
Return 0

one personal question: do u play drakensang online?
(This post was last modified: 03-09-2013 07:17 AM by Crusader.)
03-09-2013 07:07 AM
Find all posts by this user Like Post Quote this message in a reply
Mordaunt
Super Moderator
****

Posts: 1,237
Likes Given: 26
Likes Received: 55 in 43 posts
Joined: Mar 2012
Reputation: 35



Post: #3
RE: [split] 56b - some problems ....
Have split this, please start new threads for new problems so people can identify them more easily.

[Image: 2nis46r.jpg]
03-09-2013 09:41 AM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
an0n!m0use
Journeyman
*

Posts: 56
Likes Given: 16
Likes Received: 0 in 0 posts
Joined: Feb 2013
Reputation: 0



Post: #4
RE: 56b - some problems ....
(03-09-2013 07:07 AM)Crusader Wrote:  and one more thing, why u use morey first, then more1, then morey again? shouldn't be always morey? (and actually, is better if u use more1, since morey is about coordinates)
And how would you do? I do not get ... Tried a hundred variants Sad


(03-09-2013 07:07 AM)Crusader Wrote:  i don't get it what about the second problem... but i would do like this:
Code:
on=@step
   ....
    endif
Return 0
Did not help Sad

(03-09-2013 07:07 AM)Crusader Wrote:  one personal question: do u play drakensang online?
No Veryhappy Why do you think I played there? Smile
03-09-2013 11:01 AM
Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

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

Erehwon New Hera

Post: #5
RE: [split] 56b - some problems ....
the point is that i don't understand what u want to do with ur potion and what u want to do with the ress tile.
u just want that the char with the ress tile is gonna be ressed and updated to avoid particular showing of 'residual' stuff ?
try this:

on=@step
if ( (<src.body>==c_ghost_man) || (<src.body>==c_ghost_woman) )
src.resurrect
src.consume 1 i_deathshroud
src.hits = <src.str>
src.mana = <src.int>
src.stam = <src.dex>
src.go britain
update
else
src.sysmessage @55 It is only for ghosts!
return 1
endif
Return 0


for the potion i don't understand what u want to do, explain.
For the game, coz in that game there is a guy called an0nym0use Big Grin
03-09-2013 11:06 PM
Find all posts by this user Like Post Quote this message in a reply
an0n!m0use
Journeyman
*

Posts: 56
Likes Given: 16
Likes Received: 0 in 0 posts
Joined: Feb 2013
Reputation: 0



Post: #6
RE: [split] 56b - some problems ....
(03-09-2013 11:06 PM)Crusader Wrote:  the point is that i don't understand what u want to do with ur potion and what u want to do with the ress tile.
u just want that the char with the ress tile is gonna be ressed and updated to avoid particular showing of 'residual' stuff ?
try this:

on=@step
....
endif
Return 0
It's working Woot Thx Tongue

(03-09-2013 11:06 PM)Crusader Wrote:  for the potion i don't understand what u want to do, explain.
For the game, coz in that game there is a guy called an0nym0use Big Grin
I have race Berserker ...
And this race has 3 leveled ...
Level 1 - +15 +17 hits and delay 5 seconds
Level 2 - +17 +20 hits and delay 4 seconds
Level 3 lvl - +20 +23 hits and delay 3 seconds

Importantly, when i drink a bottle ... not knock a swing Smile
03-10-2013 12:12 AM
Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

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

Erehwon New Hera

Post: #7
RE: [split] 56b - some problems ....
so...if i'm a berserk and i drink that potion i will be healed for that points and the delay is that one. ok.

Code:
[ITEMDEF i_restore_bers]
Name=Restoration
ID=00F09
WEIGHT=25

On=@Create
    COLOR=042c
    more2 = 25

on=@click
message <name> (<eval <more2>>)
return 1

ON=@DCLICK
IF !(<SRC.TAG0.BERSERKER>)
SRC.MESSAGE @55 Only Berserker can drink restoration!
RETURN 1
ELSE
    IF (<SRC.TAG0.BERSERKER>==1)
        MORE1={15 17}
    ELIF (<SRC.TAG0.BERSERKER>==2)
        MORE1={17 20}    
    ELIF (<SRC.TAG0.BERSERKER>==3)
        MORE1={20 23}
    ELSE
        MORE1={23 26}
    ENDIF            
ENDIF
IF (<SRC.HITS> >= <SRC.MAXHITS>)
        SRC.MESSAGE @55 You are already at maximum healt!
        RETURN 1
ENDIF
IF (<SRC.FINDID.i_rest_delay_level1>)
        SRC.SYSMESSAGE @55 You can't drink restoration potion yet
        RETURN 1
ENDIF
IF (<EVAL <MORE2>> > 0)
    SRC.EFFECT=3,0376a,10,25,10
    IF (<EVAL <SRC.HITS> + <MORE1>> >= <SRC.MAXHITS>)
        SRC.HITS = <SRC.MAXHITS>
    ELSE
        SRC.HITS += <EVAL <MORE1>>
        ENDIF
    SERV.NEWITEM=i_rest_delay_level1
    NEW.EQUIP <SRC.UID>
    MORE2 -= 1
    SRC.SYSMESSAGE Charges left <EVAL <MORE2>>
ELSE
    SRC.SYSMESSAGE @55 Charges over!
        REMOVE
ENDIF

[ITEMDEF i_rest_delay_level1]
ID=i_memory
Name=Restore Delay level 1
Type=t_eq_script

On=@Create
    attr = attr_newbie | attr_decay

On=@Equip
IF (<SRC.TAG0.BERSERKER>==1)
    TIMER=5
ELIF (<SRC.TAG0.BERSERKER>==2)
    TIMER=4
ELIF (<SRC.TAG0.BERSERKER>==3)
    TIMER=3
ELSE
    TIMER=3
ENDIF    
RETURN 0

ON=@Timer
REMOVE
RETURN 1
(This post was last modified: 03-10-2013 01:01 AM by Crusader.)
03-10-2013 12:28 AM
Find all posts by this user Like Post Quote this message in a reply
an0n!m0use
Journeyman
*

Posts: 56
Likes Given: 16
Likes Received: 0 in 0 posts
Joined: Feb 2013
Reputation: 0



Post: #8
RE: [split] 56b - some problems ....
(03-10-2013 12:28 AM)Crusader Wrote:  so...if i'm a berserk and i drink that potion i will be healed for that points and the delay is that one. ok.

[ITEMDEF i_restore_bers]
...
Yep Wink Not working ... afrer use die .... Sad
03-10-2013 12:45 AM
Find all posts by this user Like Post Quote this message in a reply
Crusader
Master
**

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

Erehwon New Hera

Post: #9
RE: [split] 56b - some problems ....
yeah i just put a wrong script, i was editing ^^' try the one i put there
03-10-2013 12:46 AM
Find all posts by this user Like Post Quote this message in a reply
an0n!m0use
Journeyman
*

Posts: 56
Likes Given: 16
Likes Received: 0 in 0 posts
Joined: Feb 2013
Reputation: 0



Post: #10
RE: [split] 56b - some problems ....
(03-10-2013 12:46 AM)Crusader Wrote:  yeah i just put a wrong script, i was editing ^^' try the one i put there

PHP Code:
....

ON=@DCLICK
IF !(<SRC.TAG0.BERSERKER>)
SRC.MESSAGE @55 Only Berserker can drink restoration!
RETURN 

ELSE    
    
SRC.MESSAGE <MORE1>

..... 


[Image: 717b2cc8a095.jpg]

Checked with command .xshow type - 'type' for 'Restoration' is 't_potion'
03-10-2013 12:56 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


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