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






Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
combat bonus
Author Message
cele_35
Apprentice
*

Posts: 7
Likes Given: 1
Likes Received: 0 in 0 posts
Joined: May 2019
Reputation: 0



Post: #1
combat bonus
hi guys im write new combat bonus but i can not pls help me ..
example :hit to enemy %20 chance 3 second only walk
is this possible ??

ON=@hit
if (rand(7)==1) && !(<src.findid.i_cramp_kontrol>)
src.newitem i_cramp_kontrol
src.act.timer 3
src.act.equip
src.sayua 025,6,0,enu Cramp !
src.damage 20 0001 <uid>
src.flags=<src.flags>&~statf_mt_walk /// ??? ///////////
return 1
05-27-2019 03:36 PM
Find all posts by this user Like Post Quote this message in a reply
Seokotov
Apprentice
*

Posts: 18
Likes Given: 2
Likes Received: 1 in 1 posts
Joined: Dec 2018
Reputation: 0

WorldAtWar

Post: #2
RE: combat bonus
try to change speedmode instead flags

World At War Devil
05-27-2019 07:08 PM
Visit this user's website Find all posts by this user Like Post Quote this message in a reply
cele_35
Apprentice
*

Posts: 7
Likes Given: 1
Likes Received: 0 in 0 posts
Joined: May 2019
Reputation: 0



Post: #3
RE: combat bonus
Old client bro not work speedmode
05-27-2019 10:32 PM
Find all posts by this user Like Post Quote this message in a reply
Coruja
Sphere Developer
*****

Posts: 987
Likes Given: 5
Likes Received: 226 in 187 posts
Joined: Jul 2012
Reputation: 7

Dimension Shard

Post: #4
RE: combat bonus
SPEEDMODE is a bit dangerous because it's client-side, and you should never trust nothing based on client-side, so you can use an alternative method

There's statf_freeze flag which will paralyze the char, but since this flag is also used for more actions (eg: paralyze spell, etc) it's not a good idea use it to avoid conflicts. There's also statf_stone flag which is not a good idea because it will totally freeze the client making it unable to speak, pickup/drop items, etc

So the best solution is use the hardcoded TAG.NoMoveTill, where you set an SERV.TIME value and the client will be unable to walk until SERV.TIME reach this value set

Code:
ON=@Hit
IF (20 > <R100>) && (<SRC.TAG0.NoMoveTill> < <SERV.TIME>)
  ARGN1=20    // damage value
  ARGN2=dam_fixed    // damage type
  SRC.SAYUA 025,6,0,enu Cramp !
  SRC.TAG.NoMoveTill=<eval <SERV.TIME>+30>    // 3.0 seconds
ENDIF
05-28-2019 10:01 AM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes Coruja's post
Post Reply 


Forum Jump:


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