GameMaker Studio 2: Complete Platformer Tutorial (Part 23: Score tracking)

preview_player
Показать описание
New parts to this series released on most Fridays
Рекомендации по теме
Комментарии
Автор

If your kill count returns to zero whenever you start a new room;
1. Make sure you drag oGame ONLY into rMenu.
2. Tick that bloody 'persistent' box.
3. Don't drag it manually into each room; restarting 'global.kills = 0;' in oGame's create event each room.
4. Don't be a big dumdum like me by paying less than 100% attention for even a split second.

rhysjones
Автор

Do you have a link to where I can find all of your custom scripts? (Approach, DrawSetText, ect)

CRAIGGU
Автор

Hi. I'm late to the party (as usual) but following the tutorials with interest. I'm on v2.3.2.560 and when I move from room to room, my global.kills resets to zero. On a bit of debugging, I'm finding that my ogame's create script is run at slide transition which initialises both global variables. What have I done wrong?

jimiwilson
Автор

If you put a smiley face instead of a sad face it changes the whole entire meaning

Cuewotted
Автор

so i wanted to make the players health the same as the score and when you get hit, your score goes. if you are at zero and get hit you die. but when i die the score goes negative the highest score i got prior to dying and doesn't start counting till you get back past zero. for example, you get 5 coins and die, now youre score is -5 and you need to get 10 coins to get to zero. any ideas on why this is the case?

marcusyoung
Автор

I'm curious why do you use global variables. Also why do you use "with (oGame) killtextscale = 2;" ? You can just reference and change those variables with less typing using "oGame.killtextscale = 2;" or "oGame.kills ++;" Is it better practice to do it your way for some reason? This is not a judgement it's honest curiosity if I'm doing it wrong.

TheSkippunk
Автор

in the draw gui event, the game dosent seem to register the color in the "DrawSetText(c_black, fMenu, fa_right, fa_top);" the draw_set_color overwright both texts. although the DrawSetText seems to be correct.

Vager
Автор

Can anyone give me advice because my text isn’t showing. oGame is persistent and visible, it is definitely in the room. When I take away the line — if (room != menu) then it shows in the menu so the text does exist. But then I go to the next room it vanishes and fails to show. Anyone got idea?

JpKizzy
Автор

uh how do i do this if i didn't have the RES_W from last time as my thing was already fixed

hunter-of-artemis
Автор

I’m trying to make my character be able to crouch, and I’ve got him to be able to look like he is but I can’t figure out how to reduce the collision mask when he does. It doesn’t work to set the mask to be same as sprite. Any ideas?

feereddieb
Автор

20:25 When your creation gets the better of you. Stephen Hawking was right all along

Tdog
Автор

When did we create a drawsettext script? I need to know the code inside of it because I don’t have it

anakinopium
Автор

@ Shaun Spaulding got everything to work up to a certain point for the score keeping episode, but was wondering is you might be able to help with these problems:

1. When I die score doesn't reset at all ( loading save state keeps it however)

2. I get an error with the line global.kill -= global.killsthisroom, ( run fine except above bugs happening when I change it to =- in that error.

I'm still learning, hoping someone might be able to help, thank you so much Shaun for taking me this far, keep up your good work!!

joshuafoster
Автор

Hey I was trying to get this global.kills -= global.killsthisroom; script to work but after testing and testing for the last hour, the display keeps disappearing when I die in another room. I would love to get some thought or solutions if any of you ran in the same issue :)

royschippers
Автор

Can I get an explanation for why my textures turned into some white broken text in GameMaker Studio 2?

MasterBroNetwork
Автор

I changed "with (oGame) killtextscale = 2;" to "oGame.killtextscale = 2;" so it's just as easy to use as global variables.
Also, I used instance_change instead of instance_create_layer and instance_destroy. Just like how the bullet changes into the hitspark.

NaudVanDalen
Автор

Can you do something like making ladders bouncers powerups and a flags for the endzone and even a secret route way to win the game

grandpop
Автор

lol, i already have "globalvar" setup as have been using it for enemy strengthening and weapon system powerups

ZerobreakerEduEnt
Автор

Can you make a second weapon for this tutorial? Also you could add lighting to this tutorial because it would look awesome and there are no other lighting tutorials for GMS2 so it would be really helpful!

georgeandriopoulos
Автор

I FOUND A FIX FOR IF YOUR SCORE TEXT ISN'T APPEARING!!

(Scroll to bottom if you're impatient)
This has been plague-ing me for months, and I haven't been able to find a fix. Another commentor even saying the EXACT thing, WORD FOR WORD, i was dealing with. But, I figured it out. This whole time, it says "DrawSetText" as the script. That's why it doesn't work.

It has to be "scr_DrawSetText" in the "oGame" Object.

Linguini_Guy