Author Topic: New to modding & questions  (Read 287 times)

Offline Unit

  • Sergeant
  • **
  • Posts: 16
    • View Profile
New to modding & questions
« on: November 04, 2024, 03:38:50 pm »
Greetings fellow astronauts

I'm slowly reading up on how to mod the openxcom
It seems like a PITA but have always loved the game
Having seen what xpiratez is capable of keen to start me own mod

They're telling me we can't remove a unit, like the one of the rosigma designers is currently struggling with..
Can possibly do a workaround using neutral character assigned through a variable check but It's not ideal

I'm just wondering if these kinda limitations are gonna be addressed in time, are they going to expand the functionality of the engine?

Also, noticed the units get drawn from individual pieces, very nice..
Any chance a script can be made here to randomly assemble the pieces so we can have full blown mutants in game

Also, is it possible to introduce a variable, let's say it's called
playerSecurityClearance
Starts off set to zero
Player can't access usual base development, base building, buying of units, pretty much everything, until the Player starts gaining security clearance (advancing in rank otherwise)
I also need the game to generate some starter missions & replace dead troops etc while in this phase
I'm planning to incorporate the fantastic brutal AI engine modified to hard-set units to AI control while the player has 0 security clearance, so you're basically starting out as a grunt amongst other grunts
(Chatting with brutal AI author in discord, have access to help there)

That's about it for now
I got a lot of plans and no idea how to achieve 'em
Thanks for stopping by
May you always have 100% accuracy

Offline Yankes

  • Commander
  • *****
  • Posts: 3328
    • View Profile
Re: New to modding & questions
« Reply #1 on: November 04, 2024, 04:38:18 pm »
Quote
Also, noticed the units get drawn from individual pieces, very nice..
Any chance a script can be made here to randomly assemble the pieces so we can have full blown mutants in game
Yes, if you spend enough time you can duplicate all body parts in unit graphic, then you can switch between them by script.
If you look for example of power armor and fly armor was hardcoded in original game. OXCE allow same behavior for
any armor and any body part.

Offline Unit

  • Sergeant
  • **
  • Posts: 16
    • View Profile
Re: New to modding & questions
« Reply #2 on: November 04, 2024, 05:04:51 pm »
That's good news
Thanks!

Still querying:
- restricted base actions (and)
- early game simple AI base self maintenance
- removal of units
« Last Edit: November 07, 2024, 08:36:28 am by Unit »

Online CrazedHarpooner

  • Captain
  • ***
  • Posts: 97
    • View Profile
Re: New to modding & questions
« Reply #3 on: November 04, 2024, 06:31:52 pm »
While not a variable, you could get a very close aproximation of this via dummy research topics. Soldiers, scientists, engineers, gear and facilities can be made dependant on a topic before you can hire, build, purchase or manufacture any of them. However, I don't believe there's a way to prevent a player from sacking, selling or dismantling. Unlocking the dummy topics can be done either via completing a particular mission or events popping up.

A sample of this would be
Code: [Select]
research:
  - name: STR_DUMMY # This one must never be unlocked
    dependencies:
      - STR_DUMMY
  - name: STR_SC1 # First security clearence obtained
    dependencies:
      - STR_DUMMY

hireEngineersUnlockResearch: STR_SC1
hireScientistsUnlockResearch: STR_SC1

soldiers:
  - type: STR_SOLDIER
    # ... other fields in the definition
    requires:
      - STR_SC1

facilities:
  - type: STR_LIVING_QUARTERS
    # ... other fields in the definition
    requires:
      - STR_SC1

# Event that unlocks 1st security clearence. This can be used in monthly event triggers or from alien deployments (completing a mission).
events:
  - name: STR_SC1_EVENT
    # ... other fields in the definition
    researchList:
      - STR_SC1


Replacement of soldiers and gear seems a bit trickier as it's possible to base events on a soldierType present (or not) but not on soldier count. The same goes for gear (or items I should say) and it only looks what's in the base stores, not in the craft. You may have to base the triggers of these on monthly scoring and possibly have to define them per difficulty.

Offline Unit

  • Sergeant
  • **
  • Posts: 16
    • View Profile
Re: New to modding & questions
« Reply #4 on: November 04, 2024, 10:06:46 pm »
I like the way your mind works
That's really helpful for me at this stage
Thanks so much for typing that up
I use a tiny little tablet device to access intermajigger, typing code would be a nightmare
Cheers, I will let you know how it goes..
..in a few weeks 🤭

Offline Unit

  • Sergeant
  • **
  • Posts: 16
    • View Profile
Re: New to modding & questions
« Reply #5 on: November 07, 2024, 08:34:25 am »
How to make a flickering or pulsing light radius?
Doesn't have to animate every frame just adjust every turn..