Revamp Expansion Mod (RVE) A Supreme Commander 2 Complete Overhaul / Total Conversion Mod

Forum Thread
by member
Projectiles...Again...(Ugh.) (Mods : Revamp Expansion Mod (RVE) : Forum : Mod Creation Help : Projectiles...Again...(Ugh.)) Locked
Thread Options
Apr 24 2013, 7:54pm Anchor

I hate to do this, both for my sake and yours, but....oh well..

I just tried my 3rd real attempt at adding a new projectile, and though I have made progress, I haven't made enough. My projectile seems to be appearing now, but the effects don't. (What I mean is, you can see the yellow dot that represents the projectile when you zoom out, but when you zoom in, the projectile has no effects.) To be specific, I'll put everthing I've got (well, not EVERTHING) here. This is the projectile (called IOhCannon01) blueprint. Script:

IOhCannon01 = Class(import('/lua/sim/Projectile.lua').Projectile) {
TypeClass = IOhCannon01

Then the effect template (in z_lua_dlc1.scd):

UnitPortEffectTemplates = {
Weapons = {
IOhCannonProjectileTrail = {
IOhCannonHit = {
IOhCannon_Launch_01 = {

EffectTemplates = table.merged(EffectTemplates, RevampEffectTemplates, UnitPortEffectTemplates)

The actual bp files in /effects/emitters/[the rest] I haven't touched. I have just copied and pasted all of the particles in FA to /textures/particles in my own .scd, so particle paths should not be a problem.

If I had a lot of money to bet, I would bet it all on a typo...

Edited by: ALBINOsnowball

Apr 26 2013, 5:35am Anchor

Instead of

Someone wrote:EffectTemplates = table.merged(EffectTemplates, RevampEffectTemplates, UnitPortEffectTemplates)

Just try

Someone wrote:EffectTemplates = table.merged(EffectTemplates, UnitPortEffectTemplates )

You dont need to merge with revamp as it merges with the default EffectTemplates file as well, Let me know how that goes.

Edited by: OverRated

Apr 26 2013, 2:39pm Anchor

And...It crashed! Back to square one....

This goes to show how much I know about lua, but does teh space between "UnitPortEffectTemplates" and ")" really need to be there? That's the only problem I can think of

EDIT: The muzzle flash and impacts are working (YES) but the projectile is still not showing up. I sort of assumed that the projectile emitters were the "polytrails", but...are they?

And to further the fun, how do you change the size of the muzzle flash? At least, is there a way in the code to do it?

EDIT 2: Okay, I pretty much have projectiles showing up and working. My only question left on this subject is how to make the muzzle flash effects smaller/larger.


Image and video hosting by TinyPic

Apr 26 2013, 11:07pm Anchor

Seeing your using Revamp you can add this line below to the units weapon table Revamp also support ImpactEffectScale + ProjEffectScale, Just a heads up though 1.2 works a little diffrent so you will need to change this when moving your units over to 1.2 .

Someone wrote:MuzzleFlashEffectScale = 1,

Edited by: OverRated

Apr 27 2013, 12:03am Anchor

Ah, thank you. Now, may I encourage you to take a look at my other unanswered thread about the tech toggle? (You may want to consider going to an insane asylum after all my questions :) )

As for 1.2, as soon as that comes out, I will pretty much stop porting units and will only try to make bug fixes. Why would I port old, badly textured units when 1.2's will be a [insert large number here] times better?


Image and video hosting by TinyPic

Apr 27 2013, 9:14am Anchor

HAHA i dont know maybe to add some think more :)

Reply to Thread
click to sign in and post

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.