Jump to content
  • 0

progressbar and pcblockmove combined?


Question

Posted

I'd like to make a request as the topic title states, if possible?

Instead of progressbar canceling if the player moves or clicks to move, during the progressbar's duration the player shouldn't be able to move.

I've tried using these two commands together, but this just leads to the progressbar stopping when you click, regardless if you can move or not; ultimately ending up with no progressbar and unable to move status since the script ended prematurely. :/

Thank you for your time~

3 answers to this question

Recommended Posts

Posted

Not sure how to add that as I dont speak c. :/

But if I understand right, I have this:

BUILDIN_FUNC(progressbar)
{
#if PACKETVER >= 20080318
struct map_session_data * sd = script_rid2sd(st);
const char * color;
unsigned int second;

if( !st || !sd )
 return 0;

st->state = STOP;

color = script_getstr(st,2);
second = script_getnum(st,3);

sd->progressbar.npc_id = st->oid;
sd->progressbar.timeout = gettick() + second*1000;

clif_progressbar(sd, strtol(color, (char **)NULL, 0), second);
#endif
return 0;
}

And then I make it like this?

BUILDIN_FUNC(progressbar)
{
#if PACKETVER >= 20080318
struct map_session_data * sd = script_rid2sd(st);
const char * color;
unsigned int second;

if( !st || !sd )
 return 0;

st->state = STOP;

color = script_getstr(st,2);
second = script_getnum(st,3);

sd->state.blockedmove = 1
sd->progressbar.npc_id = st->oid;
sd->progressbar.timeout = gettick() + second*1000;
sd->state.blockedmove = 0

clif_progressbar(sd, strtol(color, (char **)NULL, 0), second);
#endif
return 0;
}

I tried this but it still allowed me to click away and move, canceling the progressbar. :<

Posted

try add this ??

at the progressbar script there...

/src/map/script.c

sd->state.blockedmove = 1;

and to remove the BlockMove

sd->state.blockedmove = 0;

It doesn't help because problem in ехе file.

Join the conversation

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

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...