UFO: Alien Invasion Issue Tracker
UFO: Alien Invasion
Go to the previous open issue
Go to the previous issue (open or closed)
star_faded.png
Please log in to bookmark issues
icon_project.png UFO: Alien Invasion / Closed Bug report #1899 Wrong callback for homonymous confunc
Go to the next issue (open or closed)
Go to the next open issue
There are no more issues in that direction.
This issue has been closed with status "Closed" and resolution "Not determined".
Issue basics
  • Type of issue
    Bug report
  • Category
    User interface
  • Targetted for
    Not determined
  • Status
    Closed
  • Priority
    4. Useful
User pain
  • Type of bug
    Not triaged
  • Likelihood
    Not triaged
  • Effect
    Not triaged
Affected by this issue (0)
There are no items
People involved
Times and dates
  • Posted at
  • Last updated
  • Estimated time
    Not estimated
Issue details
  • Resolution
    Not determined
  • Reproducability
    Not determined
  • Severity
    Not determined
  • Complexity
    Not determined
  • Platform
    Not determined
  • Architecture
    Not determined
Attachments (0)
There is nothing attached to this issue
Duplicate issues (0)
This issue does not have any duplicates
Description
[http://sourceforge.net/p/ufoai/bugs/1899 Item 1899] imported from sourceforge.net tracker on 2013-01-28 19:12:13

On battle, original HUD, firemodes don't open up on clicking the button so we can't fire (manually).

I've checked: the click happens, even CL_DisplayFiremodeEntry runs. Maybe problem with Cbuf_AddText("confuncs") ?

-geever
===== Comments Ported from Sourceforge =====

====== bayo-fr (2008-11-26 09:02:45) ======

Problem come from by revision 20383

Precondition of this revision is confunc name is unique; but it's not (for example "hud" and "althud") (i dont think its very nice, but its done like that). So, with this revision, your problem come from we call the wrong node from "althud" instead of from "hud".

I fix that by an override of the node adress of menus when we push it on the renderer. We push "althud" or "hud".

But we must do more, to no more have problems like that:
* How to prevent confunc homonymous (it can create problems)
* How and when allowing confunc homonymous (the code use it, we cant do without)

Maybe we can do something like that:
* common case: Dont allowing any homonymous confunc. Registration at the parsing time, with a warning/error (not a debug one).
* extends of menu: we can allow it here. When we script something like that, we know we will have confunc with same name, so we will not call a confunc if we have not already push the menu. We can allow, only here the patch of the revision 20401.

It will maybe work safe. But not yet done :)
====== bayo-fr (2008-11-27 08:44:14) ======

I patch something yesterday, but i dont read very well new warning it introduce; it dont fix all the case.

The last case is a callback function fired when a cvar change (for exemple looking change of "cl_name"). If we look at each use, we can see it is every time used for edition of text. That why, maybe, we can :
* Create a new node "listener" to allow random number of callback using the same command (we call all functions instead of the first one on the top of the stack); registring it when we push a menu; ununregistring it when we pop it.
* But we also can create the "textentry" node (with a change action) and see if we can use it for all this cases.

Both are easy to implement. The second will take more time, but maybe i will begin with it.
Steps to reproduce this issue
Nothing entered.
Todos (0 / 0)
Issue created
footer_logo.png The Bug Genie 4.3.1 | Support | Feedback spinning_16.gif