Jump to content

Unhardcoded internal (type) lists


Iran

Recommended Posts

  • Replies 74
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

For buildings it sequentially builds hard-coded buildings pretty much. The game builds every vehicle (haven't updated the code to use new vehicles), for infantry it does some checks, not sure about aircrafts but easy to check.

 

 

Link to comment
Share on other sites

Alright, got a change to mess around with the new type lists. [unittypes], [infantrytypes], [AircraftTypes], [soundtypes], [Weapons], [Animtypes], [bullettypes], [Weapons] and [Warheads] are working fine for me in skrimish mode testing.

 

[VesselTypes] has a prob. The game isn't loading the turrent (SSAM.shp) so it tries to use the main unit .shp as the turrent. (Screen Shot below) I did not test the [buildingTypes] at all.

red_alert-2013-11-06-15_08_55.png.162f935b541eaafc73f0b48284a83a42.png

Link to comment
Share on other sites

Yup I know about the issue, it's because the turret drawing code checks the internal ID of the vessel it's trying to draw the turret for. I.e. checks that look "If vessel is TYPE_DESTROYER". I need to extend vessel types to support extra flags read from an INI to get proper turret drawing. Please keep adding suggestions, I've been busy with my job this week but hopefully starting tomorrow I have some more time again. I think I will keep focusing on extending UnitTypes (vehicles), as I still need to get my framework for extending UnitTypes working properly, to save time when extending VesselTypes and the other types.

 

Please take a look into adding new BuildingTypes, there isn't much interesting things you can do with newly added buildings but I'd like to know if it has any fundamental issues.

 

I'd like to thank you guys for helping with the testing so far, even if bugs aren't found it makes me more confident about the code. It saves me time to and it shows there's interest in these features.

Link to comment
Share on other sites

For buildings, I assume that a *make.shp is required with the same number of build frames as ATEK? Or will it just play the animation out properly regardless?

 

Edit:

http://www.speedyshare.com/kSmH3/ra95crash-Echo.dmp

 

Tried adding two buildings. First one played out fine, with one less image (16) in the *make.shp. Second one (15 images in *make.shp) shows up in the sidebar, but rolling the cursor over it results in a crash. Crashdmp says something about trying to read/write without appropriate access.

Link to comment
Share on other sites

Can you reproduce the crash and give me a new crash dump file? The info I get from the crash dump file you gave me seems odd. Something about crashing while trying to print something for an audio or voice sample status..

Link to comment
Share on other sites

Weirdly enough, it's not crashing now for some reason (I messed with recompiling the SHP files). I don't seem to be able to tag new structures as prerequisites for old structures though. Will post again if I encounter any weird shit and/or crashing.

 

Edit:

Alright they can't be used as prerequisites for anything. They do at least appear ingame though. As for the previous crashing, I think it might have had something to do with the new structure SHPs having a third state present (one for idle, one for damaged, and a third for being destroyed, like in TD).

Link to comment
Share on other sites

I copied the internal settings for the Allied Tech center to use as base when adding new buildings, I'm honestly not sure.

 

I expected  prerequisites to not work, even though I don't know how prerequisites are supposed to work in-game, I assume it uses a bitfield..

Link to comment
Share on other sites

Crash when Missile Silo is built when playing Echo's mod.

 

Worth adding that building MSLO unlocks a new structure, so it may be related to this.

 

Oddly it can be avoided by commenting out some other new structures (which don't have a real use right now anyway) in spawn.xdp/rules.ini, but here's another crashdump of the same thing:

http://www.speedyshare.com/Weda6/ra95crash-Echo-b.dmp

Link to comment
Share on other sites

Not able to duplacate Echo crash. I used a 2 frame build up and 3 frame main (one for idle, one for damaged, and a third for being destroyed, like in TD). As pointed out trying to use an new building for a prerequisite of a unit isn't working rignt. I used 1=COMM for my new building and set my new units to need Prerequisite=COMM but the game is think I put Prerequisite=fix on my new units as they won't be buildable tell I build a Service Depot.

 

Any new unit or building can use Prerequisite= of any stock building just fine.

Link to comment
Share on other sites

I used 1=COMM for my new building and set my new units to need Prerequisite=COMM but the game is think I put Prerequisite=fix on my new units as they won't be buildable tell I build a Service Depot.

 

Also encountered this.

 

As for the crashing, it's not at all related to structures having extra states so we can ignore that (just like the game ignores state 3). It always occurs when hovering over an offending structure icon in the sidebar (before the tip with the name/cost can appear), but I'm clueless as to what would cause this.

Link to comment
Share on other sites

I'm not getting it if I hold my mouse over the building but I'm using 1=COMM. I used 0= as placeholder/dummy that has all keys.

 

I'm attaching my rules.ini and EXPAND8.MIX. Give them a try. New unit is SSM Laucnher, Sniper, Beta Destryer. C&C95 ORCA and C&C95 Comm Center. SSM Laucnher use a new weapon, firing sound, projectile, animation and warhead. Beaware that the SSM has long reload time. The other units use stock weapons.

New_List_Type_Rules.zip

Link to comment
Share on other sites

The crashdump Stiggy gave me seems to crash in the same spot as the first one you gave me Echo. But the call stack is different and it crashes after trying to do some network related code now. Looks like the stack dump is corrupted.

 

The issue with prerequisites not working is probably the same thing as owning some civilian buildings in C&C95 giving you Ion Cannon, a 32-bit field is PROBABLY used (which can hold 32 buildings), and any newly added building probably overflows this bitfield (as new building IDs start at a number higher than 50 at least).

Link to comment
Share on other sites

It has something to do with the weapon you added, crashed because of that. I had the same crash when giving 'incorrect' weapons to units, as soon as the unit is spawned.

 

Might be a typo somewhere. Might also be an issue with my code. Could you double check? If you can't find it upload the mod for me please so I can take a look at it.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...