Author Topic: Research developement  (Read 28270 times)

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
Re: Research developement
« Reply #30 on: September 20, 2011, 04:50:33 pm »
Don't worry I'll be sure to drag it out until everyone comes to my house with torches and pitchforks. :P

Offline bramcor

  • Captain
  • ***
  • Posts: 76
    • View Profile
Re: Research developement
« Reply #31 on: September 21, 2011, 12:54:09 am »
Don't worry I'll be sure to drag it out until everyone comes to my house with torches and pitchforks. :P

.. or maybe they bring champagne for the release party? ;)

Offline Yankes

  • Global Moderator
  • Commander
  • *****
  • Posts: 3350
    • View Profile
Re: Research developement
« Reply #32 on: September 21, 2011, 01:17:13 am »
... or maybe stun rods? :D I think SupSuper could have connection to aliens :>

Offline michal

  • Commander
  • *****
  • Posts: 629
    • View Profile
Re: Research developement
« Reply #33 on: September 25, 2011, 02:30:04 pm »
gchevallereau, what about integrating research with ufopaedia? It would be nice if ufopeadia could show researched things. For now ufopedia shows couple of example articles, research does not unlock new articles.

Offline SupSuper

  • Lazy Developer
  • Administrator
  • Commander
  • *****
  • Posts: 2162
    • View Profile
Re: Research developement
« Reply #34 on: September 25, 2011, 03:37:21 pm »
gchevallereau, what about integrating research with ufopaedia? It would be nice if ufopeadia could show researched things. For now ufopedia shows couple of example articles, research does not unlock new articles.
It is integrated, the problem is the new articles don't exist yet (and they'd also need the new items, facilities, etc. to tie into). I'm hoping to get around to this once the rulesets are in place so we can easily put all the info in instead of just the "starting stuff".

Offline Daiky

  • Battlescape Programmer
  • Administrator
  • Commander
  • *****
  • Posts: 904
    • View Profile
Re: Research developement
« Reply #35 on: January 24, 2012, 11:40:41 am »
I have a suggestion, is it hard to make the prerequisite items not just a flag, but a list of items? It would make it a lot more flexible to potential mods to the research tree.

So just looking at the research.dat:

Code: [Select]
- name: STR_PLASMA_RIFLE
  cost: 700
  needItem: true
  dependencys:
    []
  unlock:
    []

would become:

Code: [Select]
- name: STR_PLASMA_RIFLE
  cost: 700
  prereqItems:
    - STR_PLASMA_RIFLE
  prereqResearch:
    []
  unlock:
    []

Offline DiceMaster

  • Sergeant
  • **
  • Posts: 44
    • View Profile
Re: Research developement
« Reply #36 on: January 24, 2012, 01:00:27 pm »
Interesting. So we would be able to merge weapon+clip researches. It is annoying to research rifles and clips separately.

Offline gchevallereau

  • Sergeant
  • **
  • Posts: 41
    • View Profile
Re: Research developement
« Reply #37 on: January 27, 2012, 12:38:32 am »
It should be really simple. The needed modifications should be:
* Transform the bool flag to a list in RuleResearchProject
* Change the SavedGame::getAvailableResearchProjects function to check a list of items instead of just one.

If we do it, it might even be interresting to set a number of needed items, and maybe if they should be consumed. We can image that scientist need to disasemble items to understand it. So your example could become:
Code: [Select]
- name: STR_PLASMA_RIFLE
  cost: 700
  prereqItems:
    - STR_PLASMA_RIFLE:
      - needed: 3
      - destroyed: true
  prereqResearch:
    []
  unlock:
    []

Offline moriarty

  • Commander
  • *****
  • Posts: 1421
    • View Profile
    • Luke's OX mod site
Re: Research developement
« Reply #38 on: January 27, 2012, 06:57:32 pm »
that would actually be really cool. just remember to tell the player what's going to happen on the research screen :) something like:

New Research: <alien artifact name>
With the recovered <alien artifact name> we should now be capable of reverse-engineering it. The research will use <x> unit(s) of <alien artifact name><, which will be destroyed in the process>.



You will also have to decide whether or not the research will become visible before all requirements are met. Just imagine a player having a Plasma Rifle in his stores and wondering why he is unable to research it. I for example always sold all alien artifacts but one if I was fairly certain that I don't need them... so maybe another line should appear in that case:


The stores currently hold <y> <alien artifact name>(s). In order to start the research, we need <x> units.

Offline R

  • Sergeant
  • **
  • Posts: 21
    • View Profile
Re: Research developement
« Reply #39 on: January 28, 2012, 07:45:48 am »
IMO the number of needed items can be coded in, but should not be part of the stock OpenXcom.  It is a feature that's included for modders to use if they wish.