﻿<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ja">
	<id>https://wiki.blender.jp/index.php?action=history&amp;feed=atom&amp;title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88%3ARelease_Notes%2F2.49%2FGame_Engine%2FPython_API</id>
	<title>テンプレート:Release Notes/2.49/Game Engine/Python API - 版の履歴</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.blender.jp/index.php?action=history&amp;feed=atom&amp;title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88%3ARelease_Notes%2F2.49%2FGame_Engine%2FPython_API"/>
	<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88:Release_Notes/2.49/Game_Engine/Python_API&amp;action=history"/>
	<updated>2026-05-24T22:27:57Z</updated>
	<subtitle>このウィキのこのページに関する変更履歴</subtitle>
	<generator>MediaWiki 1.31.0</generator>
	<entry>
		<id>https://wiki.blender.jp/index.php?title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88:Release_Notes/2.49/Game_Engine/Python_API&amp;diff=87445&amp;oldid=prev</id>
		<title>Yamyam: 1版 をインポートしました</title>
		<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88:Release_Notes/2.49/Game_Engine/Python_API&amp;diff=87445&amp;oldid=prev"/>
		<updated>2018-06-28T18:41:20Z</updated>

		<summary type="html">&lt;p&gt;1版 をインポートしました&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;ja&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;← 古い版&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #222; text-align: center;&quot;&gt;2018年6月28日 (木) 18:41時点における版&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;ja&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(相違点なし)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Yamyam</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.blender.jp/index.php?title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88:Release_Notes/2.49/Game_Engine/Python_API&amp;diff=87444&amp;oldid=prev</id>
		<title>2010年4月3日 (土) 09:31にwiki&gt;Terrywallworkによる</title>
		<link rel="alternate" type="text/html" href="https://wiki.blender.jp/index.php?title=%E3%83%86%E3%83%B3%E3%83%97%E3%83%AC%E3%83%BC%E3%83%88:Release_Notes/2.49/Game_Engine/Python_API&amp;diff=87444&amp;oldid=prev"/>
		<updated>2010-04-03T09:31:38Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新規ページ&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== GE Python API: Changes  ==&lt;br /&gt;
&lt;br /&gt;
*Replacing many get/set methods with attributes that give direct access to the properties. &lt;br /&gt;
**Deprecation warnings can be disabled with &amp;quot;Ignore deprecation warnings&amp;quot; option to the game menu (disabled in Game Player by default). &lt;br /&gt;
**Improved range clamping for attributes. &lt;br /&gt;
**Added a utility that updates old scripts to use the new API. Be sure to keep a backup and carefully review the changes that are made.&lt;br /&gt;
{{RefBox&lt;br /&gt;
 |menu=Text → Text plugins → Convert BGE 2.49&lt;br /&gt;
 |lang=en&lt;br /&gt;
 }}&lt;br /&gt;
