mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-11 23:24:59 +00:00
update 6.7
This commit is contained in:
@@ -32,7 +32,7 @@ def doPostBattleAction(actionType)
|
||||
return if !trainer
|
||||
case actionType
|
||||
when :BATTLE
|
||||
trainer = doNPCTrainerRematch(trainer)
|
||||
trainer,player_won = doNPCTrainerRematch(trainer)
|
||||
when :TRADE
|
||||
trainer = doNPCTrainerTrade(trainer)
|
||||
when :PARTNER
|
||||
@@ -46,7 +46,7 @@ def setTrainerFriendship(trainer)
|
||||
params = ChooseNumberParams.new
|
||||
params.setRange(0,100)
|
||||
params.setDefaultValue($game_map.map_id)
|
||||
number = pbMessageChooseNumber("Frienship (0-100)?",params)
|
||||
number = pbMessageChooseNumber(_INTL("Frienship (0-100)?"),params)
|
||||
trainer.friendship = number
|
||||
trainer.increase_friendship(0)
|
||||
return trainer
|
||||
@@ -57,15 +57,15 @@ end
|
||||
#
|
||||
#def customTrainerBattle(trainerName, trainerType, party_array, default_level=50, endSpeech="", sprite_override=nil,custom_appearance=nil)
|
||||
def postBattleActionsMenu()
|
||||
rematchCommand = "Rematch"
|
||||
tradeCommand = "Trade Offer"
|
||||
partnerCommand = "Partner up"
|
||||
cancelCommand = "See ya!"
|
||||
rematchCommand = _INTL("Rematch")
|
||||
tradeCommand = _INTL("Trade Offer")
|
||||
partnerCommand = _INTL("Partner up")
|
||||
cancelCommand = _INTL("See ya!")
|
||||
|
||||
updateTeamDebugCommand = "(Debug) Simulate random event"
|
||||
resetTrainerDebugCommand = "(Debug) Reset trainer"
|
||||
setFriendshipDebugCommand = "(Debug) Set Friendship"
|
||||
printTrainerTeamDebugCommand = "(Debug) Print team"
|
||||
updateTeamDebugCommand = _INTL("(Debug) Simulate random event")
|
||||
resetTrainerDebugCommand = _INTL("(Debug) Reset trainer")
|
||||
setFriendshipDebugCommand = _INTL("(Debug) Set Friendship")
|
||||
printTrainerTeamDebugCommand = _INTL("(Debug) Print team")
|
||||
|
||||
|
||||
event = pbMapInterpreter.get_character(0)
|
||||
@@ -116,3 +116,22 @@ def postBattleActionsMenu()
|
||||
end
|
||||
end
|
||||
|
||||
#leave event_type empty for random
|
||||
def forceRandomRematchEventOnTrainer(event_type=nil)
|
||||
event = pbMapInterpreter.get_character(0)
|
||||
map_id = $game_map.map_id if map_id.nil?
|
||||
trainer = getRebattledTrainer(event.id,map_id)
|
||||
while !trainer.has_pending_action
|
||||
trainer = applyTrainerRandomEvents(trainer,event_type)
|
||||
end
|
||||
updateRebattledTrainer(event.id,map_id,trainer)
|
||||
end
|
||||
|
||||
def forceTrainerFriendshipOnTrainer(friendship=0)
|
||||
event = pbMapInterpreter.get_character(0)
|
||||
map_id = $game_map.map_id if map_id.nil?
|
||||
trainer = getRebattledTrainer(event.id,map_id)
|
||||
trainer.friendship = friendship
|
||||
trainer.increase_friendship(0)
|
||||
updateRebattledTrainer(event.id,map_id,trainer)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user