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
easier way to type / layer shield?
Author Message
x77x
Master
**

Posts: 488
Likes Given: 0
Likes Received: 15 in 15 posts
Joined: Mar 2012
Reputation: -4



Post: #1
easier way to type / layer shield?
im looking for an easier way to find if its a shield...
in 51a amor and shields are both type 10, so i used baseid, but look how long this is... i need to add every shield in the game
IF ITS A SHIELD ONLY +9
IF ITS ARMS,GAUNTLETS,LEGS,CHEST,GORGET,HELM +25


Code:
IF (<SRC.TARG.BASEID>=01b72) || (<SRC.TARG.BASEID>=01b73) || (<SRC.TARG.BASEID>=01b74) || (<SRC.TARG.BASEID>=01b75) || (<SRC.TARG.BASEID>=04724) || (<SRC.TARG.BASEID>=01b77) || (<SRC.TARG.BASEID>=01b78) || (<SRC.TARG.BASEID>=01b79) || (<SRC.TARG.BASEID>=01b7a) || (<SRC.TARG.BASEID>=01b7b) || (<SRC.TARG.BASEID>=01bc3) || (<SRC.TARG.BASEID>=01bc4) || (<SRC.TARG.BASEID>=01bc5) || (<SRC.TARG.BASEID>=06006) || (<SRC.TARG.BASEID>=06007) || (<SRC.TARG.BASEID>=06346) || (<SRC.TARG.BASEID>=06356) || (<SRC.TARG.BASEID>=06336) || (<SRC.TARG.BASEID>=06326) || (<SRC.TARG.BASEID>=06386) || (<SRC.TARG.BASEID>=06316) || (<SRC.TARG.BASEID>=06366) || (<SRC.TARG.BASEID>=06376) || (<SRC.TARG.BASEID>=0478e) || (<SRC.TARG.BASEID>=0478f) || (<SRC.TARG.BASEID>=04790) || (<SRC.TARG.BASEID>=06137) || (<SRC.TARG.BASEID>=07467) || (<SRC.TARG.BASEID>=07437) || (<SRC.TARG.BASEID>=04723) || (<SRC.TARG.BASEID>=04724) || (<SRC.TARG.BASEID>=04725) || (<SRC.TARG.BASEID>=0470e) || (<SRC.TARG.BASEID>=0470f) || (<SRC.TARG.BASEID>=04710) || (<SRC.TARG.BASEID>=04815) || (<SRC.TARG.BASEID>=04816) || (<SRC.TARG.BASEID>=04817) || (<SRC.TARG.BASEID>=06167) || (<SRC.TARG.BASEID>=06147) || (<SRC.TARG.BASEID>=0457e) || (<SRC.TARG.BASEID>=0457f) || (<SRC.TARG.BASEID>=04580) || (<SRC.TARG.BASEID>=045ce) || (<SRC.TARG.BASEID>=045cf) || (<SRC.TARG.BASEID>=045d0) || (<SRC.TARG.BASEID>=06127) || (<SRC.TARG.BASEID>=06607) || (<SRC.TARG.BASEID>=0455e) || (<SRC.TARG.BASEID>=0455f) || (<SRC.TARG.BASEID>=04576) || (<SRC.TARG.BASEID>=06617) || (<SRC.TARG.BASEID>=04738) || (<SRC.TARG.BASEID>=04739) || (<SRC.TARG.BASEID>=0473a) || (<SRC.TARG.BASEID>=07447) || (<SRC.TARG.BASEID>=07457) || (<SRC.TARG.BASEID>=045a3) || (<SRC.TARG.BASEID>=045a4) || (<SRC.TARG.BASEID>=045a5) || (<SRC.TARG.BASEID>=04727) || (<SRC.TARG.BASEID>=04717) || (<SRC.TARG.BASEID>=04707) || (<SRC.TARG.BASEID>=0474e) || (<SRC.TARG.BASEID>=0474f) || (<SRC.TARG.BASEID>=04750) || (<SRC.TARG.BASEID>=06117) || (<SRC.TARG.BASEID>=045b8) || (<SRC.TARG.BASEID>=045b9) || (<SRC.TARG.BASEID>=045ba) || (<SRC.TARG.BASEID>=04763) || (<SRC.TARG.BASEID>=04764) || (<SRC.TARG.BASEID>=04765) || (<SRC.TARG.BASEID>=04586) || (<SRC.TARG.BASEID>=0456e) || (<SRC.TARG.BASEID>=0456f) || (<SRC.TARG.BASEID>=06157) || (<SRC.TARG.BASEID>=047a3) || (<SRC.TARG.BASEID>=047a4) || (<SRC.TARG.BASEID>=047a5) || (<SRC.TARG.BASEID>=04778) || (<SRC.TARG.BASEID>=04779) || (<SRC.TARG.BASEID>=0477a) || (<SRC.TARG.BASEID>=07306) || (<SRC.TARG.BASEID>=07301) || (<SRC.TARG.BASEID>=07305) || (<SRC.TARG.BASEID>=0600f) || (<SRC.TARG.BASEID>=07200) || (<SRC.TARG.BASEID>=07213) || (<SRC.TARG.BASEID>=07067) || (<SRC.TARG.BASEID>=0456f)//ALL BASE,ORE,HIDE,AGEIS,AZA,SPANK,RENZ,HOCKEYMASK,TAMEMASK,WIZHAT,ARMY - no boxingstuff,nadeball
  IF (<SRC.TARG.MOREY>>=9)
        SRC.SYSMESSAGE=This is the same or a more powerful shield!
        RETURN 1
  ELSE
    IF  (<SRC.TARG.ATTR>==04)
       SRC.TARG.ATTR=025
    ELSEIF (<SRC.TARG.ATTR>==0)
       SRC.TARG.ATTR=021
