Aller au contenu

Photo

cdaulepp's Random Loot Generator (need help disabling names)


  • Veuillez vous connecter pour répondre
28 réponses à ce sujet

#1
sapientCrow

sapientCrow
  • Members
  • 64 messages
I have so far disabled the switch inside the switch script which is supposed to stop names from being generated.  I then commented out sections that even call the names in both loot names and random.  Still when magic loot drops it is being given one of those random names.  Does anyone know how to stop this? 
I like DnD rare gear names not mmo style ones.

#2
kevL

kevL
  • Members
  • 4 056 messages
after making changes in the #include files, you have to recompile the main() script: fw_random_loot.NSS

wouldn't hurt to recompile fw_container_on_open.NSS also.

#3
sapientCrow

sapientCrow
  • Members
  • 64 messages
I think I did that but to be clear on it.
The steps I just took are:
Open toolset and load module.
I opened first the switch file and made sure it was false.
I then opened fw_random, get_random and on_open (these refer to each file but are not the entire name)
I chose compile all open scripts and then took the compiled scripts pasted them and replaced into the random loot folder.
is this correct?
Before I may have not compiled it after the change perhaps.

edit:
I did all of the above and entered a cave in the Ironfist area and the first fight a piece of armor dropped and it was named moander's palm and had 3 different properties.
I even went into fw_random where you check what type of loot and left only the line for if it is a damage shield to give it a name.  No matter what I do the names still persist.

Modifié par sapientCrow, 23 octobre 2013 - 07:06 .


#4
kevL

kevL
  • Members
  • 4 056 messages
don't know what to say,

I'm using v.2, changed the switch

const int FW_ALLOW_RANDOM_NAMES_OF_LOOT = TRUE;

to FALSE, recompiled and magical items no longer get weird names.


Ps. If cd's RLG is in your override you don't have to load any modules to open those scripts in the TS. The toolset should find them in override right away


pps. i'm not sure about "compile all open scripts" or whatever, but me I'd diligently make the change to the include, save it, then specifically compile fw_random... ( ie. the TS may be mis-compiling fw_random before saving inc_switches.. )

#5
sapientCrow

sapientCrow
  • Members
  • 64 messages
ok i will try that. it is really bizarre and I been hacking away at this thing for a day. I don't know how it is even being called after I changed the exclusion if check to only damage shield. considering I put that particular loot drop to 0% drop in probability.
think I might give up and remove it completely if this time it doesn't work and just use your oc gem one with the difficulty mod. it is very confusing to say the least.
Do you know if the rolls happen on kill or when the module or area is loaded?

Oh btw thanks for the Difficulty Modifier.  I am curious if you can explain to me how I can make the drops lower in that overall and lessen the higher level gems from dropping as well?

Modifié par sapientCrow, 23 octobre 2013 - 10:10 .


#6
kevL

kevL
  • Members
  • 4 056 messages
my random loot script is a lot simpler than cd's, and as stated it's just for OC crafting components. Have a look at it, 'kl_pia_loot'

- to lower the % drops, reduce iMonstLevel near the top (change "12" to something lower, eg.)
- to lower the max drop, reduce the Effective Level somehow. (technically it should be done in the central algorithm but that's a b****). If iEffLevel is reduced too far it will cut the priciest drops altogether.

Recompile & set RANDOM_LOOT in difficulty.2da however you want ( see docs ).


If you don't want to give up on Cd's altogether, i suggest deleting your present version and starting from scratch. It could be that you actually have two copies of it, or at least two copies of 'fw_random_loot' kicking around --


ps. The Pia rolls happen when a creature is spawned. It might be on entering a module, an area, a trigger, a conversation, whenever. Requires that the critters have the default 'nw_c2_default9' script in their onSpawn event tho

I don't know how cd's RLG rolls happen (apart from an onSpawn via the Pia). I don't use it usually, and looking at it seems to indicate it should be set up when building a module. i just never felt the need to go through it and tweak it up... added it as an afterthought..

#7
sapientCrow

sapientCrow
  • Members
  • 64 messages
cool thanks for info on your script.
I think I am just stuck with random loot unless I am missing something.
I now removed the entire script folder of his from my override and set the pia to 1 which according to docs will only use yours. I am in the eyegouger area and just started it after making all those changes and dropping his random loot.
Still one of the orcs dropped an item with a random name. I do not get what is going on with his scripts at all. I have other scripts in my override and they all work right but his and now it seems its stuck somehow and I cant even get rid of it.
I dont know where else I could have duplicates of the folder or his script either.

I am not seeing the 12 you are referring to.  I only see a check with 18 by imonster level in loot script.  Also there are a number of efflevel.
Can yopu clarify a bit more on what needs to be done to reduce the overall drop rate and the drop rate of the higher level gems?

Modifié par sapientCrow, 24 octobre 2013 - 01:32 .


#8
kevL

kevL
  • Members
  • 4 056 messages
oh sry. I make changes to my own copy here and forgot..

this determines how often pia_loot pops something:

if (d100() > 12 + iMonstLevel)
{
  if (iDebug) SendMessageToPC(GetFirstPC(FALSE), "no Loot sry.");
  return;
}


It means, d100 has to be *less than* the hitDice of the critter ( + some arbitrary number ) to drop. Adjust the arbitrary #

And this, more or less, is the EffectiveLevel code:

int iEffLevel = ((iMonstLevel * 2) + iCharLevel) / 2;
int iLevelMod = d8(3);
iEffLevel = iEffLevel + 17 + iLevelMod;


EffectiveLevel is a combination of the monster's level, the PC's level, and another arbitrary #. Obviously the higher the EF, the pricier the drops become... i suggest removing the "17" above, or reduce the iLevelMod randomizer.



re. Eyegouger : it's vaguely possible that Cd's scripts got saved into your playthrough; but without knowing how you've got things setup it seems more likely that copies of them are still in Override somewhere, or the OC Campaign folder ?


[ EDIT ] I just did a compare on my script and noticed i've refined things some, so here's a link to the one I use: pastebin Pia_loot

don't mind all those comments.. feel free to copy & paste it over your current pia_loot script and compile. I think you'll like it better, although it's not *that* different, ( i cleaned it up some, hope it didn't screw up )