*Internal and external scripts can now be imported as python modules.&lt;br /&gt;
*Python's '''dir(ob)''' now reliably returns all methods, attributes and property names for all game-engine types. &lt;br /&gt;
*Accessing game engine data that has been removed will raise a SystemError, check for this case with the 'invalid' [[http://www.blender.org/documentation/249PythonDoc/GE/GameTypes.PyObjectPlus-class.html#invalid]] property.&lt;br /&gt;
*Python 2.6 compatibility (now supports python 2.3 - 2.6)&lt;br /&gt;
&lt;br /&gt;
*GameObject names are now read only, (renaming was buggy) &lt;br /&gt;
*printing a GameObject wont raise an exception anymore.&amp;lt;br&amp;gt; &lt;br /&gt;
*CListValue changes... &lt;br /&gt;
**disable changing CValueLists that the BGE uses internally&amp;lt;br&amp;gt;'''''scene.objects.append(1)''' would crash when drawing''.&amp;lt;br&amp;gt; &lt;br /&gt;
**types can now accept negative indicies eg '''scene.objects[-1]''' &lt;br /&gt;
**fix for printing, '''scene.objects''' will no longer show [,,,] &lt;br /&gt;
**An asserts for not yet implimented functionality, this would close blender.&amp;lt;br&amp;gt;Better to print an error if the user manages to run this functions (I managed to by ListValue.count([1,2,3]))&amp;lt;br&amp;gt; &lt;br /&gt;
**New method - ListValue.from_id(int) which uses the int return of pythons id() function to lookup a list item.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;python&amp;quot;&amp;gt;gameOb.other = id(otherGameOb)&lt;br /&gt;
...some time later...&lt;br /&gt;
otherGameOb = scene.objects.from_id(gameOb.other)&lt;br /&gt;
&amp;lt;/source&amp;gt; &lt;br /&gt;
*Changed '''GameLogic.addActiveActuator(actu, bool)''' to raise an error if the actuator is not in the list.&amp;lt;br&amp;gt;Before it would allow any value as the actuator and fail silently (makes debugging scripts more difficult). &lt;br /&gt;
*Allow the actuator to be a string which is convenient if you dont want to change the settings of the actuator.&amp;lt;br&amp;gt;'''GameLogic.addActiveActuator(controller.getActuator(&amp;quot;SomeAct&amp;quot;), True)'''&amp;lt;br&amp;gt;''...can be replaced with...''&amp;lt;br&amp;gt;'''controller.activate(&amp;quot;SomeAct&amp;quot;)'''&amp;lt;br&amp;gt; &lt;br /&gt;
*Existing method '''ob.isA(&amp;quot;KX_GameObject&amp;quot;)'''now accepts python types eg. '''ob.isA(GameTypes.KX_GameObject)'''&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GE Python API: Additions  ==&lt;br /&gt;
*VideoTexture module&amp;lt;br&amp;gt;''TODO Document this'' &lt;br /&gt;
*OpenGL access from the game engine as a module so you can '''import BGL''' directly. &lt;br /&gt;
*New module '''GameTypes''' which gives access to all types defined by the BGE. &lt;br /&gt;
*GameLogic.getSceneList() &lt;br /&gt;
**Dictionary style access to GameObject's '''ob.someProp = 10''' can now be '''ob[&amp;quot;someProp&amp;quot;] = 10'''&amp;lt;br&amp;gt;This avoids naming conflicts with new attributes and is faster since it does not have to look up built in attributes first.&lt;br /&gt;
*print warnings when python attributes and methods conflict with game properties.&lt;br /&gt;
*experimental KX_GameObject attributes &amp;quot;sensors&amp;quot;, &amp;quot;controllers&amp;quot; and &amp;quot;actuators&amp;quot; (NEAT&amp;amp;nbsp;!!!!) &lt;br /&gt;
*KX_GameObject.localInertia attribute. &lt;br /&gt;
*KX_GameObject.replaceMesh(mesh) &lt;br /&gt;
*KX_GameObject.sendMessage(...) and GameLogic.sendMessage(...) &lt;br /&gt;
*KX_GameObject.setParent(parent,compound,ghost), compound, ghost are new args.&lt;br /&gt;
*KX_GameObject.get(key, value) - dictionary like alternative to KX_GameObject[&amp;quot;key&amp;quot;].&lt;br /&gt;
*KX_GameObject.has_key(key) - dictionary like function to check for a key.&lt;br /&gt;
*ListValue.get(key, value) - dictionary like alternative to ListValue[&amp;quot;key&amp;quot;].&lt;br /&gt;
*ListValue.has_key(key) - dictionary like function to check for a key.&lt;br /&gt;
*KX_Camera.useViewport to get/set the viewport toggle, (deprecates enableViewport(bool))&lt;br /&gt;
*KX_Scene.addObject(...)&lt;br /&gt;
*KX_Scene.active_camera can now be set to set the camera without an actuator.&lt;br /&gt;
*KX_Scene.lights - list of light objects&lt;br /&gt;
*KX_Scene.cameras - list of cameras&lt;br /&gt;
*KX_Scene.objects_inactive - allows access to objects in unseen layers (before the AddObject actuator adds them).&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
BGE KX_Camera methods to handle Screen Space - (getScreenPosition, getScreenVect, getScreenRay)&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*'''getScreenPosition(obj)''': Gets the position of an object projected on screen space.&lt;br /&gt;
*'''getScreenVect(x, y)''': Gets the vector from the camera position in the screen coordinate direction.&lt;br /&gt;
*'''getScreenRay(x, y, dist, property)''': Look towards a screen coordinate (x,y) and find first object hit within dist that matches prop.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Script]]&lt;/div&gt;</summary>
		<author><name>wiki&gt;Terrywallwork</name></author>
		
	</entry>
</feed>