Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / How to extend goblins life

Author
Message
Chevy Zilla
16
Years of Service
User Offline
Joined: 14th Sep 2008
Location:
Posted: 8th Oct 2008 18:12
how do i extend the goblins life in dark basic tutorial 25? please help in need of answers for a class I'm in.

<img src="http://img180.imageshack.us/img180/9605/hl2oo5.png"><br><img src="http://i131.photobucket.com/albums/p283/rhino_aus/GModUserbar.jpg">
BN2 Productions
21
Years of Service
User Offline
Joined: 22nd Jan 2004
Location:
Posted: 8th Oct 2008 19:36
Quote: "please help in need of answers for a class I'm in.
"


hmmmm going on the forums seems to make the class kinda pointless.

Either way, here is the general solution that you will have to figure out how to apply code-wise:

Life is basically just a variable. Right now, it believe that it is just a single hit will kill it, so there isn't any kind of a call to decrease its "life".

Wherever in the code it kills the goblin, you would make it decrease a variable instead.

After that check to see if the goblin is out of life.

MAKE SURE THAT BEFORE YOU KILL THE GOBLIN (but still within the check to see if it is out of life) YOU RE-SET THE LIFE VARIABLE! That is INCREDIBLY important as you will wonder why the goblin only dies once and then constantly spawns then dies all over the place.

Ever notice how in Microsoft word, the word "microsoft" is auto corrected to be "Microsoft" but "macintosh" just gets the dumb red underline?
Chevy Zilla
16
Years of Service
User Offline
Joined: 14th Sep 2008
Location:
Posted: 10th Oct 2008 05:59
thanks. the class is basically a general knowledge class so a challenge is to create a game. i found this help full and will try thank you much. if anyone has any actually "code" ideas then those would be well appreciated

<img src="http://img180.imageshack.us/img180/9605/hl2oo5.png"><br><img src="http://i131.photobucket.com/albums/p283/rhino_aus/GModUserbar.jpg">
TheComet
17
Years of Service
User Offline
Joined: 18th Oct 2007
Location: I`m under ur bridge eating ur goatz.
Posted: 24th Oct 2008 09:48 Edited at: 24th Oct 2008 09:49
Here:



And here is an example using it:



Suicide is away of telling God, You can’t fire me I quit !!!!!

Login to post a reply

Server time is: 2025-06-07 08:06:20
Your offset time is: 2025-06-07 08:06:20