Skip to content

Commit

Permalink
✨ new spellcard and new kekkai ,sorry for so busy
Browse files Browse the repository at this point in the history
  • Loading branch information
H2Sxxa committed Sep 30, 2023
1 parent b998fc5 commit 5e4da9b
Show file tree
Hide file tree
Showing 8 changed files with 114 additions and 7 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ dependencies {
transitive = false
}
}
implementation 'maven.modrinth:kekkai:1.2.0'
implementation 'maven.modrinth:kekkai:1.2.1'
implementation fileTree(dir:project.implementation_folder.toString(),includes:['*jar'])
if (project.do_embed.toBoolean() && (project.gradle.startParameter.taskNames[0] == "build" || project.gradle.startParameter.taskNames[0] == "publish")){
embed fileTree(dir:project.embed_folder.toString(),includes:['*jar'])
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,13 @@
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.GoPSpellcardBase;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.compat.GoASpellcardBase;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.DreamSeal;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.EarthLight;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.IDRelease;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.MasterSpark;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.MilkyWay;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.PearlDarkCast;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.WaveAndParticle;
import io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy.WonderGodWind;
import net.katsstuff.teamnightclipse.danmakucore.entity.living.TouhouCharacter;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.Spellcard;
import net.minecraftforge.event.RegistryEvent;
Expand Down Expand Up @@ -46,6 +48,11 @@ public static void initSpellCard() {
public static final Spellcard WAVE_PARTICLE = new GoASpellcardBase<WaveAndParticle>("wave_particle",
WaveAndParticle.class, TouhouCharacter.YUKARI_YAKUMO).setendTime(400);

public static final Spellcard WONDER_GODWIND = new GoASpellcardBase<WonderGodWind>("wonder_godwind",
WonderGodWind.class, TouhouCharacter.SANAE_KOCHIYA).setendTime(200);
public static final Spellcard EARTH_LIGHT = new GoASpellcardBase<EarthLight>("earth_light",
EarthLight.class, TouhouCharacter.MARISA_KIRISAME).setendTime(200);

@SubscribeEvent
public static void onSpellCardRegister(RegistryEvent.Register<Spellcard> event) {
event.getRegistry().registerAll(SPELL_CARDS.toArray(new Spellcard[0]));
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
package io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy;

import io.github.teamgensouspark.grimoireofpatchouli.PatchouliModInfo;
import io.github.teamgensouspark.kekkai.color.AtomColors;
import io.github.teamgensouspark.kekkai.danmaku.DanmakuBuilder;
import io.github.teamgensouspark.kekkai.danmaku.KekkaiDanmakuCreationHelper;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.EntitySpellcard;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.Spellcard;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.SpellcardEntity;
import net.katsstuff.teamnightclipse.danmakucore.lib.data.LibShotData;
import net.katsstuff.teamnightclipse.mirror.data.Vector3;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.util.EnumFacing.Axis;
import scala.Option;

public class EarthLight extends SpellcardEntity {

public EarthLight(Spellcard spellcard, EntitySpellcard cardEntity, Option<EntityLivingBase> target) {
super(spellcard, cardEntity, target);
}

int rndSigned() {
return PatchouliModInfo.RND.nextInt(2) == 1 ? -1 : 1;
}

@Override
public void onSpellcardUpdate() {
if (time() % 2 == 0) {
KekkaiDanmakuCreationHelper.createCircleShot(
DanmakuBuilder.getBuilderWithEntity(user())
.setPos(new Vector3(user()).add(rndSigned() * PatchouliModInfo.RND.nextDouble() * 25, 0,
rndSigned() * PatchouliModInfo.RND.nextDouble() * 25))
.setShot(LibShotData.SHOT_LASER.setMainColor(AtomColors.ATOM_COLOR_CYAN))
.setDirection(Vector3.Up().rotate(PatchouliModInfo.RND.nextDouble() * 6, Axis.X))
.setMovementData(0)
.build(),
1,
1.0f, 1.0d);
}
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,15 @@ public WaveAndParticle(Spellcard spellcard, EntitySpellcard cardEntity, Option<E

@Override
public void onSpellcardUpdate() {
KekkaiDanmakuCreationHelper.createCircleShot(
DanmakuBuilder.getBuilderWithEntity(user())
.setShot(LibShotData.SHOT_RICE.setMainColor(AtomColors.ATOM_COLOR_PURPLE)).build(),
9, (float) (Math.PI / 180 *
time() * ((float) time() / 5)),
0d);
// love from gsko
if (time() % 2 == 0) {
KekkaiDanmakuCreationHelper.createCircleShot(
DanmakuBuilder.getBuilderWithEntity(user())
.setShot(LibShotData.SHOT_RICE.setMainColor(AtomColors.ATOM_COLOR_PURPLE)).build(),
9, 5 * (float) (Math.PI / 180 *
time() * ((float) time() / 5)),
0d);
}
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
package io.github.teamgensouspark.grimoireofpatchouli.spellcard.entitiy;

import io.github.teamgensouspark.kekkai.color.DanCoreColors;
import io.github.teamgensouspark.kekkai.danmaku.DanmakuBuilder;
import io.github.teamgensouspark.kekkai.danmaku.KekkaiDanmakuCreationHelper;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.EntitySpellcard;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.Spellcard;
import net.katsstuff.teamnightclipse.danmakucore.entity.spellcard.SpellcardEntity;
import net.katsstuff.teamnightclipse.danmakucore.lib.data.LibShotData;
import net.minecraft.entity.EntityLivingBase;
import scala.Option;

public class WonderGodWind extends SpellcardEntity {

public WonderGodWind(Spellcard spellcard, EntitySpellcard cardEntity, Option<EntityLivingBase> target) {
super(spellcard, cardEntity, target);
}

@Override
public void onSpellcardUpdate() {
if (time() % 10 == 0) {
KekkaiDanmakuCreationHelper.createCircleShot(
DanmakuBuilder.getBuilderWithEntity(user())
.setShot(LibShotData.SHOT_MEDIUM.setSize(1f).setMainColor(DanCoreColors.COLOR_VANILLA_BLUE))
.build(),
12, 0f,
0.7d);
}

if (time() % 30 == 0) {
for (double d = 5; d >= 0; d--) {
KekkaiDanmakuCreationHelper.createCircleShot(
DanmakuBuilder.getBuilderWithEntity(user())
.setShot(LibShotData.SHOT_OVAL.setMainColor(
time() % 20 == 0 ? DanCoreColors.COLOR_SATURATED_GREEN
: DanCoreColors.COLOR_VANILLA_BLUE)
.setSize(0.8f)
.setDelay((int) (12 - d)))
.build(),
20,
(float) d, d);
}
}
}

}
3 changes: 3 additions & 0 deletions src/main/resources/assets/grimoireofpatchouli/lang/zh_cn.lang
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ spellcard.grimoireofpatchouli.master_spark=恋符「Master Spark」
item.spellcard.spellcard.grimoireofpatchouli.wave_particle.name=符卡:境符「波与粒的境界」
spellcard.grimoireofpatchouli.wave_particle=境符「波与粒的境界」

item.spellcard.spellcard.grimoireofpatchouli.earth_light.name=符卡:光符「Earth Light Ray」
spellcard.grimoireofpatchouli.earth_light=光符「Earth Light Ray」

itemGroup.goptab=帕秋莉的魔法书

item.card_bag.name=符卡袋
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "danmakucore:item/danmaku/spellcard/spellcard_base",
"textures": {
"1": "grimoireofpatchouli:items/spellcard/earth_light"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5e4da9b

Please sign in to comment.