Sunday, June 02, 2013

Running Code After X Seconds Delay in Cocos2D-x

Assuming you have a class called YOUR_CLASS in Cocos2-dx

You use something like this:

CCCallFunc* moveCallback = CCCallFunc::create(this, callfunc_selector(YOUR_CLASS::callfunc_selector_startTurn));

CCDelayTime* delayAction = CCDelayTime::create(2.0f);

this->runAction(CCSequence::create(delayAction, moveCallback, NULL));


And include a function like this for the CCCallFunc to call


void YOUR_CLASS::callfunc_selector_startTurn(void)
{
// do some stuff
}

Inspired by this blog post:





National Parks List


CALIFORNIA

National Parks With Hiking

Cabrillo National MonumentDogs are allowed on leash only west of Gatchell Road

Channel Islands National Park
Dogs are not allowed on the island

Death Valley National Park
Dogs are not allowed on trails or in public facilities

Devils Postpile National Monument
Dogs are allowed throughout this park

Golden Gate National Recreation Area
Dogs are allowed in many areas of the park; signs are posted and
dog-walking policies are subject to change


John Muir National Historic Site
Dogs are allowed in the two main areas of the park - the Mt.Wanda Unit
and the orchards around the house


Joshua Tree National Monument
Dogs are allowed in the campground but not on the hiking trails

Lassen Volcanic National Park
Dogs are not allowed on the trails or in buildings

Lava Beds National Monument
Dogs are allowed on some trails in this park

Muir Woods National Monument
Dogs are not allowed in this park

Pinnacles National Monument
Dogs are not allowed on the trails in this park

Point Reyes National Seashore
Dogs are not allowed on trails or in campgrounds but are permitted on
North and South beaches and part of Limantour Beach


Redwood National Park
Dogs are not allowed on the trails in this park

Santa Monica Mountains National Recreation Area
Dogs are permitted through most of this park except in state owned areas

Sequoia and Kings Canyon National Parks
Dogs are not allowed on the trails in these parks

Whiskeytown-Shasta-Trinity National Recreation Area
Dogs are allowed on the trails and through most of this park

Yosemite National Park
Dogs are not allowed on the trails or in the public buildings. For camping, dogs are allowed in Upper Pines in Yosemite Valley, the west end of the campground at Tuolumne Meadows and at White Wolf (Section C), Bridalveil (Section A), Crane Flats (Section A), Wawona, Hodgson Meadows and Yosemite Creek. Dogs can walk on some paved trails in valley.

Links to National Forests With Hiking

Angeles National Forest
Cleveland National Forest
Eldorado National Forest
Inyo National Forest
Klamath National Forest
Lassen National Forest
Los Padres National Forest
Mendocino National Forest
Modoc National Forest
Plumas National Forest
San Bernardino National Forest
Sequoia National Forest
Shasta-Trinity National Forest
Sierra National Forest
Six Rivers National Forest
Stanislaus National Forest
Tahoe National Forest
 State Parks With Hikinghttp://www.parks.ca.gov/default.asp
