~ Forums of Enroth ~
Would you like to react to this message? Create an account in a few clicks or log in to continue.

~ Forums of Enroth ~

The Enroth diehard fan community
 
HomeHome  Latest imagesLatest images  SearchSearch  RegisterRegister  Log inLog in  
Latest topics
» Songs of Conquest
[Script System][Suggestions] New Callbacks Icon_minitimeby Blake01 2024-04-07, 15:14

» ...to XP run...
[Script System][Suggestions] New Callbacks Icon_minitimeby CATMAN 2024-03-30, 03:16

» WARNING - The dreaded moment is here: Heroes 6 servers shutting down
[Script System][Suggestions] New Callbacks Icon_minitimeby Blake01 2024-03-29, 23:04

» Songs of Silence (HoMM like game)
[Script System][Suggestions] New Callbacks Icon_minitimeby Blake01 2024-03-27, 16:52

» Heroes Orchestra's 5th Birthday concerts with Paul Romero
[Script System][Suggestions] New Callbacks Icon_minitimeby rrravyn 2024-03-23, 22:45

» fheroes2 General Announcements
[Script System][Suggestions] New Callbacks Icon_minitimeby sirDranik 2024-03-17, 23:35

» Photo Gallery
[Script System][Suggestions] New Callbacks Icon_minitimeby Sir Albe 2024-03-07, 06:57

Poll
Global announcements should be:
Everlasting, 1 for each project.
[Script System][Suggestions] New Callbacks Redbar110%[Script System][Suggestions] New Callbacks Redbar12
 0% [ 0 ]
Temporary, when there is something new to announce.
[Script System][Suggestions] New Callbacks Redbar11100%[Script System][Suggestions] New Callbacks Redbar12
 100% [ 6 ]
Holalala... No idea where the Ultimate artifact is.
[Script System][Suggestions] New Callbacks Redbar110%[Script System][Suggestions] New Callbacks Redbar12
 0% [ 0 ]
Total Votes : 6
Most Viewed Topics
H3SW: General Graphics discussion
Ragoon's Graphics For HoMM3SW
Introduce yourself
H3SW General Discussion
H3SW Map List: Work in progress
H3SW: Dwelling Development
Forum Admins Feed
The Floody Land
Enrothian Fan Art
Heroes III: The Succession Wars v0.8.1 Beta

 

 [Script System][Suggestions] New Callbacks

Go down 
AuthorMessage
Unknown_Hero
Mage
Mage
Unknown_Hero


Messages : 778
Quality Points : 78
Registration Date : 2015-09-06

[Script System][Suggestions] New Callbacks Empty
PostSubject: [Script System][Suggestions] New Callbacks   [Script System][Suggestions] New Callbacks Icon_minitime2017-03-18, 02:38

OnHeroLevelUp(hero) +

It is called when a hero level up.

OnHeroHire(hero) +

It is called when the player clicks on the "OKAY" button in the Recruit Hero window.

OnHeroDismiss(hero) +

It is called when the player clicks on the "DISMISS" button in the Hero Screen.

OnHeroLosing(hero) +

It is called when the player loses a hero in combat.

OnHeroMeetingScreenOpen(h1, h2) +

It is called after the Meeting screen is opened.

OnHeroRetreat(hero) +

It is called when the player clicks on the "Retreat" button in the Hero's Options window during combat.

OnHeroSurrender(hero) +

It is called when the player clicks on the "Surrender" button in the Hero's Options window during combat.

*

OnCreatureInfoOpen(creature) +

It is called after the Creature Info window is opened.

OnCreatureUpgrade(creature) +

It is called when the player clicks on the "UPGRADE" button in the Creature Info window.

OnCreatureDismiss(creature) +

It is called when the player clicks on the "DISMISS" button in the Creature Info window.

OnCreatureJoin(creature) +

It is called when an army of neutral creatures want to join the hero on the adventure map.

*

OnTownCastleScreenOpen(name) +

It is called after the Castle Options screen is opened.

OnTownBuildingOpen(name, building) +

It is called when the player clicks on a building sprite to "enter" the building.

OnTownBuildingScreenOpen(name, building) +

It is called after the building screen is opened.

OnTownBuildingSlot(name, building) +

It is called when the player clicks on a building slot in the Castle Options screen.

OnTownLosing(name) +

It is called when the player loses a town.

OnTownCapture(name) +

It is called when the player captures a town.

*

OnBattleNewTurn(side) +
side: the side which will control the hero.

It is called at the start of a new turn during combat.

OnBattleSpellCasting(hero, spell, cost) +
hero: the hero who casts the spell.
spell: the id of the spell.
cost: the number of spell points used to cast the spell.

It is called when a hero casts a spell during combat.

OnMapSpellCasting(hero, spell, cost) +
hero: the hero who casts the spell.
spell: the id of the spell.
cost: the number of spell points used to cast the spell.

It is called when a hero casts a spell on the adventure map.

*

+: "WaitEndOfEvent" can be used with all these callbacks.

Reminder: "WaitEndOfEvent" waits for the end of an event (after the last message box of the event is closed) to continue the instructions.

***** Updated on March 25, 2017 *****

OnMouseRightClick(type, x, y)
type: the ID of the location (see section "Locations"). Can also be used on an empty square.
x: X coordinate on the world map.
y: Y coordinate on the world map.

It is called when a user right-clicks on any square on the adventure map.
For example, can be used in coordination with Get/SetLocationText(type, x, y), Get/SetCoordinateText(x, y), GetNearestPlayerTown(x, y, player), GetNearestPlayerFreeTown(x, y, player) (see here), etc.

***** Updated on March 29, 2017 *****

OnHeroDigging(hero, x, y) +

It is called when a hero digs on the adventure map.
Back to top Go down
 
[Script System][Suggestions] New Callbacks
Back to top 
Page 1 of 1
 Similar topics
-
» [Script System][Suggestions] GetUserDifficultyChoice() and more
» [Script System][Suggestions] BattleGetCurrentTurn() and more
» [Script System][Suggestions] CancelShareVision(p1, p2)
» [Script System][Suggestions] GetGlobalCreatureUpgradeCost(value) and more
» [Script System][Suggestions] GetCreaturesInGeneratorQuantity(x, y) and more

Permissions in this forum:You cannot reply to topics in this forum
~ Forums of Enroth ~ :: Modding Guild :: Heroes of Might and Magic II: Project Ironfist :: Modding and Mapmaking-
Jump to: