map events or whatever

This commit is contained in:
the me 2022-08-23 02:25:43 -07:00
parent b0e718f879
commit 856b518593
28 changed files with 185 additions and 29 deletions
eastern flames
datafiles
eastern flames.yyp
objects
ARTICULATOR
o_damage
o_unit
scripts
c_changealignment
c_input
c_loadstageone
c_moveunit
c_selectunit
st_control
st_enemyturn
st_moving
tiledata
txt_aya
txt_momijiyaya
txt_momijiyreisen
txt_momijiytkn
txt_nitoriytkn
txt_reisen
txt_win
x_bunnies
x_textstyles
sprites/s_black

@ -0,0 +1,9 @@
CREDITS:
Aeon - code, numbers, mapstuff, japanese
Bakaretsu - 2d art
Bread Man - 3d support
Luyuu - chillin
Megapig9001 - concept, mapstuff, english, japanese
Muzilana - music
SolarisSect - ultra chillin
Vinyis - 3d, 3d art

@ -0,0 +1,12 @@
hello!
it's fire emblem. if you don't know what entails, consider yourself lucky.
controls:
wasd/arrows: move camera or selected character
left click/enter/space: advance, select
right click/esc/q: back, deselect
shift: aim attack
you can click on a weapon's name in your inventory to change it.
you've gotta hold shift to do anything with your guy (including wait) so, uh, don't forget. i cut out a submenu or two from vanilla emblem.
- aeon

