DragonPrime - LoGD Resource Community
Welcome Guest
  • Good morning, Guest.
    Please log in, or register.
  • September 23, 2017, 11:07:27 AM
Home Forums News Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Login
 
 
Resource Pages
Search

Pages: [1] 2 3 ... 10
 1 
 on: Today at 03:12:34 AM 
Started by TGTarheel - Last post by TGTarheel
Thanks, everyone for the help, then.

I just needed to have a way to control beta-testing access to new modules, one that did not grant Grotto Access, so that some players could also beta-test.

This is something I like to do after I have first assured myself that there is nothing that causes a conflict or parsing error or call stack somewhere.  Then, the next thing is to test functionality to be sure things function as intended.

 2 
 on: Today at 03:09:04 AM 
Started by austenmc - Last post by TGTarheel
@Nder' what kind of storytelling do you like ? darker sword and sorcery Style or rather heroic Lotr style ? Just wondering --

My own mind seems to go best towards young person faces tragedy (usually death of a parent) - is thrown into adverse situation against their will (usually a dark magic/evil situation) - suffers for years, manages to escape, begins to build new life....that is the general theme I ted to write best.  Usually the protagonist is persecuted and finds a way to rise above it (usually by kicking butt) - I like female buttkickers.

If you remember Dragon Warrior/Dragon Quest from the 1980's - 1990's, think in terms of Alena.

 3 
 on: Yesterday at 04:03:23 PM 
