|
首先想提问一下,我自己找了一些素材和参考mod,想自己做一个武器瞎玩,结果在开火的时候游戏直接闪退了,报空指针异常,日志如下:52047 [Thread-4] ERROR com.fs.starfarer.combat.CombatMain - java.lang.NullPointerException
java.lang.NullPointerException
at com.fs.starfarer.combat.entities.ship.A.void.?O0000(Unknown Source)
at com.fs.starfarer.combat.entities.ship.A.void.createBeam(Unknown Source)
at com.fs.starfarer.combat.entities.ship.trackers.class.o00000(Unknown Source)
at com.fs.starfarer.combat.entities.ship.trackers.O0OO.o00000(Unknown Source)
at com.fs.starfarer.combat.entities.ship.trackers.O0OO.o00000(Unknown Source)
at com.fs.starfarer.combat.entities.ship.trackers.class.o00000(Unknown Source)
at com.fs.starfarer.combat.entities.ship.A.void.advance(Unknown Source)
at com.fs.starfarer.combat.systems.oOoO.advanceLinked(Unknown Source)
at com.fs.starfarer.combat.systems.oOoO.advance(Unknown Source)
at com.fs.starfarer.combat.entities.Ship.fire(Unknown Source)
at com.fs.starfarer.combat.entities.Ship.advance(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advanceInner(Unknown Source)
at com.fs.starfarer.combat.CombatEngine.advance(Unknown Source)
at com.fs.starfarer.combat.CombatState.traverse(Unknown Source)
at com.fs.state.AppDriver.begin(Unknown Source)
at com.fs.starfarer.combat.CombatMain.main(Unknown Source)
at com.fs.starfarer.StarfarerLauncher$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
武器的类型是激光武器,wpn文件是用参考mod里的文件手动改的,感觉都是一些配置,没啥问题,还和速子长矛做了对比和修改。wpn文件内容如下:
{
"specClass":"beam",
"id":"hii_skaal_laser_system",
"type":"ENERGY",
"size":"LARGE",
"beamEffect":"com.fs.starfarer.api.impl.combat.TachyonLanceEffect",
"turretSprite":"graphics/weapons/hii_skaal_laser_system.png",
"turretGlowSprite":"graphics/weapons/hii_skaal_laser_system_glow.png",
"hardpointSprite":"graphics/weapons/hii_skaal_laser_system.png",
"hardpointGlowSprite":"graphics/weapons/hii_skaal_laser_system_glow.png",
"turretOffsets":[14, 0],
"turretAngleOffsets":[0],
"hardpointOffsets":[14, 0],
"hardpointAngleOffsets":[0],
"fringeColor":[200,100,0,255],
"coreColor":[255,200,150,255],
"glowColor":[255,150,100,255],
"darkCore":false,
"width":75.0,
"textureType":ROUGH,
"textureScrollSpeed":128.0,
"pixelsPerTexel":5.0,
"pierceSet":[PROJECTILE_FF,PROJECTILE_NO_FF,PROJECTILE_FIGHTER,MISSILE_FF,MISSILE_NO_FF],
"fireSoundOne":"hii_ion_beam_charge",
"fireSoundTwo":"hii_sustained_ion_beam",
}
weapon_data.csv也添加了,如下:
Skaal Laser System,hii_skaal_laser_system,3,,0,1500,4000,,250,10,1,0,1,0.1,,ENERGY,,8000,1.4,5,1.25,,,,,,10000,,,,,FIRE_WHEN_INEFFICIENT,"energy20, beam15, LR, rare_bp",,,,General,,,,,,,,,,74
目前遇到的问题就是以上这些
***************************************************************
其次,还有拿舰船编辑器用weapon mode添加图片都添加不上去了,不显示~
不知道是编辑器版本的问题还是啥的问题....
***************************************************************
最后就是希望各位大佬分享一下武器mod的制作经验,供对制作mod感兴趣的各位新手提供一个参考,感谢各位~
|
|