What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Profile Looping

vlad0327

New Member
Joined
Feb 4, 2011
Messages
291
Reaction score
10
Is there any means by which a loop could be coded in profile execution?
for example an if condition that will keep running over and over until IsQuestCompleted() value returns True?

Or a marker in the profile for an "If ... goto" condition? checkpoint is obviously not an option.

If not, I think it's pretty simple to code a custom qb for someone with enough C# knowledge.

This would make alot of quests much easier to do and remove a whole bunch of ugly code in the profile
 
Last edited:
Give me an example... are you trying to do:

use cb's to do quest
if quest isn't complete, then re-do cb's?

PHP:
if condition hasquest && !Isquestcompleted
CB
/if

if condition isquestcompleted
turnin
elseif condition !isquestcompleted
cb's
turnin
/elseif
/if

or something like that
 
But what would it looks like if you had to re-do something 12 times or more?
Really bad coding
PHP:
if condition hasquest && !Isquestcompleted
CB
/if

if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
if condition !isquestcompleted
cbs
/if 
turnin
 
Last edited:
That's exactly what i'm talking about..

to avoid long and ugly If -> Then -> Else.. and so on constructions, I need something that would look like this:

PHP:
Marker 1
cbs
...
Condition terms
If condition check returns False GoTo Marker 1
Else continue profile

But I think I just found a way to do this...
Will do some testing this week and then report back here =)
 
Panyama's Wintersaber Trainers quest series is a perfect example of where looping is needed.

Looping would also get us out of the situation where you need to kill-use-collect for the quest several times. Right now, Profile Writers are solving the problem by repeating the actions N times, and throwing in a couple of more 'just in case'. Its just plain silly what is having to be done due to lack of a simple looping construct.

The programmatically-inclined profile writers are writing their own custom behaviors to get around the problem. But a large number of profile writers in our community are not programmers.

PHP:
<while Condition="!IsQuestComplete(1234)">
    <!-- ...kill mob... -->
    <!-- ...use item... -->
    <!-- ...darn some socks... ->
</while>

cheers,
chinajade
 
Panyama's Wintersaber Trainers quest series is a perfect example of where looping is needed.

Looping would also get us out of the situation where you need to kill-use-collect for the quest several times. Right now, Profile Writers are solving the problem by repeating the actions N times, and throwing in a couple of more 'just in case'. Its just plain silly what is having to be done due to lack of a simple looping construct.

The programmatically-inclined profile writers are writing their own custom behaviors to get around the problem. But a large number of profile writers in our community are not programmers.

PHP:
<while Condition="!IsQuestComplete(1234)">
    <!-- ...kill mob... -->
    <!-- ...use item... -->
    <!-- ...darn some socks... ->
</while>

cheers,
chinajade

You've just explained clearly what I meant in the op. English is not my native language, so thanks for that =)

And if there are cb's for that, nobody shared it with the community so far, which is sad.

But as I stated above, I did find a way to do this, and it does in fact work as a charm. Just need some more thorough testing before I post it here just in case =)
 
Back
Top