The VG Resource
PBG's ADVENTURE! (Yeah!) - Printable Version

+- The VG Resource (https://www.vg-resource.com)
+-- Forum: Creativity (https://www.vg-resource.com/forum-126.html)
+--- Forum: Game Development (https://www.vg-resource.com/forum-129.html)
+--- Thread: PBG's ADVENTURE! (Yeah!) (/thread-27609.html)

Pages: 1 2


RE: PBG's ADVENTURE! (Yeah!) - TheShyGuy - 08-30-2015

[Image: Ym6Plo4.png]

http://docs.yoyogames.com/source/dadiospice/002_reference/001_gml%20language%20overview/401_04_expressions.html

Use "div" for the division and "mod" for the remainder operator %.


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 08-30-2015

FRIIIICK. I hate pestering people with questions instead of asking them all at once... Ok. This is the last one as there's no more errors afterwards. What exactly do you mean with the statement "i++" in the for statement? It comes up as an in correct statement when used.


RE: PBG's ADVENTURE! (Yeah!) - TheShyGuy - 08-30-2015

I don't mind.

"i++" is the same thing as saying "i = i + 1"


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 08-30-2015

...I updated the engine... with WIP things. WIP bombs, WIP platforms, and... still WIP health. Just look at it. Its the white and black circles as i dont have a good sprite yet..

Check the first post for the link
My coding involving the health render:
Code:
DRAW EVENT:
for (i=0 ; i<maxhp; i=i+1)
{
if (i <hp)
draw_sprite(spr_heart_whole,0,posX, posY);
else
draw_sprite(spr_heart_empty,0,posX, posY)
}

STEP EVENT:
for (i=0 ; i<maxhp; i=i+1)
{
cellX = i mod 10;
cellY = i div 10;

posX = cellX * 16 + view_xview+1;
posY = cellY * 16 + view_yview+16;
}



RE: PBG's ADVENTURE! (Yeah!) - TheShyGuy - 08-30-2015

I am disappointed to see that you only added one health sprite Cry

I'm sorry that I don't have much else to say as there's not much to talk about. There's a bug. Holding down both move direction keys at the same time causes fast moon walking.


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 08-30-2015

What do you mean one health sprite..? Also, that bug with both keys I'm just trying to find a good fix for. If this doesn't work out... I might just resort to a health bar with a health stat.


RE: PBG's ADVENTURE! (Yeah!) - TheShyGuy - 08-30-2015

[Image: 6tQuLbi.png]


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 08-30-2015

Yeah... That's the problem. I think the horizontal cells aren't working right. I set up more than that. He's supposed to have 3...


RE: PBG's ADVENTURE! (Yeah!) - Silversea - 09-04-2015

The last time I did a zelda heart-styled HP system I took the lazy route because I argue with for loops too much. Made a sprite with 4 subimages, 1 for each heart "quarter".

And then something like

DRAW EVENT
if life > 0
{if life > 3 draw_spritRolleyesxt(spr_hud_hp,3,view_xview[0]+xx,view_yview[0]+yy,1,1,0,-1,1)
else draw_spritRolleyesxt(spr_hud_hp,life-1,view_xview[0]+xx,view_yview[0]+yy,1,1,0,-1,1)
}
if life > 4
{if life > 7 draw_spritRolleyesxt(spr_hud_hp,3,view_xview[0]+xx+20,view_yview[0]+yy,1,1,0,-1,1)
else draw_spritRolleyesxt(spr_hud_hp,life-5,view_xview[0]+xx+20,view_yview[0]+yy,1,1,0,-1,1)
}

that's two hearts, no STEP EVENT interference.

I made that off top of my head so probably isn't reliable, and I don't suggest using it without testing.


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 11-04-2015

Alright, I'm gonna try and get this project alive and running for a bit, again. If anyone can tell me what needs fixing ASAP (Other than placing bombs and the broken health "bar") if appreciate it. Otherwise, I'll start working on the bombs. It'll work this way; If you're standing and hit the bomb key, you throw it. If you crouch, you place it. Then, I'm cutting the ground roll, and start-up and ending lag to it, so it's harder than just jumping and pressing the attack button. Also, if you use it too close to the ground, you'll stumble, and be vulnerable to attacks for a second. Then, I need to find a better fix for the platforms you jump through, as when you're below it, the collision disappears, but that means other objects fall through it. It'll be appreciated if a script could be supplied for that, otherwise, I'll try something myself. I'll update y'all when I get there.


RE: PBG's ADVENTURE! (Yeah!) - Joxon - 11-07-2015

AGH. So I added crouching, which works fine, land lag works fine, but... FOR THE LIFE OF ME THROWING WON'T WORK. It broke everything so I had to redo everything other than throwing. I should be able to just use the same system for throwing as I am slashing (Going into a state then creating the hitboxes at the right time). But it didn't work. I'll give it another shot later. I'll update the game later. Also, if anyone could help out with an RPG text box script, that'd be great.