This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is an initial finished prototype demonstrating Sculptie based armor that is affected by damage. (multiple stages of degradation, bullit holes etc) | |
integer damageStage = -1; | |
SendStatus(integer dmg) | |
{ | |
string texture = llGetInventoryName(INVENTORY_TEXTURE,dmg); | |
list params = [PRIM_TYPE, PRIM_TYPE_SCULPT, texture, PRIM_SCULPT_TYPE_SPHERE]; | |
llSetLinkPrimitiveParams(LINK_ALL_OTHERS,params); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// limit caching to test + live environment and "Published stage" only | |
if (Director::isDev() || Versioned::current_stage() !== 'Live') SS_Cache::set_cache_lifetime('any', -1, 100); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class HowtoPage extends DocumentPage { | |
public static $has_many = array( | |
'Steps' => 'Step', | |
); | |
public function getCMSFields() { | |
$fields = parent::getCMSFields(); | |
Debug::show($this->Steps()); // shows steps when exist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Class to make it easier to compare date ranges (where range is between start date and end date) | |
*/ | |
class DateRange { | |
public $StartDate = null; | |
public $EndDate = null; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* get relation chains for new records | |
*/ | |
class CMSGetRelationChainExtension extends Extension { | |
private $parts = null; | |
private $keys = array( | |
'field', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class TempTask extends BuildTask { | |
protected $title = 'TempTask'; | |
protected $description = ''; | |
public function run($request) { | |
echo '<pre>'; | |
// Do stuff |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Page_Controller extends ContentController { | |
public static $allowed_actions = array ( | |
'test' | |
); | |
public function test($r) { | |
return 'ok'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* This helper is a minimal geolocation service wrapper that allows quick geolocating. | |
* | |
* freegeoip.net is community funded, therefore please consider donating if you like and use this service. | |
* Alternatively you can run your own server. | |
* | |
* Example (uses a 1 hour cookie to minimize lookups): | |
* $is_international = Cookie::get('IsInternational'); | |
* if (is_null($is_international)) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
layout: nil | |
--- | |
<?xml version="1.0" encoding="utf-8"?> | |
<feed xmlns="http://www.w3.org/2005/Atom"> | |
<title type="text" xml:lang="en">{{ site.name }}</title> | |
<link type="application/atom+xml" href="{{ site.url }}/atom.xml" rel="self"/> | |
<link type="text/html" href="{{ site.url }}" rel="alternate"/> | |
<updated>{{ site.time | date_to_xmlschema }}</updated> | |
<id>{{ site.url }}/</id> |
OlderNewer