Cov txheej txheem:

2d foob pob hluav taws tsaws Sim: 3 Kauj Ruam
2d foob pob hluav taws tsaws Sim: 3 Kauj Ruam

Video: 2d foob pob hluav taws tsaws Sim: 3 Kauj Ruam

Video: 2d foob pob hluav taws tsaws Sim: 3 Kauj Ruam
Video: kawm lus Mev foob ​​pob hluav taws 2024, Hlis ntuj nqeg
Anonim
2d foob pob hluav taws tsaws Sim
2d foob pob hluav taws tsaws Sim
2d foob pob hluav taws tsaws Sim
2d foob pob hluav taws tsaws Sim
2d foob pob hluav taws tsaws Sim
2d foob pob hluav taws tsaws Sim

Koj yuav tsum tau ua ib qho nraub qaum, kos foob pob hluav taws, thiab qhov taw qhia kom pib (tau kawg koj yuav xav tau kev txuas hauv is taws nem txhawm rau siv khawb) yog tias koj tsuas yog xav ua qhov simulation/ game, nyem qhov no, lossis mus rau https:/ /scratch.mit.edu/projects/432509470/

Kauj Ruam 1: Lub Tshuab Physics

Physics Cav
Physics Cav
Physics Cav
Physics Cav

Cov foob pob hluav taws simulators tsis tuaj yeem muaj yam tsis muaj kev sim lub cev, thiab yog li koj yuav xav tau txhua qhov kev hloov pauv raws li hauv qab no:

  1. Vh lossis VelocityHorizontal raws li qhia hauv qhov piv txwv
  2. Vv lossis VelocityVertical raws li qhia
  3. EnginePower, los qhia qhov kev sib zog tsim los ntawm lub foob pob hluav taws
  4. EngineAngle, rau kev taw qhia los ntawm gimbals
  5. tag nrho cov tshaj tawm, rau qhov taw qhia thiab kov cov xwm txheej
  6. tau tawg, vim li cas peb yuav nkag mus rau theem tom ntej

Tom qab tsim cov kev hloov pauv, mus rau "txav" tab, thiab tso cov thaiv [hloov x los ()] thiab [hloov y los ()]

Muab koj Vv tso rau hauv [hloov y los ()] thiab Vh hauv [hloov x los ()] thiab muab txhua yam tso rau hauv lub voj.

Txhawm rau ntxiv qhov nqus, tsuas yog ntxiv [hloov Vh los ntawm (-1)] rau lub voj.

Txhawm rau ntxiv qee qhov zoo sib xws ntawm kev rub, ntxiv cov block hauv qab no rau lub voj:

[teeb tsa Vh rau (0.99*Vh)]

[teeb Vv rau (0.999*Vv)]

Huag tus tub tam sim no nws yog lub sijhawm rau "tshuab"

Txij li qhov no yuav raug tswj los ntawm gimbals thiab taw qhia, peb xav tau qee yam uas yuav tso cai rau lub foob pob hluav taws taug kev raws qhov nws tau taw qhia. raws li lub cav tig yuav muaj qee qhov cuam tshuam rau kev taw qhia ntawm lub zog, lub cav lub kaum ntse ntse yuav pab txhawb rau tag nrho cov kev taw qhia me ntsis yog li ntxiv qhov ntawd, thiab hais kom lub khoos phis tawj ua haujlwm me ntsis ntawm trigonometry thiab voila, lub cav tso tawm tiav.

Kauj Ruam 2: Game Mechanics

Game Mechanics
Game Mechanics
Game Mechanics
Game Mechanics
Game Mechanics
Game Mechanics
Game Mechanics
Game Mechanics

Raws li "game" qhov no yuav tsum muaj kev tswj hwm, yeej qhov xwm txheej, thiab qee txoj hauv kev kom qhov kev ua si xaus.

Txog kev tswj hwm, txhua yam uas yuav tsum tau ua yog txuas cov yuam sij rau qee qhov kev hloov pauv peb tau teeb tsa ua ntej

Muab ob tus yuam sij rau lub cav kev taw qhia thiab ib qho rau lub zog cav, raws li qhia saum toj no

Rau qhov xwm txheej yeej, siv ib qho xim tshwj xeeb lossis qib y los ua hauv av, thiab ntawm no kuv tso ib feem loj ntawm daim duab qhia chaw uas yog thaj chaw tsis zoo. raws li koj pom ntawm no, muaj kev siv qhov "tawg" qhov sib txawv, nws tiv thaiv tus hnav khaub ncaws teeb tsa los ntawm kev hloov rov qab mus rau qhov tsis tau tawg los ntawm thaum qhov tawg tshwm sim. cov ntsuas tau ua ntau dua lossis tsawg dua qhov ncaj ncees, thiab muaj qhov nrawm heev. tam sim no tom qab tsaws, foob pob hluav taws tau muab tso rau ntawm ib qib y txhawm rau tiv thaiv foob pob hluav taws, thiab txhua yam tau teeb tsa rau 0.

Txog kev pib ua haujlwm, teeb tsa nws mus rau lub kaum ntse ntse ntawm qhov chaw tsim nyog, lossis ua rau nws tsis raug, nws yog qhov koj xaiv

Kauj Ruam 3: Cov Ntsuas

Qhov ntsuas
Qhov ntsuas
Qhov ntsuas
Qhov ntsuas

thiab thaum kawg tsuas yog ua kom nws ua si rau ntau tus neeg, kuv ntxiv cov ntsuas, thiab koj yuav tsum ib yam, cov ntsuas pom tau yooj yim pom, thiab cov cai tau tshwm sim saum toj no.

Pom zoo: