Custom Equip Conditions v1.01 by AdiktuzMiko (get free items after loaded a game)

Hello !


Script :





Quick line : I get extra items after loaded a game.


Well, I suddenly realize that I had 2x "Armor -> 046:Wooden buckler" in my inventory at the begining of my game that is impossible to get so early.


Especialy when it's inside a chest.


This is how the problem comes out:


Nothing happend as long the game is not loaded. I mean, you can save and continue to play as normal


without to get extra armors. But if you quit and load the game .... BANG !


I am using notetag on many armors and weapons:


 <start_custom_req>
   actor.level > 2
 <end_custom_req>


But I only getting the same item after loaded a game.


Of course, I started an all fresh new project with only this script inside !


In a new project, I discovered it was not all the items in the data base. I dont know if I was "lucky" to find the only one, cause I dident tried all the armor list.


- In my personal project, I get 2x "Armor -> 046:Wooden buckler"


- In a new one, using notetag only on the " 046:Wooden buckler" makes me to get it only once.


I tried to put the same notetag on "Armor -> 047:Iron buckler" or "Armor -> 045😀ragon shield/targe" but nothing strange happend...


If someone can help me, because my only way to avoid it, is to command " -2 Wooden buckler " after loading and memorize with variable if the player got the wooden bucker in the chest to avoid to delet the legit one ... the messsssss.


Thanks in advance.
It's weird, my script shouldn't actually have anything to do with adding/removing items... Unless you're trying to force equip maybe that item and the actor can't use it and somehow triggers 2 times or something. 
I suppose, if your actors are equipped with Wooden Buckler in the database (their starting equipment), but they can't actually use them (because the database only checks for the built-in conditions, not the ones from Adik's script), those will get unequipped and put in the inventory, at least on a new game. 


But that should not happen if you load a game.


Actually, I just tested it, and it doesn't happen for me. I can save/load a game just fine.
can you upload the project where this happens? I also can't reproduce your problem... I never got two items when I load a game with my script on it.
Hello, thanks to answered.


I think Sixth is right.


But what surprising me is that the actor has no equipment on him at the begining.


Does the script affect all the data base regardless if the actor is in the team ?


What is strange, is that if I start a new project, only actor 001 Eric losing the wooden buckler. So why in my personal


project I have 2 of them ? ...


I setted all the basic actors with "None" equipements, and I dont get my problem anymore.


Just hope is not a coïncidence ...


By the way, very helpfull script AdiktuzMiko and happy to found it ! (°_-)
The script only runs when you equip an item so unless the game is trying to equip something the script shouldn't be interfering, so if you are sure that only Eric equips it (but couldn't due to it being tagged as for level 2) then it should only be removing that one item.
And why the game should try to equip something only when a game is loaded ?


- My game starts with a cut scene playing with only 1 actor with nothing equiped. "actor 11"


- After the scene a save is asking.


- If I load it, I've got the 2x Wooden buckler that I dont know where they came from.


In the actor11 notetag I have a memo that is for a Yanfly equip script.


starting gear: 6, 46, 67, 70, 71, 73         (It's not activated, right ? To activate I have to use <...>, right ?)


The "46" is one wooden buckler, but if the notetag is not active, no reason to care.


My actor11 is still the same. I just removed equip of useless actors and I dont get items anymore.
IDK, and I cannot reproduce your problem... It could be that one of the other scripts in that project is running something that conflicts with that script. 


So it would really help if you could upload that project which has the problem.
Thank you Adiktuzmiko !


At the moment it's ok, I have to finish my demo before jully the 1st.


As long I dont get other weired stuffs that's ok for me, or I'll do deeper check.


I'll let you know.


Thank you

Original thread: https://forums.rpgmakerweb.com/threads/custom-equip-conditions-v1-01-by-adiktuzmiko-get-free-items-after-loaded-a-game.63598/