Started by TGTarheel - Last post by RaynDarren
Code:
dohook:
$allowed_acctids = array( acct id's go here separated by commas);

case "village or whatever"
if(in_array($session['user']['acctid'],$allowed_acctids))
{
addnav
}
in this case, I assume the account id's a separated by commas?

They do yes, apologies, thought I put that in there!

 4 
 on: Yesterday at 07:56:26 AM 
Started by TGTarheel - Last post by DarknessFalls
Not a problem! Here to help!

 5 
 on: Yesterday at 04:37:21 AM 
Started by TGTarheel - Last post by TGTarheel
I've actually got a couple of modules that make it so that you can grant access to certain players, by granting access to them via UE. I've added the necessary snippets of code for it. The first one goes at the top of the module, at the end of your $info section of the module.

Code:
"prefs"=>array(
"allowed"=>"Is this player allowed into the area?,bool|0",

Then, under the cases, where you've got your village case:

Code:
case "village":
$allowed = get_module_pref("allowed");
if ($allowed == 1 && $session['user']['location'] == "InsertVillageNameHere"){
addnav("Ale Alley");
addnav("Name for Nav","runmodule.php?module=InsertnameofModulehere&loc=enter");
}


That should help. I hope.

This would make it so that you can pick and choose which players have access to the specific module you are testing.

Yes, I like it.  I see where this works.
I could then set the boolean to default 1 and re-install the module when beta-testing is done, thus keeping it in and making the ability to re-beta the thin if necessary later.

Thanks!

 6 
 on: Yesterday at 04:32:54 AM 
Started by TGTarheel - Last post by TGTarheel
Code:
dohook:
$allowed_acctids = array( acct id's go here );

case "village or whatever"
if(in_array($session['user']['acctid'],$allowed_acctids))
{
addnav
}
in this case, I assume the account id's a separated by commas?

 7 
 on: Yesterday at 02:44:30 AM 
Started by TGTarheel - Last post by Stephen.Kise
OK...I could try.

What I am actually doing...

Is setting up so that in, let's say, in the hook for village (where my modue would show up)

While it is in the testing stage, I only want it to access certain values and add the nav ONLY for those values.  Everyone else would not have the nav, thus would not stumble into what is not fully tested.

The reason why this first came up in the multi-poke thread, was because that one has setting in it where you can allow ONLY certain account ID's to use certain pokes.

I wanted to know how I would set that up within a module, as a temporary thing, so that, once fully tested, it could then be taken out and thus everyone would get the nav, see?

Now, the way I had done this in the past would be something like this:

Code:
if ($session['user']['id'] <= 10) {
addnav whatever
} else {}

That way only users with an account ID 10 or lower would see the nav.

So, without setting superuser tags on someone...how would I make a player a betatester on something...so that they could still see the nav where other players could not?

THAT is where I am trying to get.  I do not want to give someone Grotto Access just in order to allow them to beta test.  I have some longer-term players that I normally would consider for use for beta-testing, but their account ID's are all over the place and I wanted to order those players so that everything was in the same rage, so that my above coding would work.

I am being told this is not a good plan.  So what I am looking for then....is code that would allow access only to certain players...and without giving them Grotto Access.

Oh, alright. If you are going to give certain users, including non-superuser accounts, access I would use DarknessFall's method or use the 'beta' tag in user editor (Misc Info > Willing to participate in beta). The beta feature will make it so that you don't have a lot of modules where you assign specific access (less preferences saved in the database). Just keep in mind that the beta flag is for beta testing, meaning they have access to all beta features you provide, not just one module. If you are going to flag people as beta testers, then the code would be:

Code:
if ($session['user']['beta']) {
// Code for beta users to access.
}

 8 
 on: September 20, 2017, 02:23:02 PM 
Started by TGTarheel - Last post by RaynDarren
dohook:
   $allowed_acctids = array( acct id's go here separated by commas  );

case "village or whatever"
            if(in_array($session['user']['acctid'],$allowed_acctids))
{
addnav
}

 9 
 on: September 20, 2017, 02:10:29 PM 
Started by TGTarheel - Last post by DarknessFalls
I've actually got a couple of modules that make it so that you can grant access to certain players, by granting access to them via UE. I've added the necessary snippets of code for it. The first one goes at the top of the module, at the end of your $info section of the module.

Code:
"prefs"=>array(
"allowed"=>"Is this player allowed into the area?,bool|0",

Then, under the cases, where you've got your village case:

Code:
case "village":
$allowed = get_module_pref("allowed");
if ($allowed == 1 && $session['user']['location'] == "InsertVillageNameHere"){
addnav("Ale Alley");
addnav("Name for Nav","runmodule.php?module=InsertnameofModulehere&loc=enter");
}


That should help. I hope.

This would make it so that you can pick and choose which players have access to the specific module you are testing.

 10 
 on: September 20, 2017, 01:57:52 PM 
Started by TGTarheel - Last post by TGTarheel
OK...I could try.

What I am actually doing...

Is setting up so that in, let's say, in the hook for village (where my modue would show up)

While it is in the testing stage, I only want it to access certain values and add the nav ONLY for those values.  Everyone else would not have the nav, thus would not stumble into what is not fully tested.

The reason why this first came up in the multi-poke thread, was because that one has setting in it where you can allow ONLY certain account ID's to use certain pokes.

I wanted to know how I would set that up within a module, as a temporary thing, so that, once fully tested, it could then be taken out and thus everyone would get the nav, see?

Now, the way I had done this in the past would be something like this:

Code:
if ($session['user']['id'] <= 10) {
addnav whatever
} else {}

That way only users with an account ID 10 or lower would see the nav.

So, without setting superuser tags on someone...how would I make a player a betatester on something...so that they could still see the nav where other players could not?

THAT is where I am trying to get.  I do not want to give someone Grotto Access just in order to allow them to beta test.  I have some longer-term players that I normally would consider for use for beta-testing, but their account ID's are all over the place and I wanted to order those players so that everything was in the same rage, so that my above coding would work.

I am being told this is not a good plan.  So what I am looking for then....is code that would allow access only to certain players...and without giving them Grotto Access.

Pages: [1] 2 3 ... 10

*
DragonPrime Notices
Please take the time to read the FAQ and browse the DragonPedia

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Recent Topics
DragonPrime LoGD
Who's Online
26 Guests, 0 Users
Home Forums News Downloads Login Register Advanced Search