ENDIF
        SRC.TARG.MOREY=9
        SRC.CONSUME=1 06524
        SRC.SFX=32
        SRC.EFFECT=3,0375a,6,15,1
        SRC.SFX=0214
        SRC.SYSMESSAGE #0033,3, You have successfully upgraded your armor!
        RETURN 1
    ENDIF
ELSE
IF (<SRC.TARG.TYPE>==10)
  IF (<SRC.TARG.MOREY>>=25)
        SRC.SYSMESSAGE=This is the same or a more powerful piece of armor!
        RETURN 1
  ELSE
    IF  (<SRC.TARG.ATTR>==04)
       SRC.TARG.ATTR=025
    ELSEIF (<SRC.TARG.ATTR>==0)
       SRC.TARG.ATTR=021
ENDIF
        SRC.TARG.MOREY=25
        SRC.CONSUME=1 06524
        SRC.SFX=32
        SRC.EFFECT=3,0375a,6,15,1
        SRC.SFX=0214
        SRC.SYSMESSAGE #0033,3, You have successfully upgraded your armor!
        RETURN 1
    ENDIF
ELSE
    SRC.SYSMESSAGE=This is not a piece of armor!
    RETURN 1
ENDIF

crazy long... check for layer instead perhaps?

on a side note...
how do you do a range?

Code:
IF (<SRC.TARG.BASEID>={04905 04909 1}) || (<SRC.TARG.BASEID>={04910 04919 1}) || (<SRC.TARG.BASEID>={04920 04929 1}) || (<SRC.TARG.BASEID>={04930 04939 1})//DEF MAGITEMS
SRC.SYSMESSAGE=This armor is already magic and cannot be enhanced!
RETURN 1

Dragons of Time 2000-2020
http://dragonsoftime.com
(This post was last modified: 02-10-2014 01:01 AM by x77x.)
02-10-2014 12:45 AM
Find all posts by this user Like Post Quote this message in a reply
Anarch Cassius
Master
**

Posts: 273
Likes Given: 19
Likes Received: 10 in 9 posts
Joined: Mar 2012
Reputation: 2



Post: #2
RE: easier way to type / layer shield?
For the love of Pete check the layer! I was wondering if you couldn't access layer in 51a, if you can it's definitely the way to go.


Range:
{04930 04939}

You seem to have a 1 on it for a weight, not needed. Ranges and weight lists are different despite looking almost identical in Sphere syntax.

Current Projects: Necromancy SCP overhaul. Custom Faction AI/System. Imbuing.
(This post was last modified: 02-10-2014 06:46 AM by Anarch Cassius.)
02-10-2014 06:45 AM
Find all posts by this user Like Post Quote this message in a reply
XuN
Sphere Developer
*****

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



Post: #3
RE: easier way to type / layer shield?
You cannot check a range this way, {} is randomizing the values, however you are using <src.targ.baseid>={} <--- double == for comparing, not single one.
if ((<src.targ.baseid>>=04905) && (<src.targ.baseid><=04909)) will do it
02-10-2014 07:11 AM
Find all posts by this user Like Post Quote this message in a reply
x77x
Master
**

Posts: 488
Likes Given: 0
Likes Received: 15 in 15 posts
Joined: Mar 2012
Reputation: -4



Post: #4
RE: easier way to type / layer shield?
never knew that... thanks, makes it a lil shorter anyway =P

Dragons of Time 2000-2020
http://dragonsoftime.com
02-10-2014 10:17 AM
Find all posts by this user Like Post Quote this message in a reply
evening
Journeyman
*

Posts: 138
Likes Given: 0
Likes Received: 14 in 9 posts
Joined: Apr 2012
Reputation: 1

Finally Land

Post: #5
RE: easier way to type / layer shield?
02-10-2014 03:44 PM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Extreme
Grandmaster Poster
***

Posts: 1,141
Likes Given: 217
Likes Received: 90 in 77 posts
Joined: May 2012
Reputation: 20

SphereCommunity

Post: #6
RE: easier way to type / layer shield?
Why use this shit of .51 version?
Can't understand it...

STEPS BEFORE CREATE A THREAD
- Check the revisions log;
- Use the search button and use the keywords of your problem;
- Check the WIKI;
- Create a thread.
02-11-2014 08:07 AM
Find all posts by this user Like Post Quote this message in a reply
evening
Journeyman
*

Posts: 138
Likes Given: 0
Likes Received: 14 in 9 posts
Joined: Apr 2012
Reputation: 1

Finally Land

Post: #7
RE: easier way to type / layer shield?
Some game player like 51A fighting style
02-11-2014 04:08 PM
Visit this user's website 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: #8
RE: easier way to type / layer shield?
And are there not settings in the ini to emulate this behaviour in 56b/c?
I think there are...
Haven't tried them myself mind you.

[Image: 2nis46r.jpg]
02-11-2014 09:46 PM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
Extreme
Grandmaster Poster
***

Posts: 1,141
Likes Given: 217
Likes Received: 90 in 77 posts
Joined: May 2012
Reputation: 20

SphereCommunity

Post: #9
Re: RE: easier way to type / layer shield?
(02-11-2014 09:46 PM)Mordaunt Wrote:  And are there not settings in the ini to emulate this behaviour in 56b/c?
I think there are...
Haven't tried them myself mind you.

Of course you can... But they like the. 51 style because of older client with hacks.. Like change speed and injection... Hahaha

Sent from my GT-I9505 using Tapatalk

STEPS BEFORE CREATE A THREAD
- Check the revisions log;
- Use the search button and use the keywords of your problem;
- Check the WIKI;
- Create a thread.
02-12-2014 03:12 AM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Forum Jump:


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