Modifié par kevL, 24 octobre 2013 - 02:52 .


#9
sapientCrow

sapientCrow
  • Members
  • 64 messages
thanks for the script. I appreciate it. It actually has a lot of changes in it compared to the download.
Going to check it out. I honestly only got random loot generator because I thought it would give me more crafting items to go with tcc which I sue as well.

If rlg is saved into my playthrough is there any way to purge it out or am i stuck with it?
Because I no longer even have any of the scripts for rlg in my override and there is nothing I can find in the campaign oc folder.
I did have the demo module in modules folder but that is it and now that is deleted too

Modifié par sapientCrow, 24 octobre 2013 - 03:25 .


#10
kevL

kevL
  • Members
  • 4 056 messages
try creating a script in override:

'fw_random_loot'

void main()
{}


Compile it so there's an .Ncs file, then hopefully whenever the RLG tries to run it'll do this instead.

but .. it's possible you're still getting drops from spawns that happened a while ago

Modifié par kevL, 24 octobre 2013 - 03:38 .


#11
sapientCrow

sapientCrow
  • Members
  • 64 messages
ok I will try this. Will I need to turn on the switch in your script by setting it to 3 or just leave it set to 1 like it is now?
Is it possible to force it off through the debug mode?

#12
kevL

kevL
  • Members
  • 4 056 messages
* if * Cd's is still getting called, only a hak file has priority over the override. Assuming there's no hak, and assuming Cd's has to call 'fw_random_loot' to run, then the empty script above should cut things right down.

no need to set RANDOM_LOOT to 3, try it at 1 for awhile

#13
andysks

andysks
  • Members
  • 1 645 messages
May I ask how did you disable, if you did, the very high drops on low level? I tried this system, liked it's simplicity but I didn't touch anything to the scripts to suit my needs due to my inexperience. So I ended up changing it because the monsters were dropping essences on level 1.

#14
kevL

kevL
  • Members
  • 4 056 messages
myself, I haven't used it much at all -- never for long in real play.

like Sapient, the names just got to me; and the stats were just too arbitrary, like those random language generators are..

So with a big grain of salt, I noticed that the code will check for a variable "CR" on an object (chest or critter i guess) -- but when i set it to "30" (pretty darn high) i was only getting low level drops. So i don't know what's going on. cd's RLG strikes me as a grand foundation that needs a dedicated second-party person to give it a good rubdown and puffup.....

/shrug.

#15
andysks

andysks
  • Members
  • 1 645 messages
I know what you mean. In the beginning it seemed nice, but after a while the names got me too. It is CR based, but also price based. So the monsters were dropping some orbs or items that cost 0 gold but in fact are too powerful to have at low levels. I think it also had a problem with essences, counting them as low loot.
It's a good base, but needs some modification to make it work better and to your needs I think.

#16
sapientCrow

sapientCrow
  • Members
  • 64 messages
your changes to the drops of oc gems/essences is much better. thank you for that.
if in the future I do want to further adjust overall drop am I just focusing on the 12? and for high level drops the 1.9f?

I am still getting named drops randomly and I hope it is just because some are stuck in the stream and will eventually clear out. those scripts although very thoroughly commented and explained do not work at all right for rlg. I even have random named bullets and and ammo that have 0 properties on them.

#17
kevL

kevL
  • Members
  • 4 056 messages
no, i wouldn't suggest playing around with "availability" 1.9f

I wrote that note trying to understand it, and now think it's redundant in the formula. This is what you'd be playing around with if you adjusted Availability:

f(x)=((cos(d))^(0.975/x))+(655x/(d^1.91))


