Jump to content
OverLord

Progress bar

Recommended Posts

In rAthena when you start the progress bar. If you try to move on if this is a "break" in the script and you can move, run, attack and etc.
 
In Hercules when starting a progress bar, you stay locked until it ends, you can not move, attack and nothing of the sort. And it hinders creativity lock eg for creation of mining systems in PvP map or with strong mobs. Limits the creation of a "Healer" timer (with the progress bar showing time) to prevent abuse and other simple and useful ideas.
 
So is the suggestion to change the operation of the progress bar so that it does not lock the character, but that if he tries to do some action it be canceled, as well as the (break) rest of the script that was running.
Edited by OverLord

Share this post


Link to post
Share on other sites

yeah make it movable,

is it possible remove the timer and send specific values also?

Edited by mleo1

Share this post


Link to post
Share on other sites
        mes "Drink from Fountain?";	if(select("Yes!I'm dying of thirst...:it must be dirty!")!=1) close;	close2;	while( ( HP < MaxHP || SP < MaxSP ) && .Mode & 1){		progressbar "0x11CC99",.HealDelay;		percentheal rand(.healrate),rand(.healrate);	}	if(.Mode & 2){		for(set .@x,0; .@x < getarraysize(.BuffInfo); set .@x,.@x + 3){			sc_start .BuffInfo[.@x], .BuffInfo[.@x + 1] * 60000, .BuffInfo[.@x + 2];		}	}

Check this code, its a basic healer (using non-abuse system), if possible "move" and "break" the script,if possible It would be easier to use this script and others. Imagine the RK with TG lock and having to log out?

This is a silly example, but it has other cases which can be best applied as mining on a PvP map/strong mobs map.
Edited by OverLord

Share this post


Link to post
Share on other sites

I think you can edit this yourself if you want:

void clif_parse_WalkToXY(int fd, struct map_session_data *sd){...	if (sd->sc.opt1 && ( sd->sc.opt1 == OPT1_STONEWAIT || sd->sc.opt1 == OPT1_BURNING ))		; //You CAN walk on this OPT1 value.	/* else if( sd->progressbar.npc_id )		clif->progressbar_abort(sd); */	else if (pc_cant_act(sd))		return;...}

Just uncomment the line. Albeit if it could be made into a configurable option it would be best imo.

Edited by Garr

Share this post


Link to post
Share on other sites

In official, you're not able to move when the ProgressBar is still active. I'm also the one who report this.
 

Topic: http://herc.ws/board/tracker/issue-7380-showprocgressbar-improper-behaviour/?gopid=18578#entry18578

 

https://github.com/HerculesWS/Hercules/commit/962d203f95fd8b81d504f60aa28bb17cc268395d

Share this post


Link to post
Share on other sites

I think you can edit this yourself if you want:

void clif_parse_WalkToXY(int fd, struct map_session_data *sd){...	if (sd->sc.opt1 && ( sd->sc.opt1 == OPT1_STONEWAIT || sd->sc.opt1 == OPT1_BURNING ))		; //You CAN walk on this OPT1 value.	/* else if( sd->progressbar.npc_id )		clif->progressbar_abort(sd); */	else if (pc_cant_act(sd))		return;...}

Just uncomment the line. Albeit if it could be made into a configurable option it would be best imo.

Thx :) Help a lot!

 

 

 

 

In official, you're not able to move when the ProgressBar is still active. I'm also the one who report this.

 

Topic: http://herc.ws/board/tracker/issue-7380-showprocgressbar-improper-behaviour/?gopid=18578#entry18578

 

https://github.com/HerculesWS/Hercules/commit/962d203f95fd8b81d504f60aa28bb17cc268395d

I really thinking is a good ideia make a configurable option.

Share this post


Link to post
Share on other sites

You really shouldn't ever be able to move / break during a progress bar... that opens up a world of player reports asking why a script doesn't work or have orphaned quest variables that needed to be set after the progress finished. Could seriously have the potential to break a lot of things in my opinion.

Share this post


Link to post
Share on other sites

I'd have to go with Emistry's idea honestly, it's far better than having it toggle'd in a conf file. Especially since there are multiple instances where you could use the progress bar with both walkable and non-walkable forms.

 

Example that I used in a few scripts:

1. In a custom crafting system, players were unable to move while the progress bar went through (much like other MMORPGs).

2. In a custom battle ground, I add pyres that needed to be activated 5 times, each time took 5seconds. Meaning if they moved, or were attacked, the bar cancelled, thus making them have to start over. Really adds depth and variety to scripts with just this simple option.

3. Made an item that simulated using a long cast time skill, however they needed to remain still or else it would cancel (intended feature), since the spell casted a global stun effect bypassing stats. No need to punish the players by making them unable to move to re-position themselves for strategic use.

 

So again, I'd go with Emistry's idea, and add an extra parameter to make it root players, or allow them to walk.

Share this post


Link to post
Share on other sites

I think I can do this if I able to finish up that pcblock script command, so this progressbar will use the flags from BLOCK_ constants

http://herc.ws/board/topic/11020-add-pcblockattack-pcblockskill-pcblockchat-pcimmune-script-commands/

 

currently the BLOCK_ flags are

enum block_action_flag {	PCBLOCK_MOVE     = 0x01,	PCBLOCK_ATTACK   = 0x02,	PCBLOCK_SKILL    = 0x04,	PCBLOCK_USEITEM  = 0x08,	PCBLOCK_CHAT     = 0x10,	PCBLOCK_IMMUNE   = 0x20,	PCBLOCK_SITSTAND = 0x40,	PCBLOCK_COMMAND  = 0x80,};
@@kyeme

the official behavior for progressbar is

BLOCK_MOVE|BLOCK_ATTACK|BLOCK_SKILL|BLOCK_USEITEM

anything else ?

it doesn't block sit/stand, chat and command, right ?

 

so the concept will be something like

pcblock "", 3;
is equal to
pcblock "", 3, BLOCK_MOVE|BLOCK_ATTACK|BLOCK_SKILL|BLOCK_USEITEM;
match the official behavior

 

but if added an optional flag, it will be

pcblock "", 3, false;
all actions can be use

Share this post


Link to post
Share on other sites

upon further test, I found out it also has

1. block players from drop items

2. block players from pick up items

3. block players from trade with other players

4. block players from clicking on npc

5. block players from changing cart -> https://github.com/HerculesWS/Hercules/blob/master/src/map/clif.c#L10771

which are not defined in the enum I made ...

I try ask Haru's opinion on this ...

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.