@ -56,6 +56,7 @@
{"id":{"name":"camera_reset","path":"scripts/camera_reset/camera_reset.yy",},"order":0,},
{"id":{"name":"s_bunnyface","path":"sprites/s_bunnyface/s_bunnyface.yy",},"order":7,},
{"id":{"name":"o_unit","path":"objects/o_unit/o_unit.yy",},"order":2,},
{"id":{"name":"c_changealignment","path":"scripts/c_changealignment/c_changealignment.yy",},"order":35,},
{"id":{"name":"s_rabbittalk","path":"sprites/s_rabbittalk/s_rabbittalk.yy",},"order":4,},
{"id":{"name":"combat","path":"scripts/combat/combat.yy",},"order":13,},
{"id":{"name":"mod_negative","path":"scripts/mod_negative/mod_negative.yy",},"order":11,},
@ -77,6 +78,7 @@
{"id":{"name":"s_robotalk","path":"sprites/s_robotalk/s_robotalk.yy",},"order":6,},
{"id":{"name":"txt_","path":"scripts/txt_/txt_.yy",},"order":0,},
{"id":{"name":"ft_chiaro","path":"fonts/ft_chiaro/ft_chiaro.yy",},"order":1,},
{"id":{"name":"s_black","path":"sprites/s_black/s_black.yy",},"order":11,},
{"id":{"name":"Model","path":"scripts/Model/Model.yy",},"order":2,},
{"id":{"name":"s_title","path":"sprites/s_title/s_title.yy",},"order":9,},
{"id":{"name":"c_gettile","path":"scripts/c_gettile/c_gettile.yy",},"order":11,},
@ -237,6 +239,8 @@
{"CopyToMask":-1,"filePath":"datafiles/forestbattle","resourceVersion":"1.0","name":"forestbattle.size","resourceType":"GMIncludedFile",},
{"CopyToMask":-1,"filePath":"datafiles/plainsbattle","resourceVersion":"1.0","name":"plainsbattle.dat","resourceType":"GMIncludedFile",},
{"CopyToMask":-1,"filePath":"datafiles/plainsbattle","resourceVersion":"1.0","name":"plainsbattle.size","resourceType":"GMIncludedFile",},
{"CopyToMask":-1,"filePath":"datafiles","resourceVersion":"1.0","name":"readme.txt","resourceType":"GMIncludedFile",},
{"CopyToMask":-1,"filePath":"datafiles","resourceVersion":"1.0","name":"credits.txt","resourceType":"GMIncludedFile",},
],
"MetaData": {
"IDEVersion": "2.3.3.574",

@ -1,3 +1,4 @@
draw_set_font(ft_chiaro);
//c_addunit(un.chara, ARMY.US);
//c_addunit(un.kris, ARMY.THEM);
var i;

@ -1,3 +1,4 @@
//if ARTICULATOR.waiting
cpp();
draw_set_color(c_black);
//draw_set_alpha(0.25);

@ -17,12 +17,14 @@ x = tempx;
y = tempy;
//log(data);
draw_set_color(c_red);
draw_rectangle(0-ts.x/2, 0-sprite_height-1,
draw_rectangle(0-ts.x/2, 0-sprite_height+5,
0-ts.x/2+(ts.x*(data.hp.val/data.hp.cap)),
0-sprite_height+1, false
0-sprite_height+7, false
);
draw_text(5, -6-sprite_height-6, data.hp.val);
draw_set_halign(fa_center);
draw_text(0, -6-sprite_height-20, data.hp.val);
//draw_set_color(c_red);
draw_set_halign(fa_left);
//draw_circle(x, y, 5, false);
matrix_set(matrix_world,worldMat);

@ -0,0 +1,5 @@
function c_changealignment(unitobject, alignment) {
//array_remove(global.units[unitobject.alignment], unitobject);
unitobject.alignment = alignment;
array_push(global.units[alignment], unitobject);
}

@ -0,0 +1,12 @@
{
"isDnD": false,
"isCompatibility": false,
"parent": {
"name": "Scripts",
"path": "folders/Scripts.yy",
},
"resourceVersion": "1.0",
"name": "c_changealignment",
"tags": [],
"resourceType": "GMScript",
}

@ -9,7 +9,7 @@ function c_input() {
upp = keyboard_check_pressed(ord("W")) + keyboard_check_pressed(vk_up);
rightp = keyboard_check_pressed(ord("D")) + keyboard_check_pressed(vk_right);
select = mouse_check_button_pressed(mb_left) + keyboard_check_pressed(vk_enter);
select = mouse_check_button_pressed(mb_left) + keyboard_check_pressed(vk_enter) + keyboard_check_pressed(vk_space);
back = mouse_check_button_pressed(mb_right) + keyboard_check_pressed(vk_escape) + keyboard_check_pressed(ord("Q"));
stop = keyboard_check(vk_shift);
}

@ -15,7 +15,7 @@ function c_loadstageone() {
c_addweapon(nitori, wp[$"Healgun"], true);
var bunny = c_inheritunit(19, 3, un[$"Bunny Buddy"], ARMY.THEM);
/*var bunny = c_inheritunit(19, 3, un[$"Bunny Buddy"], ARMY.THEM);
c_addweapon(bunny, wp[$"Bayonet"], true);
bunny = c_inheritunit(17, 2, un[$"Final Bunny"], ARMY.THEM);
c_addweapon(bunny, wp[$"Bayonet"], true);
@ -49,7 +49,7 @@ function c_loadstageone() {
c_addweapon(bunny, wp[$"Bayonet"], true);
bunny = c_inheritunit(19, 13, un[$"Sneaky Bunny"], ARMY.THEM);
c_addweapon(bunny, wp[$"Lunar Machete"], true);
c_addweapon(bunny, wp[$"Lunar Machete"], true);*/
var reisen = c_inheritunit(19, 1, un[$"Rei'sen"], ARMY.THEM);

@ -5,5 +5,5 @@ function c_moveunit(targetunit, destination) {
array_push(destination.contents, targetunit);
targetunit.pos.x = destination.x;
targetunit.pos.y = destination.y;
theguy.event();
theguy.event(targetunit);
}

@ -18,7 +18,8 @@ function c_selectunit(unitobject) {
}
function c_deselectunit(unitobject) {
if ARTICULATOR.selectedunit != unitobject return false
if ARTICULATOR.selectedunit != unitobject return false;
if unitobject == noone return false;
unitobject.sprite_index = unitobject.data.idle;
state = st_standing;
drawstate = c_null;

@ -73,6 +73,9 @@ function st_control() {
}
c_dewait(global.turn);
//global.turn = (global.turn+1)%2;
hoveredunit = noone;
c_deselectunit(selectedunit);
waiting = 60;
k = 0;
global.turn = ARMY.THEM;
log("TURN " + string(global.turn));

@ -29,8 +29,10 @@ function st_enemyturn() {
if done {
c_dewait(global.turn);
k = 0;
c_deselectunit(selectedunit);
state = st_control;
global.turn = ARMY.US;
done = false;
}
//}
}

@ -137,6 +137,8 @@ function st_moving() {
if hitting.contents[i].alignment != alignment ^^ !data.str.val {
c_moveunit(id, c_gettile(pos.x, pos.y));
c_generatecombatstack([id, hitting.contents[i]]);
waiting = true;
c_deselectunit(id);
}
}
}
@ -147,7 +149,7 @@ function st_moving() {
c_moveunit(id, c_gettile(returnpos.x, returnpos.y));
c_deselectunit(id);
}
if dir == DIR.NONE && select && stop && ARTICULATOR.hoveredunit == id{
if dir == DIR.NONE && select && stop {
c_moveunit(id, c_gettile(x, y, true));
waiting = true;
c_deselectunit(id);

@ -1,24 +1,47 @@
global.gotaya = false;
global.gottkn = false;
var forest123456 = function() {return new tiledata(u, u, [], [new statmod(st.def, 5, add)])}
var forest123456 = function() {return new tiledata(u, u, [], [new statmod(st.def, 2, add)])}
var block1234567 = function() {return new tiledata(false, u, [])}
var recruit__aya = function() {return new tiledata(u, u, u, u, function(unitobject) {
if unitobject.alignment == ARMY.US {
switch unitobject.data.name {
case "Momiji":
textbox_create(txt_momijiyaya);
if !global.gotaya {
textbox_create(txt_momijiyaya);
global.gotaya = true;
c_changealignment(global.units[2][0], ARMY.US);
}
break;
}
}
})}
var recruit__tkn = function() {return new tiledata(u, u, u, [new statmod(st.def, 2, add)], function(unitobject) {
if unitobject.alignment == ARMY.US {
switch unitobject.data.name {
case "Momiji":
if !global.gottkn {
textbox_create(txt_momijiytkn);
global.gottkn = true;
c_changealignment(global.units[2][1], ARMY.US);
}
break;
case "Nitori":
if !global.gottkn {
textbox_create(txt_nitoriytkn);
global.gottkn = true;
c_changealignment(global.units[2][1], ARMY.US);
}
break;
}
}
})}
global.map = c_mapgen([
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), recruit__aya(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), recruit__aya(), new tiledata(), recruit__aya(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), recruit__aya(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), block1234567()],
[block1234567(), block1234567(), block1234567(), forest123456(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), block1234567(), new tiledata(), new tiledata(), new tiledata(), block1234567()],
[block1234567(), block1234567(), block1234567(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
@ -27,8 +50,8 @@ global.map = c_mapgen([
[new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), recruit__tkn(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), forest123456(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
[block1234567(), block1234567(), block1234567(), new tiledata(), new tiledata(), new tiledata(), recruit__tkn(), new tiledata(), recruit__tkn(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata(), new tiledata()],
]); //i simply dont care
function c_informtiles() {
for (i=0; i<array_length(global.map); i++) {

@ -1,5 +1,5 @@
function txt_aya() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Ayaya!", AYA.SURPRISED),

@ -1,5 +1,5 @@
function txt_momijiyaya() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Oh great, you...", MOMIJI.ANNOYED),

@ -1,6 +1,6 @@
global.everyonealive = true;
function txt_momijiyreisen() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Are you the commander of the other side?", REISEN.WOBBLE),

@ -1,5 +1,5 @@
function txt_momijiytkn() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Ah! Ive been spotted!", TAKANE.SURPRISED),

@ -1,5 +1,5 @@
function txt_nitoriytkn() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Aaah!", TAKANE.SURPRISED),

@ -1,5 +1,5 @@
function txt_reisen() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("E-Enemy spotted!", REISEN.WOBBLE),

@ -1,5 +1,5 @@
function txt_win() {
ARTICULATOR.state = c_null;
msg = msglang([
txt("Ow...", REISEN.WOBBLE),
@ -40,5 +40,5 @@ function txt_win() {
])
endevent = c_null;
endevent = function() {game_restart()};
}

@ -95,7 +95,7 @@ mydata = {
up: s_bunnyup,
down: s_bunnydown,
face: s_bunnyface,
aitype: AI.KILLER,
aitype: AI.WAITER,
}
nu unit(mydata, mydata, [st.hp.add(20), st.str.add(4), st.def.add(10), st.spd.add(9), st.mov.add(4), st.hit.add(0), st.rng.add(1)]);
mydata = {
@ -106,7 +106,7 @@ mydata = {
up: s_bunnyup,
down: s_bunnydown,
face: s_bunnyface2,
aitype: AI.KILLER,
aitype: AI.WAITER,
}
nu unit(mydata, mydata, [st.hp.add(30), st.str.add(10), st.def.add(4), st.spd.add(9), st.mov.add(4), st.hit.add(0), st.rng.add(1)]);
@ -151,9 +151,9 @@ mydata = {
up: s_bunnyup,
down: s_bunnydown,
face: s_bunnyface,
aitype: AI.WAITER,
aitype: AI.KILLER,
}
nu unit(mydata, mydata, [st.hp.add(27), st.str.add(7), st.def.add(7), st.spd.add(7), st.mov.add(4), st.hit.add(0), st.rng.add(1)]);
nu unit(mydata, mydata, [st.hp.add(27), st.str.add(7), st.def.add(7), st.spd.add(7), st.mov.add(2), st.hit.add(0), st.rng.add(1)]);
mydata = {
name: "Sneaky Bunny",
desc: "",

@ -18,7 +18,7 @@ global.textdefault = {
spriteposy: 190,
sprite: s_spacetext,
type: TEXTTYPE.ADV,
font: ft_couriernew,
font: ft_chiaro,
}

Binary file not shown.

After

(image error) Size: 3.0 KiB

@ -0,0 +1,79 @@
{
"bboxMode": 0,
"collisionKind": 0,
"type": 0,
"origin": 4,
"preMultiplyAlpha": false,
"edgeFiltering": false,
"collisionTolerance": 0,
"swfPrecision": 2.525,
"bbox_left": 0,
"bbox_right": 639,
"bbox_top": 0,
"bbox_bottom": 639,
"HTile": false,
"VTile": false,
"For3D": false,
"width": 640,
"height": 640,
"textureGroupId": {
"name": "Default",
"path": "texturegroups/Default",
},
"swatchColours": null,
"gridX": 0,
"gridY": 0,
"frames": [
{"compositeImage":{"FrameId":{"name":"654cfe64-38d8-4f2f-8288-abece37e91fb","path":"sprites/s_black/s_black.yy",},"LayerId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMSpriteBitmap",},"images":[
{"FrameId":{"name":"654cfe64-38d8-4f2f-8288-abece37e91fb","path":"sprites/s_black/s_black.yy",},"LayerId":{"name":"f17d5509-18e0-4bb7-bccd-954afee52892","path":"sprites/s_black/s_black.yy",},"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMSpriteBitmap",},
],"parent":{"name":"s_black","path":"sprites/s_black/s_black.yy",},"resourceVersion":"1.0","name":"654cfe64-38d8-4f2f-8288-abece37e91fb","tags":[],"resourceType":"GMSpriteFrame",},
],
"sequence": {
"spriteId": {"name":"s_black","path":"sprites/s_black/s_black.yy",},
"timeUnits": 1,
"playback": 1,
"playbackSpeed": 30.0,
"playbackSpeedType": 0,
"autoRecord": true,
"volume": 1.0,
"length": 1.0,
"events": {"Keyframes":[],"resourceVersion":"1.0","resourceType":"KeyframeStore<MessageEventKeyframe>",},
"moments": {"Keyframes":[],"resourceVersion":"1.0","resourceType":"KeyframeStore<MomentsEventKeyframe>",},
"tracks": [
{"name":"frames","spriteId":null,"keyframes":{"Keyframes":[
{"id":"9299d4cc-30a3-4272-a80b-4144f441295c","Key":0.0,"Length":1.0,"Stretch":false,"Disabled":false,"IsCreationKey":false,"Channels":{"0":{"Id":{"name":"654cfe64-38d8-4f2f-8288-abece37e91fb","path":"sprites/s_black/s_black.yy",},"resourceVersion":"1.0","resourceType":"SpriteFrameKeyframe",},},"resourceVersion":"1.0","resourceType":"Keyframe<SpriteFrameKeyframe>",},
],"resourceVersion":"1.0","resourceType":"KeyframeStore<SpriteFrameKeyframe>",},"trackColour":0,"inheritsTrackColour":true,"builtinName":0,"traits":0,"interpolation":1,"tracks":[],"events":[],"modifiers":[],"isCreationTrack":false,"resourceVersion":"1.0","tags":[],"resourceType":"GMSpriteFramesTrack",},
],
"visibleRange": null,
"lockOrigin": false,
"showBackdrop": true,
"showBackdropImage": false,
"backdropImagePath": "",
"backdropImageOpacity": 0.5,
"backdropWidth": 1366,
"backdropHeight": 768,
"backdropXOffset": 0.0,
"backdropYOffset": 0.0,
"xorigin": 320,
"yorigin": 320,
"eventToFunction": {},
"eventStubScript": null,
"parent": {"name":"s_black","path":"sprites/s_black/s_black.yy",},
"resourceVersion": "1.3",
"name": "s_black",
"tags": [],
"resourceType": "GMSequence",
},
"layers": [
{"visible":true,"isLocked":false,"blendMode":0,"opacity":100.0,"displayName":"default","resourceVersion":"1.0","name":"f17d5509-18e0-4bb7-bccd-954afee52892","tags":[],"resourceType":"GMImageLayer",},
],
"nineSlice": null,
"parent": {
"name": "Sprites",
"path": "folders/Sprites.yy",
},
"resourceVersion": "1.0",
"name": "s_black",
"tags": [],
"resourceType": "GMSprite",
}