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-nmm6 (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-nmm6 (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-nmm6 (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-nmm6 (Linux)
File Line Function
/showthread.php 786 errorHandler->error






Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Stabler System
Author Message
admin phoenix
Master
**

Posts: 354
Likes Given: 1
Likes Received: 23 in 13 posts
Joined: Mar 2012
Reputation: 3



Post: #1
Stabler System
PHP Code:
// ###########################################################################​###########################################
// #                                                            #
// #                        Stable Script SYSTEM BY Admin Phoenix aka Levanthis            #
// #                                                            #
// #    You have to redesign the Gump Pics for yourself                                    #
// #                                                            #
// #    Features:                                                    #
// #    Store your pet                                                     #
// #    Storing max Pets Numbers depends from your taming Skill                                #
// #    Sell your pet                                                    #
// #    Buy Pets                                                    #
// ###########################################################################​########################################### 


[DEFNAME stabler_defname]
stabler_budget    2500
stabler_time    12
*60*60

[DIALOG d_stallmenue]
0,0
page 0

ref2
=<src.uid>
FORCONT <FINDLAYER.29.uid1
    
IF (<link.uid> == <ref2.uid>)
        
local.+=1
        local
.name_<dlocal.a>=<name>
        
local.icon_<dlocal.a>=<id>
        
local.color_<dlocal.a>=<color>
    ENDIF
ENDFOR
local.max=<eval <src.taming>/100>
local.max -= <local.a>
IF (<
dlocal.max> == 0)
    
local.max=1
ELSEIF (<dlocal.max> < 0)
    
local.max=0
ENDIF

gumppic 0 0 <hval 08b>

button 520 430 <hval 0f2> <hval 0f11 0 0 // cancel
button 520 405 <hval 0f7> <hval 0f81 0 1 // ok

button 260 106 <hval 037> <hval 0371 0 3 // sell

IF (<dlocal.max> > 0)
    
button 260 139 <hval 037> <hval 0371 0 2 // store pet
ELSE
    
dhtmlgump 260 139 320 60 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>N/A
ENDIF

dhtmlgump 468 195 320 60 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED> <name>, <def.br>the Stabler //name

dhtmlgump 495 312 320 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED> <dlocal.a// stored pet

dhtmlgump 495 382 320 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED> <dlocal.max// max stored

button 260 172 <hval 037> <hval 0370 3 0 // buy

page 1

IF (<dlocal.a> > 0)
    FOR 
b 1 <dlocal.a>
        IF (<
dlocal.b> < 6)
            
local.= <eval <local.b>*40>
            
checkbox 80 <eval <local.y>+190> <hval 02600> <hval 02601<dlocal.b>
            
tilepichue 150 <eval <local.y>+196> <local.icon_<dlocal.b>> <dlocal.color_<dlocal.b>>
            
dhtmlgump 230 <eval <local.y>+195120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED><local.name_<dlocal.b>>
        ENDIF
    ENDFOR
ENDIF

IF (<
dlocal.a> > 5)
    
button 423 395 <hval 08c> <hval 08d0 2 0 // page up
ENDIF

page 2

IF (<dlocal.a> > 5)
    FOR 
b 1 <dlocal.a>
        IF (<
dlocal.b> > 5)
            
local.= <eval (<local.b>-5)*55>
            
checkbox 80 <eval <local.y>+175> <hval 02600> <hval 02601<dlocal.b>
            
tilepichue 150 <eval <local.y>+180> <local.icon_<dlocal.b>> <dlocal.color_<dlocal.b>>
            
dhtmlgump 230 <eval <local.y>+180120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED><local.name_<dlocal.b>>
        ENDIF
    ENDFOR
ENDIF

button 423 395 <hval 08e> <hval 08f0 1 0 // page down

page 3
dhtmlgump 75 205 40 20 0 0 
<def.BFONT_SIZE7> <def.Bfont_DRED>GP

dhtmlgump 75 240 120 20 0 0 
<def.BFONT_SIZE7> <def.Bfont_DRED>75
tilepic 150 230 
<serv.chardef.c_rabbit.ICON>
dhtmlgump 230 240 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Rabbit
button 360 240 
<hval 037> <hval 0371 0 4 // buy

dhtmlgump 75 270 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>100
tilepic 150 270 
<serv.chardef.c_cat.ICON>
dhtmlgump 230 270 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Cat
button 360 270 
<hval 037> <hval 0371 0 5 // buy

dhtmlgump 75 300 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>150
tilepic 150 300 
<serv.chardef.c_dog.ICON>
dhtmlgump 230 300 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Dog
button 360 300 
<hval 037> <hval 0371 0 6 // buy

dhtmlgump 75 330 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>175
tilepic 150 327 
<serv.chardef.c_eagle.ICON>
dhtmlgump 230 330 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Eagle
button 360 330 
<hval 037> <hval 0371 0 7 // buy

dhtmlgump 75 360 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>200
tilepic 150 345 
<serv.chardef.c_llama_pack.ICON>
dhtmlgump 230 360 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Pack Lama
button 360 360 
<hval 037> <hval 0371 0 8 // buy

dhtmlgump 75 390 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>230
tilepic 150 380 
<serv.chardef.c_horse_pack.ICON>
dhtmlgump 230 390 120 20 0 0 <def.BFONT_SIZE7> <def.Bfont_DRED>Pack Horse
button 360 390 
<hval 037> <hval 0371 0 9 // buy

[DIALOG d_stallmenue button]
ON=0
smsg 
@<def0.def_smsg_norm>,3 Canceled the action.

ON=1
ref2
=<src.uid>
FORCONT <FINDLAYER.29.uid1
    
IF (<link.uid> == <ref2.uid>)
        
local.+=1
        local
.uid_<dlocal.a>=<uid>
    ENDIF
ENDFOR
FOR 
x 1 <dlocal.a>
    IF (<
argchk[<dlocal.x>]> == 1)
        
uid.<local.uid_<dlocal.x>>.useitem
    
ENDIF
ENDFOR

ON=2
ref2
=<src.uid>
FORCONT <FINDLAYER.29.uid1
    
IF (<link.uid> == <ref2.uid>)
        
local.+=1
    
ENDIF
ENDFOR
local.max=<eval <src.taming>/100>
IF (<
dlocal.max> < 2)
    
local.max=2
ENDIF
local.max -= <local.a>

IF (<
dlocal.max> < 1)
    
src.smsg @<def0.def_smsg_norm>,3 You can not put any more pet here!
ELSE
    if !<
findlayer.layer_bankbox.uid>
        
serv.newitem i_bankbox
        
new.cont = <uid>
        new.
layer 29
    
endif
    
src.targetf f_stable_npc <findlayer.layer_bankbox.uid>
    
src.smsg @<def0.def_smsg_norm>,3 Choose the pet you want to store there.
ENDIF
RETURN 
1

ON
=3
src
.smsg @<def0.def_smsg_norm>,3 Which pet you want to sell?
src.targetf f_sell_animal <uid>

ON=4 10
IF (<argn1> == 4)
    
src.f_stabler_buy 75,i_pet_RABBIT_2,c_rabbit
ELSEIF (<argn1> == 5)
    
src.f_stabler_buy 100,i_pet_CAT,c_cat
ELSEIF (<argn1> == 6)
    
src.f_stabler_buy 150,i_pet_DOG,c_dog
ELSEIF (<argn1> == 7)
    
src.f_stabler_buy 175,i_pet_EAGLE,c_eagle
ELSEIF (<argn1> == 8)
    
src.f_stabler_buy 200,i_pet_llama_pack,c_llama
ELSEIF (<argn1> == 9)
    
src.f_stabler_buy 230,i_pet_horse_pack,c_horse_pack
ENDIF

[FUNCTION 
f_stabler_buy]
local.gold=<dargv[0]>
local.pet=<argv[1]>
local.pet_name=<argv[2]>

IF (<
restest <dlocal.goldi_gold>)
    
serv.newitem=<local.pet>
    new.
bounce
    consume
=<dlocal.goldi_gold
ELSE
    
smsg @<def0.def_smsg_norm>,<serv.chardef.<local.pet_name>.nameis to expensive for you.
ENDIF


[FUNCTION 
f_sell_animal]
ref1=<argo.uid>
ref2=<args>

IF (<
ref1.isplayer>)
    
smsg @<def0.def_smsg_norm>,3 You can not sell players!
ELSEIF !(<
ref1.ischar>)
    
smsg @<def0.def_smsg_norm>,3 You can not sell items!
ELSEIF (<
ref1.uid> == <uid>)
    
smsg @<def0.def_smsg_norm>,3 You can not sell yourself!
ELSEIF !(<
ref1.ismypet>)
    
smsg @<def0.def_smsg_norm>,3 That is not a pet!
ELSEIF (<
ref1.flags>&statf_conjured)
    
smsg @<def0.def_smsg_norm>,3 You can not sell summoned pets!
ELSE
    
local.money=<eval <ref1.taming>/10>
    
newgold=<dlocal.money>
    
smsg @<def0.def_smsg_norm>,3 You sell your pet for <dlocal.moneygold.
    
ref1.remove
ENDIF
RETURN 
1

// Stable function
[function f_stable_npc]
ref1=<argo.uid// pet to store
ref2=<uid// spieler

IF (<ref1> == <ref2>)
    
ref1.smsg @<def0.def_smsg_norm>,3 You can not sell yourself!
    return 
1
ENDIF
IF (<
ref1.memoryfindtype.memory_ipet.link> == <ref2.uid>)
    
ref1.shrink
    FORITEMS 10
        
IF (<type> == t_figurine)
            IF <
more2> == <ref1>
                
ref77 = <uid>
            ENDIF
        ENDIF
    ENDFOR
    
ref77.tag0.control.slots=<local.slot>
    
ref77.link=<ref2.uid>
    
ref77.removefromview
    ref77
.tag0.master = <ref2.uid>
    
ref77.cont = <args>
    
ref2.sysmessage You store your pet.
ENDIF


[
EOF
(This post was last modified: 08-22-2014 03:23 PM by admin phoenix.)
08-20-2014 10:35 PM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes admin phoenix's post
Post Reply 


Messages In This Thread
Stabler System - admin phoenix - 08-20-2014 10:35 PM
RE: Stabler System - kn4tseb - 08-22-2014, 06:47 AM
RE: Stabler System - Extreme - 08-22-2014, 12:55 PM
RE: Stabler System - admin phoenix - 08-22-2014, 03:24 PM
RE: Stabler System - kn4tseb - 08-24-2014, 08:17 AM
RE: Stabler System - admin phoenix - 08-24-2014, 06:47 PM
RE: Stabler System - kn4tseb - 08-25-2014, 12:03 AM
RE: Stabler System - chrono - 01-18-2022, 07:06 PM
RE: Stabler System - Aris - 10-16-2022, 11:30 AM

Forum Jump:


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