Info needed any input very much appreciated

Hello everyone, 


Firstly i just want to say that this is NOT a plugin request. It is simply a shout out to people who may have the know how to get certain variables pertaining to the game. in other words is a variable request, sort of.


eg.


Player position x and or Player position y.     



My AIM:  To make a core script to simplify scripting.


Method:   I actually just want to get like a bunch of useful variables that get updated if certain (conditions are met) and make them global in a ordered and easily-accessible manner.


Reason:  So I can access them in any of the plugins i create in the future and have them be both faster and lighter while having a much faster production time.


This may not be as easy as it was made to seem.


Note. Any useful info is appreciated links etc. 


Now onward! 🙂   ( is it just me or does this kinda sound a bit corny?)


-------------------------------------(Needed variables etc)-----------------------------------
​


1. Player position x and player position y on scene map.
​


2. Player and Player followers' info. (Name, face ect.)  
​


3. Image of the current map as shown when window takes a snapshot of the scene to be used as a window background. 
​


4. Number of items a player is currently holding. 
​


5. Icon for an item in player inventory list. (doesn't have to be category specific)
​


6. Name for an item in player inventory list. (doesn't have to be category specific)
​


7. Any icon[ ].
​


8. Current background music name.
​


9. Background music lname list. 
​


10.  current map name (*new)
​


11. ----
​






===================================(will be updated)==============================
​


                                                                                                                                                       !updated!
​




The variable list will be updated periodically.


Also if you feel there is something that is missing from the list or that you would like to add please let me know by commenting. 


 
Most of these are like... one line script calls, so I'll just fill in the ones I know offhand.


1. $gamePlayer.x and $gamePlayer.y


3. SceneManager.snapForBackground()


4. $gameParty.allItems().length


Not sure if 5 is referring to the bitmap or the id, but the id is just a property of an item. so like...


5. $gameParty.allItems()[some ID here].iconIndex


Same thing for 6...


6. $gameParty.allItems()[some ID here].name


I have no idea what 7 is asking.


8. AudioManager._currentBgm.name


Not sure what 9 is looking for, a list of possible BGM names?


Notes:


$gamePlayer.x and $gamePlayer.y will return the Tile positions, not screen positions. Screen positions can be gotten via $gamePlayer.screenX() and $gamePlayer.screenY().


$gameParty.allItems() will include all items, weapons, and armors in the inventory, but not currently equipped items. To just get weapons or armors separately, use $gameParty.weapons(), or $gameParty.armors(). $gameParty.items() will return just items, such as potions and such.
I guess 2 would be 


$gameParty.members().forEach(function(actor){
console.log(actor);
})




Look at that in the dev console; it has all the actor properties listed there.
Most of these are like... one line script calls, so I'll just fill in the ones I know offhand.


1. $gamePlayer.x and $gamePlayer.y


3. SceneManager.snapForBackground()


4. $gameParty.allItems().length


Not sure if 5 is referring to the bitmap or the id, but the id is just a property of an item. so like...


5. $gameParty.allItems()[some ID here].iconIndex


Same thing for 6...


6. $gameParty.allItems()[some ID here].name


I have no idea what 7 is asking.


8. AudioManager._currentBgm.name


Not sure what 9 is looking for, a list of possible BGM names?


Notes:


$gamePlayer.x and $gamePlayer.y will return the Tile positions, not screen positions. Screen positions can be gotten via $gamePlayer.screenX() and $gamePlayer.screenY().


$gameParty.allItems() will include all items, weapons, and armors in the inventory, but not currently equipped items. To just get weapons or armors separately, use $gameParty.weapons(), or $gameParty.armors(). $gameParty.items() will return just items, such as potions and such.



Wow thanks zalerinian this helps a lot 🙂  .


As for 7  it's umm... what i mean is.. ok do you know how all the icons are just one big .png file? i was a little confuzzled about that and was wondering how exactly do i call or print just one icon in a window.


and yes number 9 is asking for  the list of BGM names. 
I guess 2 would be 



$gameParty.members().forEach(function(actor){
console.log(actor);
})




Look at that in the dev console; it has all the actor properties listed there.



Also Thankx for the assist kino. 
ougitou1, please avoid double posting, as it is against the forum rules. You can review our forum rules here. Thank you.


If you want to reply to more than one person, then simply use the convention


@username + reply (and please don't quote whole posts, it makes reading threads more difficult)


@otherusername +another reply


Thanks
For number 7; every icon has an index; that's the index used to draw Icons in a window. You can check this index by opening up an event in the editor, clicking show text command, and then right  clicking to see the icon set viewer.
Awesome thanks kino.

Original thread: https://forums.rpgmakerweb.com/threads/info-needed-any-input-very-much-appreciated.66165/