subject

Why is it useful to understand coding fundamentals even if you work in a game design role that doesn’t traditionally write code?
imagine you need to create a series of “bouncepads” for a platform game—a set of platforms that propel the character high into the air, with a challenge of having the player move from pad to pad before landing on a normal platform. describe an efficient way to set up that scenario, using things like conditional logic, queries, pre-fabs, etc. (you don’t need to include the specific code for the “bounce”
why would a programmer use a “public” variable for something like speed? provide at least two other examples of variables a developer would likely make “public.”
using these parameters and the logic statement, answer the following questions:

a= player has less than 10 health points (hp)
b= goblin has at least 10 hp
c= no other target (non-player characters -- npc) has less than 10 hp
d= goblin attacks the player
e= goblin drinks a potion
f= goblin attacks an npc

logic statement: if a and b are true, then if c is true, then d.

when would the enemy attack a player? change the parameters and the conditional logic statement to describe a situation where the enemy would drink a potion if they wouldn’t otherwise be able to kill a hero or npc in one hit (the enemy does 9 hp of damage with an attack).

review the following code for different random number generators:
random rnd = new random();
int month = rnd. next(1, 13); // 1 < = month < 13
int dice = rnd. next(1, 7); // 1 < = dice< 7
int card = rnd. next(53); // 0 < = card< 53
using what you know of programming, what do each of the three options indicate they are doing? what does the “big” largest number indicate about the way this coding language treats . rnd and maximums? when might you want a random number generator in a game? the unit discusses the weaknesses of copy-and-pasting code: it leads to errors when you forget to change a value or miss part of the section you meant to copy. can you think of any other risks to “copy pasta? ” do you agree with the unit’s argument? why or why not?

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 19:30
Why is it a good idea to leave an interview being courteous and polite?
Answers: 1
question
Computers and Technology, 22.06.2019 15:30
Which of the following examples has four beats in each measure?
Answers: 2
question
Computers and Technology, 23.06.2019 11:00
How should you specify box sizes on a web page if you want the boxes to vary according to the font size of the text they contain? a. in pixels b. in inches c. as percentages d. in em units
Answers: 2
question
Computers and Technology, 23.06.2019 14:00
How are stop motion special effects in animated films created
Answers: 1
You know the right answer?
Why is it useful to understand coding fundamentals even if you work in a game design role that doesn...
Questions
question
Mathematics, 16.12.2019 12:31
question
Mathematics, 16.12.2019 12:31
question
Biology, 16.12.2019 12:31
question
Mathematics, 16.12.2019 12:31
Questions on the website: 13722360