02-21-2015, 04:30 AM
The syntax is correct. It uses the same actor_index value as other main menu functions, such as the Scene_Item, Scene_Skill and others. And insofar as the from_map value, this lets one generate a Skill Tree from an event. This would be like one is learning skill techniques from a trainer NPC who asks what skill types one may wish to learn.
One can gain the actor_index of a particular party member by oerforming a small scriptette that cycles through the party until the desired ID is found
This bit looks for whatever actor in your party is actor #3 in your database (Cyrus). If he's not there, it would return 'nil' otherwise, it would be the actor_index in your party.
One can gain the actor_index of a particular party member by oerforming a small scriptette that cycles through the party until the desired ID is found
Code:
actor_index = nil
actor_id = 3
for member in $game_party.actors
if member.id == actor_id
actor_index = member.index
end
end
p actor_index
![[Image: QrnbKlx.jpg]](https://i.imgur.com/QrnbKlx.jpg)
![[Image: sGz1ErF.png]](https://i.imgur.com/sGz1ErF.png)
![[Image: liM4ikn.png]](https://i.imgur.com/liM4ikn.png)
![[Image: fdzKgZA.png]](https://i.imgur.com/fdzKgZA.png)
![[Image: sj0H81z.png]](https://i.imgur.com/sj0H81z.png)
![[Image: QL7oRau.png]](https://i.imgur.com/QL7oRau.png)
![[Image: uSqjY09.png]](https://i.imgur.com/uSqjY09.png)
![[Image: GAA3qE9.png]](https://i.imgur.com/GAA3qE9.png)
![[Image: 2Hmnx1G.png]](https://i.imgur.com/2Hmnx1G.png)
![[Image: BwtNdKw.png%5B]](https://i.imgur.com/BwtNdKw.png%5B)