Dogs are usually banned from state park trails and not allowed in the following California state parks: Angel Island State Park, on the trails at Annadel State Park, Ano Nuevo State Reserve, Seven Mile Slough and Windy Cove at Brannan Island State Recreation Area, on the trails at Castle Rock State Park, Crystal Cove State Park, on all trails at Henry Cowell Redwoods State Park except Pipeline Road/Granham Hill/and Meadow, on the trails and beaches at Salt Point State Park, the Forest of Nivene Marks State Park except the entrance roads and picnic areas, everywhere but the campground and parking lots at Montana de Oro State Park and everywhere but the parking lot at Silver Strand State Beach.
Admiral William Standley State Recreation Area http://www.parks.ca.gov/default.asp?page_id=424
Ahjumawi Lava Springs State Parkhttp://www.parks.ca.gov/default.asp?page_id=464
http://www.parks.ca.gov/default.asp?page_id=483 
http://www.parks.ca.gov/default.asp?page_id=582
http://www.parks.ca.gov/default.asp?page_id=627 http://www.parks.ca.gov/default.asp?page_id=638
http://www.parks.ca.gov/default.asp?page_id=450 
http://www.parks.ca.gov/default.asp?page_id=634
Auburn State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=502 
Austin Creek State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=452 
Bale Grist Mill State Historic Parkhttp://www.parks.ca.gov/default.asp?page_id=482
Bean Hollow State Beachhttp://www.parks.ca.gov/default.asp?page_id=527 Benbow Lake State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=426 
Benicia State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=476 Bidwell-Sacramento River State Park http://www.parks.ca.gov/default.asp?page_id=463 
Big Basin Redwoods State Park-http://www.parks.ca.gov/default.asp?page_id=540 Bodie State Historic Parkhttp://www.parks.ca.gov/default.asp?page_id=509
Bolsa Chica State Beachhttp://www.parks.ca.gov/default.asp?page_id=642 
Border Field State Parkhttp://www.parks.ca.gov/default.asp?page_id=664 
Bothe-Napa Valley State Parkhttp://cal-parks.ca.gov/default.asp?page_id=477 Burleigh H. Murray Ranch Park Property http://cal-parks.ca.gov/default.asp?page_id=535 Burton Creek State Park http://cal-parks.ca.gov/default.asp?page_id=512 http://cal-parks.ca.gov/default.asp?page_id=536
Calaveras Big Trees State Parkhttp://cal-parks.ca.gov/default.asp?page_id=551 
Candlestick Point State Recreation Area http://cal-parks.ca.gov/default.asp?page_id=551 Cardiff State Beach http://cal-parks.ca.gov/default.asp?page_id=551 
http://cal-parks.ca.gov/default.asp?page_id=567
Carpinteria State Beach http://cal-parks.ca.gov/default.asp?page_id=599 http://cal-parks.ca.gov/default.asp?page_id=445
Castaic Lake State Recreation Areahttp://cal-parks.ca.gov/default.asp?page_id=628 Castle Crags State Park http://cal-parks.ca.gov/default.asp?page_id=454 
Caswell Memorial State Parkhttp://cal-parks.ca.gov/default.asp?page_id=557 
China Camp State Park http://cal-parks.ca.gov/default.asp?page_id=466 http://cal-parks.ca.gov/default.asp?page_id=648
Clear Lake State Park http://cal-parks.ca.gov/default.asp?page_id=473 http://cal-parks.ca.gov/default.asp?page_id=667
http://cal-parks.ca.gov/default.asp?page_id=505
Del Norte Coast Redwoods State Park http://cal-parks.ca.gov/default.asp?page_id=414 Emerald Bay State Park http://cal-parks.ca.gov/default.asp?page_id=506 Empire Mine http://cal-parks.ca.gov/default.asp?page_id=499 Folsom Lake State Recreation Areahttp://cal-parks.ca.gov/default.asp?page_id=500 
Fremont Peak State Park http://cal-parks.ca.gov/default.asp?page_id=564 Garrapata State Park http://cal-parks.ca.gov/default.asp?page_id=579 Greenwood State Parkhttp://cal-parks.ca.gov/default.asp?page_id=447 
Grizzly Creek Redwoods State Parkhttp://cal-parks.ca.gov/default.asp?page_id=421  Grover Hot Springs State Parkhttp://cal-parks.ca.gov/default.asp?page_id=508 Half Moon Bay State Park http://cal-parks.ca.gov/default.asp?page_id=531 
Harry A. Merlo State Recreation Area http://cal-parks.ca.gov/default.asp?page_id=431 Heber Dunes State Recreation Areahttp://cal-parks.ca.gov/default.asp?page_id=408
Hendy Woods State Park http://cal-parks.ca.gov/default.asp?page_id=438 Henry W. Coe State Park http://cal-parks.ca.gov/default.asp?page_id=561 Humboldt Lagoons State Parkhttp://cal-parks.ca.gov/default.asp?page_id=416 Humboldt Lagoons State Park http://cal-parks.ca.gov/default.asp?page_id=416 Humboldt Redwoods State Parkhttp://cal-parks.ca.gov/default.asp?page_id=425 Indian Grinding Rock State Historic Park http://cal-parks.ca.gov/default.asp?page_id=553  http://cal-parks.ca.gov/default.asp?page_id=640
Jack London State Historic Park http://cal-parks.ca.gov/default.asp?page_id=478 Jedediah Smith Redwoods http://cal-parks.ca.gov/default.asp?page_id=413 
Jughandle State Reserve http://cal-parks.ca.gov/default.asp?page_id=441 http://cal-parks.ca.gov/default.asp?page_id=612
Kruse Rhododendron State Reservehttp://cal-parks.ca.gov/default.asp?page_id=448 Lake Del Valle http://cal-parks.ca.gov/default.asp?page_id=537 
Lake Perris http://cal-parks.ca.gov/default.asp?page_id=651 Leo Carrillo State Park http://cal-parks.ca.gov/default.asp?page_id=616 Lighthouse Field State Beach http://cal-parks.ca.gov/default.asp?page_id=550 MacKerricher State Park http://cal-parks.ca.gov/default.asp?page_id=436 Manchester State Parkhttp://www.parks.ca.gov/default.asp?page_id=437 
Manresa State Beachhttp://www.parks.ca.gov/default.asp?page_id=545 http://www.parks.ca.gov/default.asp?page_id=581
McArthur-Burney Falls Memorial State Park http://www.parks.ca.gov/default.asp?page_id=455 
McConnell State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=554 http://www.parks.ca.gov/default.asp?page_id=607
Mendocino Headlands State Parkhttp://www.parks.ca.gov/default.asp?page_id=442 
Mendocino Woodlands Regionhttp://www.parks.ca.gov/default.asp?page_id=443 
Millerton Lake State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=587 Mono Lake Tufahttp://www.parks.ca.gov/default.asp?page_id=514 Montana de Oro State Parkhttp://www.parks.ca.gov/default.asp?page_id=592 
Montara State Beachhttp://www.parks.ca.gov/default.asp?page_id=532 
Monterey State Beachhttp://www.parks.ca.gov/default.asp?page_id=576 Montgomery Woods State Reservehttp://www.parks.ca.gov/default.asp?page_id=434 Morro Bay State Parkhttp://www.parks.ca.gov/default.asp?page_id=594 Morro Strand State Beachhttp://www.parks.ca.gov/default.asp?page_id=593 Moss Landing State Beachhttp://www.parks.ca.gov/default.asp?page_id=574 Mount Diablo State Parkhttp://www.parks.ca.gov/default.asp?page_id=517
Mount San Jacinto State Parkhttp://www.parks.ca.gov/default.asp?page_id=636 Mount Tamalpais State Parkhttp://www.parks.ca.gov/default.asp?page_id=471 
Natural Bridges State Beachhttp://www.parks.ca.gov/default.asp?page_id=541 Navarro River Redwoods State Parkhttp://www.parks.ca.gov/default.asp?page_id=435 
New Brighton State Beachhttp://www.parks.ca.gov/default.asp?page_id=542 Olompali State Historic Parkhttp://www.parks.ca.gov/default.asp?page_id=465 Pacheco State Parkhttp://www.parks.ca.gov/default.asp?page_id=560 Palomar Mountain State Parkhttp://www.parks.ca.gov/default.asp?page_id=637 Patrick's Point State Parkhttp://www.parks.ca.gov/default.asp?page_id=417 
Pelican State Beachhttp://www.parks.ca.gov/default.asp?page_id=412 
Pescadero State Beachhttp://www.parks.ca.gov/default.asp?page_id=522 Picacho State Parkhttp://www.parks.ca.gov/default.asp?page_id=641 
Pismo State Beachhttp://www.parks.ca.gov/default.asp?page_id=595 Plumas-Eureka State Parkhttp://www.parks.ca.gov/default.asp?page_id=507 
Point Dume State Beachhttp://www.parks.ca.gov/default.asp?page_id=623 Point Lobos State Reservehttp://www.parks.ca.gov/default.asp?page_id=571 Point Mugu State Parkhttp://www.parks.ca.gov/default.asp?page_id=630 
Pomponio State Beachhttp://www.parks.ca.gov/default.asp?page_id=521 
Portola Redwoods State Parkhttp://www.parks.ca.gov/default.asp?page_id=539 Prairie Creek Redwoods State Parkhttp://www.parks.ca.gov/default.asp?page_id=415
Providence Mountains State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=615
Red Rock Canyon State Parkhttp://www.parks.ca.gov/default.asp?page_id=631 Refugio State Beachhttp://www.parks.ca.gov/default.asp?page_id=603 Richardson Grove State Parkhttp://www.parks.ca.gov/default.asp?page_id=422 Robert H. Meyer Memorial State Beach http://www.parks.ca.gov/default.asp?page_id=633
Robert Louis Stevenson State Parkhttp://www.parks.ca.gov/default.asp?page_id=472 Robert W. Crown Memorial State Beach http://www.parks.ca.gov/default.asp?page_id=526 Russian Gulch State Parkhttp://www.parks.ca.gov/default.asp?page_id=432 Saddleback Butte State Parkhttp://www.parks.ca.gov/default.asp?page_id=526
Salinas River State Beachhttp://www.parks.ca.gov/default.asp?page_id=573 Salton Sea State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=639 Samuel P. Taylor State Parkhttp://www.parks.ca.gov/default.asp?page_id=469 
San Bruno Mountain State Parkhttp://www.parks.ca.gov/default.asp?page_id=518
San Clemente State Beachhttp://www.parks.ca.gov/default.asp?page_id=646 San Gregorio State Beachhttp://www.parks.ca.gov/default.asp?page_id=529 
San Luis Reservoir State Recreation Area http://www.parks.ca.gov/default.asp?page_id=558 San Onofre State Beachhttp://www.parks.ca.gov/default.asp?page_id=647
San Pasqual Battlefield State Historic Park http://www.parks.ca.gov/default.asp?page_id=655 
San Simeon State Parkhttp://www.parks.ca.gov/default.asp?page_id=590 Santa Susana Pass State Historic Park http://www.parks.ca.gov/default.asp?page_id=611 Schooner Gulch State Beachhttp://www.parks.ca.gov/default.asp?page_id=446
Silverwood Lake State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=650 Sinkyone Wilderness State Parkhttp://www.parks.ca.gov/default.asp?page_id=429ß Smithe Redwoods State Reservehttp://www.parks.ca.gov/default.asp?page_id=427 
Sonoma Coast State Beachhttp://www.parks.ca.gov/default.asp?page_id=451
South Yuba River State Parkhttp://www.parks.ca.gov/default.asp?page_id=496 
Standish-Hickey State Recreation Area http://www.parks.ca.gov/default.asp?page_id=423 
Sugarloaf Ridge State Parkhttp://www.parks.ca.gov/default.asp?page_id=481
Sunset State Beachhttp://www.parks.ca.gov/default.asp?page_id=544 Tahoe State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=504 Tijuana River National Estuarine Research Reserve State Parkhttp://www.parks.ca.gov/default.asp?page_id=669 Tomales Bay State Parkhttp://www.parks.ca.gov/default.asp?page_id=470 Tomo-Kahni State Parkhttp://www.parks.ca.gov/default.asp?page_id=610 Topanga State Parkhttp://www.parks.ca.gov/default.asp?page_id=629 Torrey Pines State Beachhttp://www.parks.ca.gov/default.asp?page_id=658 Torrey Pines State Reservehttp://www.parks.ca.gov/default.asp?page_id=657
Trinidad State Beachhttp://www.parks.ca.gov/default.asp?page_id=418 Turlock Lake State Recreation Areahttp://www.parks.ca.gov/default.asp?page_id=555 Twin Lakes State Beachhttp://www.parks.ca.gov/default.asp?page_id=547 Van Damme State Parkhttp://www.parks.ca.gov/default.asp?page_id=433
Washoe Meadows State Parkhttp://www.parks.ca.gov/default.asp?page_id=516 Westport-Union Landing State Beach http://www.parks.ca.gov/default.asp?page_id=440 Wilder Ranch State Parkhttp://www.parks.ca.gov/default.asp?page_id=549 
Will Rogers State Historic Parkhttp://www.parks.ca.gov/default.asp?page_id=626 Woodson Bridge State Recreation Area-http://www.parks.ca.gov/default.asp?page_id=459