not fun. I looked at the curve again in a 2d graph program and believe the two variables you need to achieve what you might want are iMonstLevel (or its dependencies) and iEffectiveLevel (or its dependencies). The first for frequency of drops (higher is more), the second for value of drops (higher is more).

[edit] MonstLevel is obviously linear: it's simply the probability that a monster drops an item (or two...)

EffLevel is on the other hand a weight or bias. The formula, itself, should take into account a wide range of values and automatically swing the probability toward higher and lower value drops. I'm not getting very pricy drops myself (a lot of malachite tbh), but you could change EffLevel by up to ~20 +/- or more, without making expensive drops entirely impossible. (in fact I don't think the formula allows cutting them out entirely -- just extremely, extremely rare, like 1 in 10,000)

Modifié par kevL, 25 octobre 2013 - 02:40 .


#18
sapientCrow

sapientCrow
  • Members
  • 64 messages
cool I will mess around with it. Seems good so far except I did get a red dragon hide from a whimpy orc.

Question about the difficulty script:
If I set the pc_adj to 5 does this mean that for each 5 levels it will give +1 bonus up to the mex that is set in the other settings or does pc_adj negate the other settings altogether?

#19
kevL

kevL
  • Members
  • 4 056 messages

sapientCrow wrote...

Question about the difficulty script:
If I set the pc_adj to 5 does this mean that for each 5 levels it will give +1 bonus

yes.

up to the mex that is set in the other settings

no

or does pc_adj negate the other settings altogether?

no

I don't like 'caps'


... except I did get a red dragon hide from a whimpy orc.

Lol, theoretically it's possible. What level was your PC? want to play with the numbers...

#20
sapientCrow

sapientCrow
  • Members
  • 64 messages
ok so setting pc_adj doesnt negate the other settings.
I have been fighting mostly cr5 lately and they have gotten a max bonus of +1 or +2 on ac
If my character level was 20 they could only get a max of 4. So when would any creature ever get the +9 str? Wouldn't I need to be level 30 in order for a +6 to happen or is there other calculations in the script itself that has scaling? Thanks for the help on all this.

My character level was 9 at the time. I did get a wyvern hide as well. So far only the hides seem high at times. Ever since I changed the code to what you posted I rarely get high level gems.

I still unfortunately for whatever reason am getting named armor and weapons. I can load a game 10 times and enter an area and still get the exact same named item too so unlike your script that can be seen being applied on spawn rlg somehow got applied to areas I had not even been to yet. It makes no sense to me at all. What a pain those scripts are.

#21
kevL

kevL
  • Members
  • 4 056 messages
it sounds like you got the gist of it,

Most of the numbers, like bonus_str etc, in difficulty.2da are what the monster gets if it has CR=20. The bonuses scale down if the critter has less than CR=20, or more otherwise. Hence a PC won't get clobbered by a 1cr orc (not because of Pia, anyway)

pc_adj is something I added later, once i had an internal balance among all the other values. So i think of it as sort of a "unity gain" or master volume -- except it only goes up ( unless, if the balancing process is started with pc_adj set higher than 0, then you could turn it down (...up!) and the IG effect would reflect that on most all other parameters )


re. dragon hide. I punched in some numbers and agree it's a bit high. 1 in 20 ( if you're going to get a hide, rather than something else ). The wyvern hide looks like 1 in 8 ( again, if you're going to get a hide )

You can see the hide table near the very bottom of the script. Drop these values 400/1600/3200/5600, all of them by 200 i suggest as a quickfix


[ edit ] pc_adj and bonus_str will add together:

if pc_adj is 5, that's +1 (round down) for a 9th level PC
if bonus_str is 9, that's +2 (round down) on cr5 critters

strength gets +3 (unless Primary Mapping is on, in which case the bonus goes to the critter's highest primary ability, which may or may not be strength)


Thanks for the help on all this.

no worries mate.

Modifié par kevL, 25 octobre 2013 - 04:20 .


#22
kevL

kevL
  • Members
  • 4 056 messages
OH WAIT. pc_adj runs off the hitDice of the *pc*

uh yah, it's been a while. corrected above.

Modifié par kevL, 25 octobre 2013 - 04:23 .


#23
sapientCrow

sapientCrow
  • Members
  • 64 messages
ok great so if I understand it correctly regardless of pc_adj enemies will get bonuses and pc_adj just adds another layer of scaling?

off topic question:
do you know if reeron is active in here somewhere? I am trying to work with his spell improvements and his summon ones have no sources.

#24
kevL

kevL
  • Members
  • 4 056 messages
that's a good way to put it, yes.

Don't know where Reeron is, but summoning should be controlled by 'nw_s0_summon.ncs'

#25
sapientCrow

sapientCrow
  • Members
  • 64 messages
yah that's the file but I cant open it since it is a compiled script. I really just want to eliminate the multiple summons as my party spams them until the whole place is full of summons.

and rlg is finally gone. do not know why it took so long. it is nice to be back to a more normal loot drop and with yours its perfect since I use tcc and that is why I even started a search for loot scripts.